Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    HOW-TO: Fix Squid3/SquidGuard auto-start after reboot

    Scheduled Pinned Locked Moved Cache/Proxy
    16 Posts 14 Posters 118.7k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      jimmy_1969
      last edited by

      Hi,

      Just want to do a short explanation how to fix the current issue with Squid3 and SquidGuard services not starting up automatically after a reboot.

      User stephenw10 should have the credit for posting the solution here https://forum.pfsense.org/index.php?topic=90961.msg517751#msg517751.

      But for some of us, the description might be a little too vague, so I took the liberty of explaining it in more detail in this post.

      Impacted Packages
      Squid3, release 0.2.8
      squidGuard, release 1.9.14

      Symptoms

      • After reboot, your squid and squidguard services does not autostart

      • Log file /var/squid/logs/cache.log contains numerous errors of

        Shared object "libldap-2.4.so.2" not found, required by "squidGuard"

      Root Cause
      If using downloaded blacklists only, the required file/folder isn't created and at boot Squidguard fails to start filling the squid logs in cache.log with above error.

      Work Around

      • Bring up a ssh session to monitor: tail -f /var/squid/logs/cache.log

      • In Proxy Filter Squidguard/Target Categories: Define a dummy custom target category. Name: Dummy. Description: Dummy custom target category (fix: squid & squid guard not auto starting after reboot). (remaining parameters blank)

      • In Proxy Filter Squidguard/Common Access Control List: In Target Rules, find your dummy target category and set access to deny to create the missing blacklist directory

      • Go to General Settings and select Apply to activate the configuration update

      • Your monitoring tail of cache.log will immediately start to scroll indicating successful implementation of the work-around

      • Advisable to do a Configuration Backup (Diagnostics/Backup/Restore)

      • Do a restart and validate that squid and squid guard services now successfully autostarts

      B R

      //Jimmy

      1 Reply Last reply Reply Quote 1
      • R
        rootchick
        last edited by

        Thanks!  This appears to work for squid 2 as well.  :D

        1 Reply Last reply Reply Quote 0
        • A
          aGeekhere
          last edited by

          It worked, been having this issue for a long time, thank you!!!

          Never Fear, A Geek is Here!

          1 Reply Last reply Reply Quote 0
          • M
            mzarrugh
            last edited by

            Thank you for fixing this age old problem! Now would you kindly tell me how to transparently cache https (man in the middle) thanks! ;D

            1 Reply Last reply Reply Quote 0
            • KOMK
              KOM
              last edited by

              Now would you kindly tell me how to transparently cache https (man in the middle) thanks! ;D

              Don't.  It breaks the web and it hurts your brain.  Use WPAD instead.

              https://doc.pfsense.org/index.php/WPAD_Autoconfigure_for_Squid

              1 Reply Last reply Reply Quote 0
              • H
                HooKed
                last edited by

                I had this same problem for a while until i found this post.
                I'm using:

                2.2.6-RELEASE (i386)
                built on Mon Dec 21 14:50:36 CST 2015
                FreeBSD 10.1-RELEASE-p25

                This still seems to be a problem in the current release I'm using.

                As of now the "fix" still works as described above.

                1 Reply Last reply Reply Quote 0
                • L
                  limarodrigo74
                  last edited by

                  Hello my friends, some time ago I did a video explaining how to do this solution on pfsense, here is the link:

                  https://www.youtube.com/watch?v=oQf96j8TdjQ

                  Regards

                  1 Reply Last reply Reply Quote 0
                  • M
                    mzarrugh
                    last edited by

                    @KOM:

                    Now would you kindly tell me how to transparently cache https (man in the middle) thanks! ;D

                    Don't.  It breaks the web and it hurts your brain.  Use WPAD instead.

                    https://doc.pfsense.org/index.php/WPAD_Autoconfigure_for_Squid

                    Thanks. Is this good for caching HTTPS data or is it purposed for traffic filtering only? I'm more interested in caching to save on data.

                    1 Reply Last reply Reply Quote 0
                    • R
                      redeyes
                      last edited by

                      Thanks for post (Y)

                      I would like to emphasise on ( restarting ) your router

                      1 Reply Last reply Reply Quote 0
                      • A
                        allxi
                        last edited by

                        Package/Proxy Server: Cache Management/Local Cache/ Clear Disk Cache NOW and start Squid3/SquidGuard

                        1 Reply Last reply Reply Quote 0
                        • C
                          chrcoluk
                          last edited by

                          Hi guys, I added the dummy target but it still wont start, the log just shows it starts then stops immediately.

                          pfSense CE 2.7.2

                          1 Reply Last reply Reply Quote 0
                          • T
                            Tommyboy
                            last edited by

                            @chrcoluk:

                            Hi guys, I added the dummy target but it still wont start, the log just shows it starts then stops immediately.

                            I have the same issue. Can't start squidguard :

                            • pfSense 2.4.2-RELEASE-p1 (arm) on Netgate SG-3100
                            • SquidGuard 1.16.4
                            • Under 'General settings'-tab I entered the Balcklist URL : http://www.shallalist.de/Downloads/shallalist.tar.gz + clicked 'Download'
                            • Under 'target directories'-tab I create a dummy category
                            • Under 'Common ACL'-tab I selected some categories from the categories including my dummy category.
                            • Under 'General Settings'-tab I enabled squidguard and  tried to start. But it remains in SquidGuard service state: STOPPED
                            • In the log I see that I starts and immediately stops.

                            Can someone please advise?

                            Thomas.

                            1 Reply Last reply Reply Quote 0
                            • AMBEU SergeA
                              AMBEU Serge
                              last edited by

                              Hello @Idawallace,

                              Thank you for the answer but this link does not mention a tutorial on the subject. Can you give us the direct link explaining how to solve the problem?

                              Best regards

                              1 Reply Last reply Reply Quote 0
                              • S
                                sarasaunders Banned
                                last edited by

                                This post is deleted!
                                AMBEU SergeA 1 Reply Last reply Reply Quote 0
                                • AMBEU SergeA
                                  AMBEU Serge @sarasaunders
                                  last edited by

                                  @sarasaunders Thanks to you for help, we will get back to you after our tests.

                                  1 Reply Last reply Reply Quote 0
                                  • J
                                    jennifercharles Banned
                                    last edited by

                                    This post is deleted!
                                    1 Reply Last reply Reply Quote 0
                                    • First post
                                      Last post
                                    Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.