Hey Alex, thanks for the reply.
Well, for cache.log I can that the file size is getting smaller and there are several cache.log.N files getting created, for access.log nothing is happening.
This is my Squid --version:
Squid Cache: Version 4.6Service Name: squidDebian linuxconfigure options: '--build=i686-linux-gnu' '--prefix=/usr' '--includedir=${prefix}/include' '--mandir=${prefix}/share/man' '--infodir=${prefix}/share/info' '--sysconfdir=/etc' '--localstatedir=/var' '--libexecdir=${prefix}/lib/squid' '--srcdir=.' '--disable-maintainer-mode' '--disable-dependency-tracking' '--disable-silent-rules' 'BUILDCXXFLAGS=-g -O2 -fdebug-prefix-map=/build/squid-wx8Sif/squid-4.6=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -latomic' 'BUILDCXX=i686-linux-gnu-g++' '--with-build-environment=default' '--enable-build-info=Debian linux' '--datadir=/usr/share/squid' '--sysconfdir=/etc/squid' '--libexecdir=/usr/lib/squid' '--mandir=/usr/share/man' '--enable-inline' '--disable-arch-native' '--enable-async-io=8' '--enable-storeio=ufs,aufs,diskd,rock' '--enable-removal-policies=lru,heap' '--enable-delay-pools' '--enable-cache-digests' '--enable-icap-client' '--enable-follow-x-forwarded-for' '--enable-auth-basic=DB,fake,getpwnam,LDAP,NCSA,NIS,PAM,POP3,RADIUS,SASL,SMB' '--enable-auth-digest=file,LDAP' '--enable-auth-negotiate=kerberos,wrapper' '--enable-auth-ntlm=fake,SMB_LM' '--enable-external-acl-helpers=file_userip,kerberos_ldap_group,LDAP_group,session,SQL_session,time_quota,unix_group,wbinfo_group' '--enable-security-cert-validators=fake' '--enable-storeid-rewrite-helpers=file' '--enable-url-rewrite-helpers=fake' '--enable-eui' '--enable-esi' '--enable-icmp' '--enable-zph-qos' '--enable-ecap' '--disable-translation' '--with-swapdir=/var/spool/squid' '--with-logdir=/var/log/squid' '--with-pidfile=/var/run/squid.pid' '--with-filedescriptors=65536' '--with-large-files' '--with-default-user=proxy' '--with-gnutls' '--enable-linux-netfilter' 'build_alias=i686-linux-gnu' 'CC=i686-linux-gnu-gcc' 'CFLAGS=-g -O2 -fdebug-prefix-map=/build/squid-wx8Sif/squid-4.6=. -fstack-protector-strong -Wformat -Werror=format-security -Wall' 'LDFLAGS=-Wl,-z,relro -Wl,-z,now -Wl,--as-needed -latomic' 'CPPFLAGS=-Wdate-time -D_FORTIFY_SOURCE=2' 'CXX=i686-linux-gnu-g++' 'CXXFLAGS=-g -O2 -fdebug-prefix-map=/build/squid-wx8Sif/squid-4.6=. -fstack-protector-strong -Wformat -Werror=format-security
If I follow your instructions, this is what I get:
2020/12/31 20:33:49 kid1| Logfile: opening log daemon:/var/log/squid/access.log2020/12/31 20:33:49 kid1| Logfile Daemon: opening log /var/log/squid/access.log2020/12/31 20:33:49 kid1| Store logging disabled2020/12/31 20:33:57 kid1| logfileRotate: daemon:/var/log/squid/access.log2020/12/31 20:33:57 kid1| logfileRotate: daemon:/var/log/squid/access.log2020/12/31 20:33:57 kid1| Logfile: opening log daemon:/var/log/squid/access.log2020/12/31 20:33:57 kid1| Logfile Daemon: opening log /var/log/squid/access.log2020/12/31 20:33:57 kid1| Store logging disabled
For "rotate" I am getting nothing, but I do however see transactions getting logged to access.log and my logging daemon is running properly.
> How do you know that your access.log was _not_ rotated?
Any tips?
On Tue, Dec 29, 2020 at 8:37 PM Alex Rousskov <rousskov@xxxxxxxxxxxxxxxxxxxxxxx> wrote:
On 12/29/20 12:33 PM, roee klinger wrote:
> I am using a Raspberry Pi and the latest version of Squid which I
> installed from apt.
>
> In my cache.log, here are all my logging and rotation-related messages:
>
> 2020/12/29 17:37:14 kid1| logfileRotate: daemon:/var/log/squid/access.log
> 2020/12/29 17:37:14 kid1| logfileRotate: daemon:/var/log/squid/access.log
> 2020/12/29 17:37:14 kid1| Logfile: opening log daemon:/var/log/squid/access.log
> 2020/12/29 17:37:14 kid1| Logfile Daemon: opening log /var/log/squid/access.log
> 2020/12/29 17:37:14 kid1| Store logging disabled
What is your Squid version? "squid --version" may answer that question.
The "opening log" lines in your cache.log look strange. I do not see
them in my tests, but my version of Squid is probably different from
yours. If you shut down Squid completely, then remove all cache.log
files, then start Squid, and then rotate once, what logging and rotation
messages do you see in all the resulting cache.log files (including the
rotated ones)? Do not shut down or restart Squid until you collect all
those lines. Include all lines that mention "log" or "rotate".
Do you see transactions getting logged to access.log?
Is the logging daemon running? "ps aux | grep 'logfile[-]daemon'" or a
similar command may answer that question.
How do you know that your access.log was _not_ rotated?
Alex.
> On Tue, Dec 29, 2020 at 6:40 PM Alex Rousskov wrote:
>
> On 12/29/20 10:36 AM, roee klinger wrote:
>
> > logfile_rotate 10
> > access_log daemon:/var/log/squid/access.log logformat=xxxx
> rotate=10
>
> > running "squid -k rotate" still does nothing for the access.log file.
>
> Please note that, according to Squid documentation, your Squid is
> slightly misconfigured:
>
> > rotate=N Specifies the number of log file
> rotations to
> > make when you run 'squid -k rotate'.
> [...]
> > Only supported by the stdio module.
>
> You are not using an "stdio" module. You are using a "daemon" module.
>
> This minor misconfiguraiton, if any, does not explain the lack of
> rotations. The deamon module should still rotate based on your global
> logfile_rotate directive setting.
>
> What is your Squid version? What logging and rotation-related messages
> do you see in your cache.log (check both the pre-rotation and
> post-rotation files)?
>
> Alex.
>
_______________________________________________ squid-users mailing list squid-users@xxxxxxxxxxxxxxxxxxxxx http://lists.squid-cache.org/listinfo/squid-users