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

    Want package for squidanalyzer. INSTRUCTIONS AND FILES TO INSTALL

    Scheduled Pinned Locked Moved Cache/Proxy
    94 Posts 18 Posters 28.6k 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.
    • T
      Topper727
      last edited by

      I looked up the new version.. seems nothing new yet or I missed it. mine is still working quite well. love to see how many hits in percents and all that per day and all that stuff..shows me squid proxy is working and if I make a change I can see maybe a increase or decrease in stuff proxy caches.. Nice to have

      Dell 2950 g3 server
      Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
      Current: 2000 MHz, Max: 2667 MHz
      8 CPUs: 2 package(s) x 4 core(s)
      8152 MiB and 600meg 10k drive
      Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

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

        Wish someone with package skills could turn this into package for all of us.  Nice reporting tool

        Dell 2950 g3 server
        Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
        Current: 2000 MHz, Max: 2667 MHz
        8 CPUs: 2 package(s) x 4 core(s)
        8152 MiB and 600meg 10k drive
        Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

        1 Reply Last reply Reply Quote 0
        • K
          killmasta93
          last edited by

          awsome stuff :)

          But cant seem to install perl it says that its not in the repository, I also tried looking for perl it did show up on some files.

          any idea?

          Updating FreeBSD repository catalogue...
          FreeBSD repository is up-to-date.
          All repositories are up-to-date.
          pkg: No packages available to install matching 'perl5.16-5.16.3_18' have been fo
          

          then tried installing perl

          pkg install perl5
          

          then ran your command

          cd /temp/squidanalyzer/ && perl squid-analyzer -r -c /etc/squidanalyzer/squidanalyzer.conf /var/squid/logs/access.log
          perl: Command not found.
          
          

          Thank you

          Clipboarder.2016.01.02-002.png
          Clipboarder.2016.01.02-002.png_thumb
          Clipboarder.2016.01.02-005.png
          Clipboarder.2016.01.02-005.png_thumb

          Tutorials:

          https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

            I will get my notes tonight and see what can help.  Just wanted drop a line sayjng i relead this and will help later today

            Dell 2950 g3 server
            Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
            Current: 2000 MHz, Max: 2667 MHz
            8 CPUs: 2 package(s) x 4 core(s)
            8152 MiB and 600meg 10k drive
            Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

            1 Reply Last reply Reply Quote 0
            • K
              killmasta93
              last edited by

              Thanks mate really good stuff :)

              Tutorials:

              https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

                When I ran pkg install perl5 I got this

                FreeBSD repository update completed. 24761 packages processed.
                New version of pkg detected; it needs to be installed first.
                The following 1 package(s) will be affected (of 0 checked):

                Installed packages to be UPGRADED:
                        pkg: 1.5.6 -> 1.6.2

                The process will require 148 KiB more space.
                2 MiB to be downloaded.

                Proceed with this action? [y/N]:

                I wonder if there is something with your repository lists.

                Dell 2950 g3 server
                Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                Current: 2000 MHz, Max: 2667 MHz
                8 CPUs: 2 package(s) x 4 core(s)
                8152 MiB and 600meg 10k drive
                Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

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

                  what happens if you type

                  perl -v

                  I get

                  [2.2.6-RELEASE][admin@firewall.wholesale-florida.com]/temp/squidanalyzer: perl -v

                  This is perl 5, version 20, subversion 2 (v5.20.2) built for amd64-freebsd-thread-multi

                  Copyright 1987-2015, Larry Wall

                  Perl may be copied only under the terms of either the Artistic License or the
                  GNU General Public License, which may be found in the Perl 5 source kit.

                  Complete documentation for Perl, including FAQ lists, should be found on
                  this system using "man perl" or "perldoc perl".  If you have access to the
                  Internet, point your browser at http://www.perl.org/, the Perl Home Page.

                  maybe type

                  rehash

                  Then your perl -v again if it not works

                  Dell 2950 g3 server
                  Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                  Current: 2000 MHz, Max: 2667 MHz
                  8 CPUs: 2 package(s) x 4 core(s)
                  8152 MiB and 600meg 10k drive
                  Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

                  1 Reply Last reply Reply Quote 0
                  • K
                    killmasta93
                    last edited by

                    Hi Topper,
                    Thank you for the reply,
                    I seems that perl is installed and working i guess but when i run your command

                    cd /temp/squidanalyzer/ && perl squid-analyzer -r -c /etc/squidanalyzer/squidanalyzer.conf /var/squid/logs/access.log
                    

                    I get Fatal no configuration file

                    But i do have the squid analyzer webui

                    See pictures

                    Thank you

                    Clipboarder.2016.01.18-002.png
                    Clipboarder.2016.01.18-002.png_thumb
                    Clipboarder.2016.01.18-003.png
                    Clipboarder.2016.01.18-003.png_thumb
                    Clipboarder.2016.01.18-004.png
                    Clipboarder.2016.01.18-004.png_thumb
                    Clipboarder.2016.01.18-005.png
                    Clipboarder.2016.01.18-005.png_thumb

                    Tutorials:

                    https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

                      Ah .. make sure you have this file

                      /etc/squidanalyzer/squidanalyzer.conf

                      It should have this inside

                      This file is the default configuration file for SquidAnalyzer

                      Edit it to match your needs and copy it under /etc/squidanalyzer/squidanalyzer.conf

                      Path where SquidAnalyzer should dump all HTML and images files.

                      Choose a path that can  be read by a Web browser

                      Output /usr/local/www/squidanalyzer

                      The URL of the SquidAnalyzer javascript, HTML and images files.

                      WebUrl /squidanalyzer

                      Set the path to the Squid log file

                      LogFile /var/squid/logs/access.log

                      If you want to use DNS name instead of client Ip address as username enable

                      this directive. When you don't have authentication, the username is set to

                      the client ip address, this allow you to use the DNS name instead.

                      Note that you must have a working DNS resolution and that it can really slow

                      down the generation of reports.

                      UseClientDNSName 1

                      If you have enabled UseClientDNSName and have lot of ip addresses that do

                      not resolve you may want to increase the DNS lookup timeout. By default

                      SquidAnalyzer will stop to lookup a DNS name after 0.0001 second (100 ms).

                      DNSLookupTimeout 0.001

                      Set the file containing network alias name. Network are

                      show as Ip addresses so if you want to display name instead

                      create a file with this format :

                      LOCATION_NAME IP_NETWORK_ADDRESS

                      Separator must be a tabulation

                      NetworkAlias /etc/squidanalyzer/network-aliases

                      Set the file containing user alias name. If you don't have auth_proxy

                      enable user are seen as Ip addresses, or if you want to replace login

                      name by full user name, create a file with this format :

                      FULL_USERNAME IP_ADDRESS || LOGIN_NAME

                      Separator must be a tabulation

                      UserAlias /etc/squidanalyzer/user-aliases

                      How do we sort Network, User and Url report screen

                      Value can be: bytes, hits or duration. Default is bytes.

                      OrderNetwork bytes
                      OrderUser bytes
                      OrderUrl bytes

                      How do we sort Mime types report screen

                      Value can be: bytes or hits. Default is bytes.

                      OrderMime bytes

                      Should we display user URL details. This will show all URL read

                      by user. Take care to have enougth space disk for large user.

                      UrlReport 1

                      Should we display user details. This will show statistics

                      per user.

                      UserReport 1

                      Run in quiet mode or print debug information

                      QuietMode 1

                      Cost of the bandwith per Mb. If you want to generate invoice per Mb

                      for bandwith traffic this can help you. Value 0 mean no cost.

                      CostPrice 0

                      Currency of the bandwith cost

                      Currency €

                      Top number of url to show

                      TopNumber 100

                      Path to the file containing client ip addresses, network ip address,

                      and/or auth login to exclude from report

                      Exclude /etc/squidanalyzer/excluded

                      Path to the file containing client ip addresses, network ip address,

                      and/or auth login to include into the report. Other entries will be

                      excluded by default.

                      Include /etc/squidanalyzer/included

                      Translation Lang /etc/squidanalyzer/lang/en_US.txt,

                      en_US.txt, ru_RU.txt, uk_UA.txt, cs_CZ.txt, pl_PL.txt and de_DE.txt).

                      Default to:

                      Lang /etc/squidanalyzer/lang/en_US.txt

                      Date format used to display date (year = %y, month = %m and day = %d)

                      You can also use %M to replace month by its 3 letters abbreviation.

                      DateFormat %y-%m-%d

                      Set this to 1 if you want to anonymize all user login. The username

                      will be replaced by an unique id that change at each squid-analyzer

                      run. Default disable.

                      AnonymizeLogin 0

                      Adds peer cache hit (CD_SIBLING_HIT) to be taken has local cache hit.

                      Enabled by default, you must disabled it if you don't want to report

                      peer cache hit onto your stats.

                      SiblingHit 1

                      Set the default unit for transfert size. Default is BYTES, other possible

                      values are KB, MB and GB

                      TransfertUnit BYTES

                      Minimum percentage of data in pie's graphs to not be placed in the others item.

                      MinPie 2

                      Set this to your locale to display generated date in your language. Default

                      is to use strftime. If you want date in German for example, set it to de_DE.

                      For french, fr_FR should do the work.

                      Locale en_US

                      By default SquidAnalyzer is saving current collected statistics each time

                      a new hour is found in log file. Most of the time this is enough but if

                      you have huge log file and don't have enough memory this will slow down the

                      parser by forcing Perl to use temporaries files. Use lower value following

                      your memory and the size of your log file, on very huge log file with lot of

                      requests/seconde a value of 30 minutes (1800) or less should help.

                      WriteDelay 3600

                      Use this directive to show the top N users that look at an URL or a domain.

                      Set it to 0 to disable this feature.

                      TopUrlUser 10

                      This directive allow you to replace the SquidAnalyze logo by your custom

                      logo. The default value is defined as follow:

                      [#

                      #]($self->{WebUrl}) SquidAnalyzer

                      Feel free to define your own header but take care to not break current design.

                      #CustomHeader My ISP Company

                      This directive allow exclusion of some unwanted methods in report statistics

                      like HEAD, POST, CONNECT, etc. Can be a comma separated list of methods.

                      #ExcludedMethods HEAD

                      This directive allow exclusion of some unwanted mimetypes in report statistics

                      like text/html, text/plain, or more generally text/*, etc. Can be a comma separated

                      list of perl regular expression.

                      #ExcludedMimes text/.,image/.

                      This directive allow exclusion of some unwanted codes in report statistics

                      like TCP_DENIED/403 which are generated when a user accesses a page the first

                      time without authentication. Can be a comma separated list of methods.

                      #ExcludedCodes TCP_DENIED/403

                      https://www.dropbox.com/s/vtf7loy2x9lnhl3/squidanalyzer.conf?dl=0

                      download this file, run winscp and put in the folder on your firewall of
                      /etc/squidanalyzer/

                      This should of been created by unzipping the files from my original zip. Not sure why it failed there.  If file exists maybe permission?

                      squidanalyzer.png
                      squidanalyzer.png_thumb

                      Dell 2950 g3 server
                      Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                      Current: 2000 MHz, Max: 2667 MHz
                      8 CPUs: 2 package(s) x 4 core(s)
                      8152 MiB and 600meg 10k drive
                      Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

                      1 Reply Last reply Reply Quote 0
                      • K
                        killmasta93
                        last edited by

                        ooOOOooo

                        I thought i could unzip it and put though winscp oh oh

                        Alright re did your guide I put
                        squidanalyzer.rar into /usr/local/www  then on putty rancd /usr/local/www then```
                        tar -xzf squidanalyzer.rar

                        
                        Worked fine
                        
                        Then temp.rar  into /      In putty ran```
                        cd /
                        ```then```
                        tar -xzf temp.rar
                        

                        and got this error```
                        temp/squidanalyzer/.git/objects/pack/pack-ef251a8f0489dcdb37651a0598fe5e498ffee007.idx: Parsing filters is unsupported.

                        
                        then i exited it out to just run the command```
                        tar -xzf temp.rar
                        

                        and got this error```
                        tar: Error opening archive: Failed to open 'temp.rar'

                        
                        ??? ???
                        
                        Thank you
                        
                        ![Clipboarder.2016.01.18-009.png](/public/_imported_attachments_/1/Clipboarder.2016.01.18-009.png)
                        ![Clipboarder.2016.01.18-009.png_thumb](/public/_imported_attachments_/1/Clipboarder.2016.01.18-009.png_thumb)

                        Tutorials:

                        https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

                        1 Reply Last reply Reply Quote 0
                        • K
                          killmasta93
                          last edited by

                          Allright so I bought myself a new comp so I had to format pfSense tried to add it again and no luck this time i added the directory

                          to etc

                          So when running the command

                           cd /temp/squidanalyzer/ && perl squid-analyzer -r -c /etc/squidanalyzer/squidanalyzer.conf /var/squid/logs/access.log
                          
                          

                          I would get

                          ERROR: you must give a valid output directory. See option: Output
                          

                          But isn't the output directory the /var/squid/logs/access.log

                          Thank you

                          Clipboarder.2016.01.30-006.png
                          Clipboarder.2016.01.30-006.png_thumb
                          Clipboarder.2016.01.30-007.png
                          Clipboarder.2016.01.30-007.png_thumb
                          Clipboarder.2016.01.30-009.png
                          Clipboarder.2016.01.30-009.png_thumb
                          Clipboarder.2016.01.30-010.png
                          Clipboarder.2016.01.30-010.png_thumb

                          Tutorials:

                          https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

                            Yes, I also noticed that perl version is now gone from the repository.  I will have to find out what perl will work and not break a system.  As far as the zip file error I think it is bad copy.. I re installed my firewall just recently so I will put this squidanalyzer back in when I do I will update the install steps again to include the new perl and new files if needed

                            Dell 2950 g3 server
                            Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                            Current: 2000 MHz, Max: 2667 MHz
                            8 CPUs: 2 package(s) x 4 core(s)
                            8152 MiB and 600meg 10k drive
                            Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

                            1 Reply Last reply Reply Quote 0
                            • K
                              killmasta93
                              last edited by

                              thanks hopefully it goes well :)

                              Also I had lightsquid before and umm…i think it broke it :( any way to fix perl again to get lightsquid working?

                              Thank you

                              Tutorials:

                              https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

                                Lightsquid hmm not really looked into what it uses to run.  Squidanalyzer is so much more indepth .. wish someone would make a package for it. I am not really that skilled to make yet. and not know the system well enough to know if I will break something till I try it.

                                I may try tomorrow to get squid analyzer going again. if so I post what I did. I got a clean machine here as I reinstalled cause of too much modding to it got it messy..

                                Dell 2950 g3 server
                                Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                                Current: 2000 MHz, Max: 2667 MHz
                                8 CPUs: 2 package(s) x 4 core(s)
                                8152 MiB and 600meg 10k drive
                                Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

                                1 Reply Last reply Reply Quote 0
                                • K
                                  killmasta93
                                  last edited by

                                  Thanks man :) you made something really special  ;D appreciate your work

                                  Tutorials:

                                  https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

                                  1 Reply Last reply Reply Quote 0
                                  • F
                                    foxnet8
                                    last edited by

                                    got this working on my virtualbox THANKS your the MAN! ;)

                                    1 Reply Last reply Reply Quote 0
                                    • K
                                      killmasta93
                                      last edited by

                                      care to share?

                                      Tutorials:

                                      https://www.mediafire.com/folder/v329emaz1e9ih/Tutorials

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

                                        Well I got it working again. I just copied the files in my tutorial into the /temp/squidanalyzer for the temp.rar (which I had to extract in windows then copy the files over to the directory.

                                        Then the squidanalyzer.rar I copied into /usr/local/www/squidanalyzer

                                        Perl was already version 1.6.2 in my
                                        2.2.6-RELEASE (amd64)
                                        built on Mon Dec 21 14:50:08 CST 2015
                                        FreeBSD firewall.wholesale-florida.com 10.1-RELEASE-p25 FreeBSD 10.1-RELEASE-p25 #0 c39b63e(releng/10.1)-dirty: Mon Dec 21 15:20:13 CST 2015 root@pfs22-amd64-builder:/usr/obj.RELENG_2_2.amd64/usr/pfSensesrc/src.RELENG_2_2/sys/pfSense_SMP.10 amd64

                                        Version

                                        Dell 2950 g3 server
                                        Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                                        Current: 2000 MHz, Max: 2667 MHz
                                        8 CPUs: 2 package(s) x 4 core(s)
                                        8152 MiB and 600meg 10k drive
                                        Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

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

                                          Oh I do need the /temp/squidanalyzer folder.. hmm finding which perl will work.

                                          pkg install perl5-5.20.3_8

                                          This seems to put the perl back and not break anything but can't get new data to come in with that

                                          cd /temp/squidanalyzer/ && perl squid-analyzer -r -c /etc/squidanalyzer/squidanalyzer.conf /var/squid/logs/access.log /var/squid/logs/

                                          I did have to put the files in /etc/squidanalyzer this is why some get missing config.

                                          Dell 2950 g3 server
                                          Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                                          Current: 2000 MHz, Max: 2667 MHz
                                          8 CPUs: 2 package(s) x 4 core(s)
                                          8152 MiB and 600meg 10k drive
                                          Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

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

                                            ok got it!

                                            this is command that worked

                                            cd /temp/squidanalyzer/ && perl squid-analyzer -d -l /etc/squidanalyzer/squidanalyzer.conf /var/squid/logs/access.log /var/squid/logs/

                                            screencapture-192-168-5-1-squidanalyzer-2016-02-index-html-1455000167666.png
                                            screencapture-192-168-5-1-squidanalyzer-2016-02-index-html-1455000167666.png_thumb

                                            Dell 2950 g3 server
                                            Intel(R) Xeon(R) CPU E5430 @ 2.66GHz
                                            Current: 2000 MHz, Max: 2667 MHz
                                            8 CPUs: 2 package(s) x 4 core(s)
                                            8152 MiB and 600meg 10k drive
                                            Pfsense 2.4 .. Hoping to get the phpvirtualbox going again.

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