Navigation

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

    I can't get SARG Report working

    pfSense Packages
    11
    31
    10739
    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.
    • A
      aityahiaidir last edited by

      Hello all

      i have Installed Squid3 with Squidguard 3 and it is impossible to get SARG report working, the realtime statut work correctly

      i get the following error

      Error: Could not find report index file.
      Check and save sarg settings and try to force sarg schedule.

      this is my system logs

       	php-fpm[43629]: /pkg_edit.php: Sarg: force refresh now with args, compress(on) and none action after sarg finish.
      
      php-fpm[43629]: /pkg_edit.php: The command 'export LC_ALL=C && /usr/pbi/sarg-i386/bin/sarg ' returned exit code '1', the output was 'SARG: Records in file: 37469, reading: 0.00%^MSARG: Records in file: 5000, reading: 13.34%^MSARG: Records in file: 10000, reading: 26.69%^MSARG: Records in file: 15000, reading: 40.03%^MSARG: Records in file: 20000, reading: 53.38%^MSARG: Records in file: 25000, reading: 66.72%^MSARG: Records in file: 30000, reading: 80.07%^MSARG: Records in file: 35000, reading: 93.41%^MSARG: (repday) Cannot open log file /usr/local/sarg-reports/2015/01/24-25/9/d9.html SARG: Records in file: 37469, reading: 100.00%'
      

      i have tried this solution without success
      http://www.webkeydesign.com/416/fix-sarg-reports-in-pfsense/

      1 Reply Last reply Reply Quote 0
      • marcelloc
        marcelloc last edited by

        Maybe just a symlinks from sarg-reports dir under  /usr/pbi.. to /usr/local/sarg-reports

        Treinamentos de Elite: http://sys-squad.com

        Help a community developer! ;D

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

          thanks for replay

          my sarg.conf appear to be good ,i have this in report-dir

          output_dir /usr/local/sarg-reports
          

          and the path exist really

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

            i have find my report, they are generated in folder

            /usr/pbi/sarg-i386/local/sarg-reports
            

            where can i edit to put the correct  path, that my reports are accessible from "View Report" Tab

            1 Reply Last reply Reply Quote 0
            • marcelloc
              marcelloc last edited by

              Remove /usr/local/sarg-reports  and
              Symlink it to pbi dir

              
              ln -s /usr/pbi/sarg-i386/local/sarg-reports /usr/local/sarg-reports
              

              Treinamentos de Elite: http://sys-squad.com

              Help a community developer! ;D

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

                @marcelloc:

                Remove /usr/local/sarg-reports  and
                Symlink it to pbi dir

                 
                ln -s /usr/pbi/sarg-i386/local/sarg-reports /usr/local/sarg-reports
                

                i have tried this without success, what's do you mean by  "Remove /usr/local/sarg-reports"
                physically remove the folder ? or is something else

                1 Reply Last reply Reply Quote 0
                • D
                  doktornotor Banned last edited by

                  @aityahiaidir:

                  physically remove the folder ?

                  Yeah, bit of delicate fine tuning involving HDD platters and a chisel. (Make sure to stop the relevant services first, so that the bits stop moving on the platters, otherwise the job is kinda difficult to complete.)

                  For unexperienced/faint-hearted ones, perhaps

                  rm -rf /usr/local/sarg-reports
                  

                  could be an acceptable workaround.

                  ;D ;D ;D

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

                    thank dok  ;D

                    but this is still not working, i have always this frightful message  >:(

                    Error: Could not find report index file.
                    Check and save sarg settings and try to force sarg schedule.

                    1 Reply Last reply Reply Quote 0
                    • marcelloc
                      marcelloc last edited by

                      Remove the folder and then create the Symlink  ;)

                      The results should be /usr/local/sarg-reports with your report files.

                      Treinamentos de Elite: http://sys-squad.com

                      Help a community developer! ;D

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

                        @marcelloc:

                        Remove the folder and then create the Symlink  ;)

                        The results should be /usr/local/sarg-reports with your report files.

                        yes i do both tasks, bu it still not working, it would seem that the problem is elsewhere, it's still weird, it's a bug, it should work without resorting to all this complexity  :-\

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

                          :o it is a bug, when i select site_user and user_site from report type, its work
                          the bug is mentioned here

                          http://sourceforge.net/p/sarg/bugs/154/

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

                            it should work without resorting to all this complexity

                            I agree, and these problems have been hanging around since before 2.1.x.  I've always had to fight with Lightsquid and Sarg.  Always.  They should just work or be removed from the repository.  I know the base system is where all the real action is, but people's opinion of the project can be heavily influenced by the experience they have with the packages.  Broken packages that remain broken after 1+ years just looks bad.

                            1 Reply Last reply Reply Quote 0
                            • marcelloc
                              marcelloc last edited by

                              @KOM:

                              They should just work or be removed from the repository.

                              Or instead of just watching, using and complaining, start to contributing.

                              Github is not that complex to use.

                              https://www.pfsense.org/get-involved/

                              Treinamentos de Elite: http://sys-squad.com

                              Help a community developer! ;D

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

                                I have very good knowledge in PHP, I'll try to help, but first I have to understand the operation mechanism of Sarg generating report  ;)

                                1 Reply Last reply Reply Quote 0
                                • marcelloc
                                  marcelloc last edited by

                                  @aityahiaidir:

                                  I have very good knowledge in PHP, I'll try to help, but first I have to understand the operation mechanism of Sarg generating report  ;)

                                  Great!  :)

                                  The pbi is the biggest problem today. It "jais" the package under /usr/pbi dir but a lot of libs and package conf files still looks for it on /usr/local

                                  All package gui files are on https://github.com/pfsense/pfsense-packages

                                  Pfsense 2.3 will move from pbi to pkg ng, but until it happens, we have to deal with this…

                                  Treinamentos de Elite: http://sys-squad.com

                                  Help a community developer! ;D

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

                                    Or instead of just watching, using and complaining, start to contributing.

                                    Pardon me, but I do believe that I contribute LOTS here, for free, in my spare time.  I have almost the same karma as you with 1/10th the posts.  I'm not a developer or I would have fixed these frustrations long ago.  The arrogant answer "Fix it yourself or shut up" may play well on Slashdot, but it is not a practical solution for most people.  All I can do here is to learn the hacky workarounds to these lingering problems and then pass them along to others when they inevitably run into the same problems.

                                    1 Reply Last reply Reply Quote 0
                                    • marcelloc
                                      marcelloc last edited by

                                      @KOM:

                                      Pardon me, but I do believe that I contribute LOTS here, for free, in my spare time.

                                      Me too. And after creating and maintaining some packages I'm spending more then free time to keep it working on version changes.
                                      Just an example, I'm working together with Renato and cino since december to get squid working with 2.2 and pbis and it's still not finished.

                                      @KOM:

                                      I have almost the same karma as you with 1/10th the posts.  I'm not a developer or I would have fixed these frustrations long ago.  The arrogant answer "Fix it yourself or shut up" may play well on Slashdot, but it is not a practical solution for most people.

                                      Sometimes contributing to comunity and/or the project is frustrating. Most people understands the hard work to keep it working but posts like Fix it or remove it! does sounds really arrogant to me.

                                      And I never posted things like "Fix it yourself or shut up" as you understood.

                                      Treinamentos de Elite: http://sys-squad.com

                                      Help a community developer! ;D

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

                                        I don't want to fight with you because I know you're a good guy and the team is under pressure right now.  I understand as I work for a software company and I am deeply involved in the development process here.  I want the pfSense  project to be seen in the best possible light because I actually care about it.  It's strange to be emotionally invested in the success of a software project, but it is what it is.  In that light, I feel personally embarrassed when new users try to get these very popular and common packages running, only to be frustrated because they don't seem to work.  That was the source of my Fix it or remove it comment.  If it doesn't work, it should be removed so as to not tarnish the project's image.  What is the point of having a broken package in the list, after all?  That is all I am trying to say.

                                        1 Reply Last reply Reply Quote 0
                                        • marcelloc
                                          marcelloc last edited by

                                          Ok, never mind.

                                          BTW,  I'm not from pfsense team.  Just a community user like many others…

                                          Treinamentos de Elite: http://sys-squad.com

                                          Help a community developer! ;D

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

                                            Oh, I had no idea.  I thought you were an employee of ESF.  My mistake.

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

                                              hello guys,

                                              By removing the /usr/local/sarg-reports folder and creating a symlink to /usr/pbi/amd-64/local/sarg-reports, it worked for me…

                                              Report options:
                                              graphics where possible
                                              remove temp files
                                              generate  main index
                                              generate index tree
                                              overwrite report
                                              show downloaded volume

                                              Reports to generate
                                              all selected

                                              versions
                                              Sarg : 2.3.9 v 0.6.4
                                              Squid : 3.4.10_2 0.2.6
                                              squidguard-suid3 : 1.4_7 v 1.9.6

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

                                                This works for 2.2:

                                                rm -r /usr/local/sarg-reports
                                                ln -s /usr/pbi/sarg-amd64/local/sarg-reports /usr/local/sarg-reports
                                                
                                                
                                                1 Reply Last reply Reply Quote 0
                                                • W
                                                  wcrowder last edited by

                                                  Simple solution, it really is. Run pfSense in one Virtural Machine and run Squid 3.5.1 (Squid is developed on FreeBSD) on another VM in a different subnet. Use wpad.dat/proxy.pac to seamlessly integrate the two.  Sarg works really well this way installed from packages. AND you will learn a lot doing it.

                                                  And it just works better this way.

                                                  1 Reply Last reply Reply Quote 0
                                                  • marcelloc
                                                    marcelloc last edited by

                                                    On freebsd ports, squid is still on 3.4

                                                    When it gets updated to 3.5 I'll update pfsense package.

                                                    Treinamentos de Elite: http://sys-squad.com

                                                    Help a community developer! ;D

                                                    1 Reply Last reply Reply Quote 0
                                                    • W
                                                      wcrowder last edited by

                                                      I never understood why Squid lags behind on FreeBSD ports. The official repository states that Squid is developed on FreeBSD and the generic compile instructions are for FreeBSD.

                                                      http://wiki.squid-cache.org/SquidFaq/CompilingSquid

                                                      Since I run pfSense on ESXi, it makes it very easy to just fire up a minimal VM and build Squid from source. It seems to me to be a cleaner setup this way and I have far less problems with adding utility to Squid when I need it. Sarg works great and has full functionality. As it is, I have less the $200.00us in my ESXi pfSense/Squid setup.

                                                      I'm only stating this as an option. I am not taking away from the fine pfSense Squid package.

                                                      1 Reply Last reply Reply Quote 0
                                                      • marcelloc
                                                        marcelloc last edited by

                                                        Seems a loop process. If Amos release a version and update it on ports, would be easier.

                                                        Thanks for the suggestion.

                                                        @wcrowder:

                                                        I'm only stating this as an option. I am not taking away from the fine pfSense Squid package.

                                                        :) I know.

                                                        Treinamentos de Elite: http://sys-squad.com

                                                        Help a community developer! ;D

                                                        1 Reply Last reply Reply Quote 0
                                                        • S
                                                          sujyo1 last edited by

                                                          Had same problem here. I try this and it working…

                                                          1. Reinstall Sarg Pkg

                                                          2. rm -rf /usr/local/sarg-reports

                                                          3. ln -s /usr/pbi/sarg-i386/local/sarg-reports /usr/local/sarg-reports

                                                          2.2-RELEASE (i386)
                                                          built on Thu Jan 22 14:04:25 CST 2015
                                                          FreeBSD 10.1-RELEASE-p4

                                                          Thank You Guys

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

                                                            confirming this worked for me too… i'm also on 64bit 2.2... THANKS!!!!

                                                            @KOM:

                                                            This works for 2.2:

                                                            rm -r /usr/local/sarg-reports
                                                            ln -s /usr/pbi/sarg-amd64/local/sarg-reports /usr/local/sarg-reports
                                                            
                                                            
                                                            1 Reply Last reply Reply Quote 0
                                                            • K
                                                              killmasta93 last edited by

                                                              Thank you KOM and sujyo1  :)

                                                              Tutorials:

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

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

                                                                i have the same problem

                                                                Error: Could not find report index file.
                                                                Check and save sarg settings and try to force sarg schedule.
                                                                

                                                                i try the Repair instructions in this Thread
                                                                no luck dont work

                                                                1 Reply Last reply Reply Quote 0
                                                                • P
                                                                  polymathp last edited by

                                                                  First of Kudos, respect and props to 'marcelloc' for the amazing package

                                                                  For those who still cannot get it working please remember follow the instructions for your version 32 bit or 64 bit

                                                                  32 bit

                                                                  1. Reinstall Sarg Pkg

                                                                  2. rm -rf /usr/local/sarg-reports

                                                                  3. ln -s /usr/pbi/sarg-i386/local/sarg-reports /usr/local/sarg-reports

                                                                  64 bit

                                                                  1. Reinstall Sarg Pkg

                                                                  2. rm -rf /usr/local/sarg-reports

                                                                  3. ln -s /usr/pbi/sarg-amd64/local/sarg-reports /usr/local/sarg-reports

                                                                  1 Reply Last reply Reply Quote 0
                                                                  • First post
                                                                    Last post