When using dansguardian-2.8.0.6 with gentoo 2005.1 it gives following error, -------------- Error opening/creating log file. (check ownership and access rights). I am running as nobody and I am trying to open /var/log/dansguardian/access.log -------------- I created the access.log file and change the permission with nobody and change access rights with 755 but still having same problem. Also I tried to change login shell for user nobody and login using nobody on console and then try to run dansguardian it's working. But it is not working through root login nor through /etc/init.d/dansguardian script. * But running same ebuild on gentoo version 2005 works fine. Reproducibility everytime. Steps to reproduce: 1. emerge ebuild net-proxy/dansguardian-2.8.0.6 2. create access.log file with nobody as a owner and group in /var/log/dansguardian/ 3. login as root 4. run /usr/sbin/dansguardian Expected result: Error connecting to parent proxy as squid service is not started.
what permissions does the /var/log/dansguardian directory have?
The directory has owner and group as nobody. Permission on directory set as 755. Even after giving 777 -R to /var/log/dansguardian still it showing same error.
can't reproduce it. are you sure that nobody user has rw access to /var/log/dansguardian/access.log? switch to that user by running "su - nobody" (nobody should have a valid shell) and try to edit that file.
Yes, user nobody has rw access for access.log file, able to edit access.log file with user "nobody" using bash shell. pwcf ~ # ls -la /var/log/dansguardian/access.log -rw-r-xr-x 1 nobody nobody 81 Nov 4 09:28 /var/log/dansguardian/access.log Is there any way I can debug dansguardian in runtime. I am not sure during runtime does it really use "nobody" user for accessing log file bcoz if I login with nobody using bash shell and then try to run /usr/sbin/dansguardian it's works.
do you have daemonuser = 'nobody' daemongroup = 'nobody' in your config file? see if revdep-rebuild want to rebuild something (this always should be the first step when you're in trouble).
yes I do have "nobody" as daemonuser and daemongroup in config file. revdep-rebuild output shows :-> Assigning files to ebuilds... Nothing to rebuild. The problem still continue..
I have a similar problem but I am running DGAV too. Everyday the log file permissions get changed to user "root" group "adm" and I think DGAV runs as user "clamav". I change the permissions manually and everything works until the log file is archived and a new one created then dodgy permissions get put back on the file. Please fix it.
does dansguardian works with following methods ? su - nobody sudo -u nobody
the reporter has vanished. anyway, the bug is likely to be an invalid one.