Squid and SquidGuard not starting


  • Hi there everyone

    I'm having this trouble since my first install of pfSense,
    I install my package Squid and configure it, after i then I install SquidGuard and i configure it, I go to Status>Services and i see both services off I turn on Squid: OK then i go to SquidGuard and this kill Squid and SquidGuard did not start.

    Here its my logs:
    Last 50 system log entries
    Nov 23 20:00:10 kernel: pid 28644 (squid), uid 62: exited on signal 6
    Nov 23 20:00:13 Squid_Alarm[28898]: Reconfiguring filter…
    Nov 23 20:00:13 php: /status_services.php: The command '/usr/local/etc/rc.d/squid.sh stop' returned exit code '1', the output was '2014/11/23 20:00:08| parseConfigFile: squid.conf:64 unrecognized: 'La' squid: ERROR: No running copy'
    Nov 23 20:00:13 check_reload_status: Reloading filter
    Nov 23 20:00:15 squid[32526]: Squid Parent: child process 32696 started
    Nov 23 20:00:15 squid[32696]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:00:15 squid[32526]: Squid Parent: child process 32696 exited due to signal 6
    Nov 23 20:00:15 kernel: pid 32696 (squid), uid 62: exited on signal 6
    Nov 23 20:00:18 squid[32526]: Squid Parent: child process 35748 started
    Nov 23 20:00:18 squid[35748]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:00:18 squid[32526]: Squid Parent: child process 35748 exited due to signal 6
    Nov 23 20:00:18 kernel: pid 35748 (squid), uid 62: exited on signal 6
    Nov 23 20:00:21 squid[32526]: Squid Parent: child process 38612 started
    Nov 23 20:00:21 squid[38612]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:00:21 squid[32526]: Squid Parent: child process 38612 exited due to signal 6
    Nov 23 20:00:21 kernel: pid 38612 (squid), uid 62: exited on signal 6
    Nov 23 20:00:24 squid[32526]: Squid Parent: child process 39154 started
    Nov 23 20:00:24 squid[39154]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:00:24 squid[32526]: Squid Parent: child process 39154 exited due to signal 6
    Nov 23 20:00:24 kernel: pid 39154 (squid), uid 62: exited on signal 6
    Nov 23 20:00:27 squid[32526]: Squid Parent: child process 39546 started
    Nov 23 20:00:27 squid[39546]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:00:27 squid[32526]: Squid Parent: child process 39546 exited due to signal 6
    Nov 23 20:00:27 kernel: pid 39546 (squid), uid 62: exited on signal 6
    Nov 23 20:00:27 squid[32526]: Exiting due to repeated, frequent failures
    Nov 23 20:00:27 dansguardian[41214]: Error binding ipc server file (try using the SysV to stop DansGuardian then try starting it again or doing an 'rm /tmp/.dguardianipc').
    Nov 23 20:00:27 dansguardian[41214]: Exiting with error
    Nov 23 20:00:27 root: /usr/local/etc/rc.d/dansguardian.sh: WARNING: failed to start dansguardian
    Nov 23 20:01:12 php: /status_services.php: The command '/usr/local/etc/rc.d/squid.sh stop' returned exit code '1', the output was '2014/11/23 20:01:07| parseConfigFile: squid.conf:64 unrecognized: 'La' squid: ERROR: No running copy'
    Nov 23 20:01:14 squid[61393]: Squid Parent: child process 61527 started
    Nov 23 20:01:14 squid[61527]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:01:14 squid[61393]: Squid Parent: child process 61527 exited due to signal 6
    Nov 23 20:01:14 kernel: pid 61527 (squid), uid 62: exited on signal 6
    Nov 23 20:01:17 squid[61393]: Squid Parent: child process 61803 started
    Nov 23 20:01:18 squid[61803]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:01:18 squid[61393]: Squid Parent: child process 61803 exited due to signal 6
    Nov 23 20:01:18 kernel: pid 61803 (squid), uid 62: exited on signal 6
    Nov 23 20:01:21 squid[61393]: Squid Parent: child process 64436 started
    Nov 23 20:01:21 squid[64436]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:01:21 squid[61393]: Squid Parent: child process 64436 exited due to signal 6
    Nov 23 20:01:21 kernel: pid 64436 (squid), uid 62: exited on signal 6
    Nov 23 20:01:24 squid[61393]: Squid Parent: child process 64753 started
    Nov 23 20:01:24 squid[64753]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:01:24 squid[61393]: Squid Parent: child process 64753 exited due to signal 6
    Nov 23 20:01:24 kernel: pid 64753 (squid), uid 62: exited on signal 6
    Nov 23 20:01:27 squid[61393]: Squid Parent: child process 65087 started
    Nov 23 20:01:27 squid[65087]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.
    Nov 23 20:01:27 squid[61393]: Squid Parent: child process 65087 exited due to signal 6
    Nov 23 20:01:27 kernel: pid 65087 (squid), uid 62: exited on signal 6
    Nov 23 20:01:27 squid[61393]: Exiting due to repeated, frequent failures

    Any idea?
    Sorry about my english. :)


  • Same problem here. I have installed pfsense new and the proble is every time the same. Version 2.1.5 an 2.2.

    best regards


  • make sure you've created the squid directories. Get to the command prompt (Shell) of your pfsense box and type "squid -z"
    Let it create your directories and then try starting the services again.


  • I found the 'squid -z' suggestion was not helpful and made my problem worse. Do not type "squid -z" at the command line.  I still can not get squid or squid guard to start after a reboot. I am using the latest versions of pfsense 2.2.1 and squid 2.7.9 pkg v.4.3.6 and squid guard 1.4_7 pkg v.1.9.10.


  • Has anyone found a solution on this? My squidguard stops from working after upgrading to 2.2.


  • squid[65087]: Cannot open '/root/access.log' for writing. The parent directory must be writeable by the user 'proxy', which is the cache_effective_user set in squid.conf.

    Squid's access.log should be in /var/squid/logs, not /root.  What do you have in your Squid settings under Services - Proxy server - Logging Settings - Log store directory?


  • Same problem here. Wasn't working before I updated to 2.2.1, still not working now.
    squid 2.7.9 pkg 4.3.6
    squidguard 1.4_7 pkg 1.9.12

    Have tried reinstalling both. same result. I have the following errors in log files.

    php-fpm[246]: /rc.start_packages: The command '/usr/pbi/squid-i386/sbin/squid -D' returned exit code '1', the output was 'FATAL: Bungled squid.conf line 75: url_rewrite_program /usr/pbi/squidguard-i386/bin/squidGuard -c /usr/pbi/squidguard-i386/etc/squidGuard/squidGuard.conf Squid Cache (Version 2.7.STABLE9): Terminated abnormally.

    squid[68340]: Bungled squid.conf line 75: url_rewrite_program /usr/pbi/squidguard-i386/bin/squidGuard -c /usr/pbi/squidguard-i386/etc/squidGuard/squidGuard.conf

    EDIT: forgot to mention.. I inherited this setup and my pfsense foo isn't overly strong.
    I did find the following in the custom options field in the GUI.
    seems the error is referencing that but not sure what about it is the problem.

    redirect_children 3;redirect_program /usr/pbi/squidguard-i386/bin/squidGuard -c /usr/pbi/squidguard-i386/etc/squidGuard/squidGuard.conf;redirector_bypass off;url_rewrite_program /usr/pbi/squidguard-i386/bin/squidGuard -c /usr/pbi/squidguard-i386/etc/squidGuard/squidGuard.conf;url_rewrite_bypass off;url_rewrite_children 16 startup=8 idle=4 concurrency=0


  • Don't waste your time on Squid2.  Use Squid3.

    I've never seen a 'bungled' conf error before.


  • This is happening because squidguard on pfsense is adding redirect_program and  url_rewrite_program params. The second one is fine for squid3 but it's not working with squid2.
    Deleting url_rewrite directives from proxy Custom Options solves the problem untill next reboot. You can edit squidguard_configurator.inc on /usr/local/pkg to avoid this.


  • Well there you go.  I don't use squid2.


  • SquidGuard 1.4_7 pkg v.1.9.14 + Squid 2.7.9 or Squid 3.4.10

    After reboot box, Squid and SquidGuard not starting….


  • @ntct:

    SquidGuard 1.4_7 pkg v.1.9.14 + Squid 2.7.9 or Squid 3.4.10

    After reboot box, Squid and SquidGuard not starting….

    Good Evening,

    I experienced this same issue & researched it for a couple of months.  I am currently running the current Squid3 with SquidGuard.  Each time pfSense reboots, you must go into the Proxy Filter & re-download the blacklist.  After the blacklist downloads, both Squid3 & SquidGuard will automatically come back to life.  I have no idea why this is occurring or why this works, but it seems to do the trick.

    Best-

    Darren


  • me too squidguard with squid 3.4 cant start :'(


  • I found that If i add a whitelist in target categories and set it allow or white

    Reboot pfsense, Squid and SquidGuard  starting….

    It's strange


  • Yep, I had the same problem.  You just need to create at least one entry under the Target Categories tab and then both services will start.


  • ^This is working for me, for now.


  • i thinj hat i might have the same problem as this
    https://forum.pfsense.org/index.php?topic=92545.0

    what is this whtelist solution may i ask could i have some more info please ?


  • please follow the below



  • great news that seems to of fixed it :D


  • thanks sir its work :D