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

    Vnstat problem

    Scheduled Pinned Locked Moved pfSense Packages
    4 Posts 2 Posters 2.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.
    • N Offline
      none
      last edited by

      hail,

      Just installed 1.2.3-RC1 to test my update to Release. I installed Backup package to save all data before th update, and then I got a problem with vnstat.

      I did backup for /usr/local/www/vnstat and by mistake I thought it was the data dir. teste machine, no problem. So I got the backup for this dir and restored in the test machine to see what happens (I though it was going to show traffic data as the rrd backup did). but then I saw the files I was looking for were in /var/db/vnstat. so I then got those to the test machine. that did the problem.

      when I try to access vnstat I get infinity lines of:

      Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php on line 71 Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php on line 71 Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php on line 71 Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php on line 71 Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php on line 71 Notice: Constant GRAPH_FONT already defined in /usr/local/www/vnstat/config.php on line 62 Notice: Constant SVG_FONT already defined in /usr/local/www/vnstat/config.php on line 65 Notice: Constant DEFAULT_COLORSCHEME already defined in /usr/local/www/vnstat/config.php
      

      I tried uninstall the package. no luck. I then uninstalled and deleted the /var/dv/vnstat, no luck either. the only file that remais from it is:

      # find . -name "*vnstat*"
      ./tmp/pkg_mgr_vnstat.log
      # 
      
      

      I reinstalled the package several times, same results.

      so, is really possible to backup that data (I really think it is, just messed up my box) and is there a solution for what I did ? (its a test machine, but I must get through this when I can loose data =] )

      thanks,

      none

      1 Reply Last reply Reply Quote 0
      • P Offline
        Perry
        last edited by

        I've just tested it and could read the /var/db/vnstat backup.
        What I did was:
        1. Backup /var/db/vnstat
        2. Reinstall pfSense and vnstat
        3. Overwrite the new /var/db/vnstat with the backup

        If nic's aren't the same you should rename them in the backup before you apply it.

        IMO it will be to risky to make a pfSense backup with package.

        /Perry
        doc.pfsense.org

        1 Reply Last reply Reply Quote 0
        • N Offline
          none
          last edited by

          @Perry:

          I've just tested it and could read the /var/db/vnstat backup.
          What I did was:
          1. Backup /var/db/vnstat
          2. Reinstall pfSense and vnstat
          3. Overwrite the new /var/db/vnstat with the backup

          If nic's aren't the same you should rename them in the backup before you apply it.

          IMO it will be to risky to make a pfSense backup with package.

          hail ;)

          by reinstall pfsense you mean from scratch ? deleting all data ? (I know backup all info before).

          and lastly, I measure my traffic using rrd and vnstat. so vnstat is quite vital for me. So you suggest I make two backups, on being pfsense itself and other all packages I have ?

          thanks,

          none

          1 Reply Last reply Reply Quote 0
          • P Offline
            Perry
            last edited by

            Yes from scratch

            When those kind of data is vital you have to use rsync,scp or wget for continual backup.

            /Perry
            doc.pfsense.org

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