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

    SquidGuard.conf is not changed by pfSense GUI

    pfSense Packages
    2
    13
    17.5k
    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.
    • I
      igorhmm
      last edited by

      Hello all,

      I've installed pfSense (1.2-RC4), squid (2.6.18.1) and squidGuard (1.2.0_1)

      I make some changes via pfSense GUI but my squidGuard.conf was't changed :-(

      But.. squidguard_conf.xml was changed successfully !

      I tried change permissions but doesn't works :-(

      # ls -l
      total 6
      -rwxr-x---  1 proxy  proxy   940 May  1 11:54 blacklist.files
      -rwxrwxrwx  1 proxy  proxy   465 May  1 12:22 squidGuard.conf
      -rw-r--r--  1 root   proxy  1635 May  1 12:10 squidguard_conf.xml
      # cat squidGuard.conf 
      
      # ============================================================
      # SquidGuard configuration file
      #
      # This file generated automaticly with SquidGuard configurator
      #
      # (C)2006 Serg Dvoriancev
      # email: dv_serg@mail.ru
      # ============================================================
      
      logdir /var/squidGuard/log
      dbhome /var/db/squidGuard
      
      acl {
      	 default { 
      		 pass none
      		 redirect http://192.168.1.1/sgerror.php?url=&a=%a&n=%n&i=%i&s=%s&t=%t&u=%u
      		 log block.log
      	 }
      }
      # 
      
      

      Anybody have an idea about what's happening? I already search on google and forum history and can't found anything :-(

      Thanks

      Igor

      1 Reply Last reply Reply Quote 0
      • D
        dvserg
        last edited by

        If You have incorrect config data, then created this config ("black all rule");
        View GUI log for found error.

        SquidGuardDoc EN  RU Tutorial
        Localization ru_PFSense

        1 Reply Last reply Reply Quote 0
        • I
          igorhmm
          last edited by

          @dvserg:

          If You have incorrect config data, then created this config ("black all rule");
          View GUI log for found error.

          hi dvserg :)

          before anything, thanks for the fast reply!

          based on your answer I've tried uninstall and reinstall squidGuard.. but now I got an error when I open squidGuard GUI:

          Warning: fopen(/usr/local/etc/squidGuard/squidguard_conf.xml): failed to open stream: No such file or directory in /etc/inc/pfsense-utils.inc on line 1094 Warning: fwrite(): supplied argument is not a valid stream resource in /etc/inc/pfsense-utils.inc on line 1095 Warning: fclose(): supplied argument is not a valid stream resource in /etc/inc/pfsense-utils.inc on line 1096

          I guess have anything wrong… may be permissions? Thanks

          Igor

          1 Reply Last reply Reply Quote 0
          • D
            dvserg
            last edited by

            Yes - this is permissions. You can delete xml and conf file - this will generated automaticly.

            SquidGuardDoc EN  RU Tutorial
            Localization ru_PFSense

            1 Reply Last reply Reply Quote 0
            • I
              igorhmm
              last edited by

              @dvserg:

              Yes - this is permissions. You can delete xml and conf file - this will generated automaticly.

              thanks again :)

              I check permissions and files was created… but never is updated :-(

              I've create new ACL and new Destinations and .conf wasn't changed!

              After some tests I've deleted the squidGuard.conf and this file wasn't created again too...

              Any idea?

              Thanks

              1 Reply Last reply Reply Quote 0
              • D
                dvserg
                last edited by

                Check "View GUI log" option, then Save
                Press Apply button and looking "Web GUI log (Latest 50)"
                What errors you view?

                SquidGuardDoc EN  RU Tutorial
                Localization ru_PFSense

                1 Reply Last reply Reply Quote 0
                • I
                  igorhmm
                  last edited by

                  @dvserg:

                  Check "View GUI log" option, then Save
                  Press Apply button and looking "Web GUI log (Latest 50)"
                  What errors you view?

                  sorry.. I forgot to paste the log.. :-(

                  [b]Web GUI log (Latest 50)[/b]
                  /var/squidGuard/log/sg_configurator.log
                  01.05.2008 14:25:08 : sg_reconfigure_user_db: begin at '/var/db/squidGuard'
                  01.05.2008 14:25:08 : sg_reconfigure_user_db: STOPPED; User destinations list empty
                  01.05.2008 14:25:08 : sg_reconfigure_user_db: end.
                  01.05.2008 14:25:08 : sg_build_config: add Default
                  01.05.2008 14:25:08 : sg_redirector_base_url: select redirector base url (http://192.168.1.1/sgerror.php?url=&a=%a&n=%n&i=%i&s=%s&t=%t&u=%u)
                  01.05.2008 14:25:08 : sg_reconfigure: generate squidGuard config and save to /usr/local/etc/squidGuard/squidGuard.conf.
                  01.05.2008 14:25:08 : squid_reconfigure: add new redirector options to Squid config.
                  
                  

                  But my destinations list isn't empty.. there are 1 list with 2 domains.

                  Thanks

                  1 Reply Last reply Reply Quote 0
                  • I
                    igorhmm
                    last edited by

                    Hi.. I made some changes and now in log was everything ok:

                    Web GUI log (Latest 50)
                    /var/squidGuard/log/sg_configurator.log
                    01.05.2008 14:45:51 : squid_reconfigure: add new redirector options to Squid config.
                    01.05.2008 14:47:25 : sg_reconfigure_user_db: begin at '/var/db/squidGuard'
                    01.05.2008 14:47:25 : sg_reconfigure_user_db: add user entries
                    01.05.2008 14:47:25 : sg_reconfigure_user_db: -- add dbFornecedores domains 'google.com terra.com.br'
                    01.05.2008 14:47:25 : sg_rebuild_db: Begin with path '/var/db/squidGuard'.
                    01.05.2008 14:47:25 : sg_create_rebuild_config: Begin with dbhome='/var/db/squidGuard'.
                    01.05.2008 14:47:25 : sg_create_rebuild_config: -- added item 'usr_dbFornecedores' = '/var/db/squidGuard/dbFornecedores'.
                    01.05.2008 14:47:25 : sg_redirector_base_url: select redirector base url (http://192.168.1.1/sgerror.php?url=404&a=%a&n=%n&i=%i&s=%s&t=%t&u=%u)
                    01.05.2008 14:47:25 : sg_rebuild_db: Create temporary config '/tmp/squidGuard_rebuild.conf_usrdb'.
                    01.05.2008 14:47:25 : sg_rebuild_db: Started SH script '/tmp/squidGuard_db_rebuild.sh_usrdb'.
                    01.05.2008 14:47:25 : sg_reconfigure_user_db: end.
                    01.05.2008 14:47:25 : sg_build_config: add sources
                    01.05.2008 14:47:25 : sg_build_config: add destinations
                    01.05.2008 14:47:25 : sg_build_config: added: 
                    dbFornecedores; 
                    
                    01.05.2008 14:47:25 : sg_build_config: add ACL
                    01.05.2008 14:47:25 : sg_build_config: added: 
                    Fornecedores; 
                    
                    01.05.2008 14:47:25 : sg_build_config: add Default
                    01.05.2008 14:47:25 : sg_redirector_base_url: select redirector base url (http://192.168.1.1/sgerror.php?url=&a=%a&n=%n&i=%i&s=%s&t=%t&u=%u)
                    01.05.2008 14:47:25 : sg_reconfigure: generate squidGuard config and save to /usr/local/etc/squidGuard/squidGuard.conf.
                    01.05.2008 14:47:25 : squid_reconfigure: remove old redirector options from Squid config.
                    01.05.2008 14:47:25 : squid_reconfigure: add new redirector options to Squid config.
                    
                    

                    But I got an error when I click on Apply button:

                    Warning: Invalid argument supplied for foreach() in /usr/local/pkg/squidguard_configurator.inc on line 1027 Warning: Invalid argument supplied for foreach() in /usr/local/pkg/squidguard_configurator.inc on line 1115 Warning: Cannot modify header information - headers already sent by (output started at /usr/local/pkg/squidguard_configurator.inc:1027) in /usr/local/www/pkg_edit.php on line 35
                    

                    And… I guess squidGuard is working fine.. just appears this error on apply :(

                    Thanks

                    1 Reply Last reply Reply Quote 0
                    • D
                      dvserg
                      last edited by

                      Pls check permissions
                      /var/db/squidGuard and subdirs(files) - 755/proxy
                      /usr/local/etc/squidGuard & subfiles - 755/proxy

                      squidGuard.conf file also duplicated to '/usr/local/etc/squid' directory (but worked only with '/usr/local/etc/squidGuard')

                      SquidGuardDoc EN  RU Tutorial
                      Localization ru_PFSense

                      1 Reply Last reply Reply Quote 0
                      • D
                        dvserg
                        last edited by

                        I found problem

                        Warning: Invalid argument supplied for foreach() in /usr/local/pkg/squidguard_configurator.inc on line 1027

                        Big thanks (will fixed next week).
                        Now SG worked?

                        SquidGuardDoc EN  RU Tutorial
                        Localization ru_PFSense

                        1 Reply Last reply Reply Quote 0
                        • I
                          igorhmm
                          last edited by

                          @dvserg:

                          Pls check permissions
                          /var/db/squidGuard and subdirs(files) - 755/proxy
                          /usr/local/etc/squidGuard & subfiles - 755/proxy

                          squidGuard.conf file also duplicated to '/usr/local/etc/squid' directory (but worked only with '/usr/local/etc/squidGuard')

                          I've upload the blacklist again and changed the permissions.. now is working perfectly !!!

                          Thanks a lot and really thanks for the fast reply :)

                          Regards

                          Igor

                          1 Reply Last reply Reply Quote 0
                          • D
                            dvserg
                            last edited by

                            @igorhmm:

                            I've upload the blacklist again and changed the permissions.. now is working perfectly !!!

                            You change permission manually or all changed auto?
                            (This info need for solve possible bugs)

                            SquidGuardDoc EN  RU Tutorial
                            Localization ru_PFSense

                            1 Reply Last reply Reply Quote 0
                            • I
                              igorhmm
                              last edited by

                              @dvserg:

                              @igorhmm:

                              I've upload the blacklist again and changed the permissions.. now is working perfectly !!!

                              You change permission manually or all changed auto?
                              (This info need for solve possible bugs)

                              I did manually:

                              
                              chmod -R 755 /var/db/squidGuard/usr /local/etc/squidGuard
                              chown -R proxy:proxy /var/db/squidGuard/usr /local/etc/squidGuard
                              
                              

                              thanks :D

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