-
Notifications
You must be signed in to change notification settings - Fork 123
Install in Ubuntu
These instructions assume
- the user wants to install using the source package instead of distribution provided packaging
- access to 'root' account or user with admin permissions
- use only distribution release specific instructions
- some basic Linux skills
- commands aren't copypasted blindly
- that the process is stopped in case of errors
Open a terminal and gain root permissions
sudo -s -H
Verify that root has been gained
whoami
which should reply "root".
Install needed development packages
apt-get update
apt-get install make gcc libc6-dev wget libsqlite3-0 libsqlite3-dev
optional additional packages for image output support
apt-get install libgd3 libgd-dev
Get the latest release and extract it
cd /usr/src
wget https://humdi.net/vnstat/vnstat-2.12.tar.gz
tar zxvf vnstat-2.12.tar.gz
Compile and install the binaries
cd vnstat-2.12
./configure --prefix=/usr --sysconfdir=/etc && make && make install
Install the service file and start the daemon
cp -v examples/systemd/vnstat.service /etc/systemd/system/
systemctl enable vnstat
systemctl start vnstat
Verify that daemon process got started
pgrep -c vnstatd
which should reply "1". A reply of "0" indicates that the process has failed to start.
Open a terminal and gain root permissions
sudo -s -H
Verify that root has been gained
whoami
which should reply "root".
Install needed development packages
apt-get update
apt-get install make gcc libc6-dev wget libsqlite3-0 libsqlite3-dev
optional additional packages for image output support
apt-get install libgd3 libgd-dev
Get the latest release and extract it
cd /usr/src
wget https://humdi.net/vnstat/vnstat-2.12.tar.gz
tar zxvf vnstat-2.12.tar.gz
Compile and install the binaries
cd vnstat-2.12
./configure --prefix=/usr --sysconfdir=/etc && make && make install
Install the service file and start the daemon
cp -v examples/upstart/vnstat.conf /etc/init/
initctl start vnstat
Verify that daemon process got started
pgrep -c vnstatd
which should reply "1". A reply of "0" indicates that the process has failed to start.