These instructions assume
Open a terminal and gain root permissions
su -
Verify that root has been gained
whoami
which should reply "root".
Install needed development packages
yum install make gcc gd gd-devel wget sqlite sqlite-devel
Get the latest release and extract it
cd /usr/src wget http://humdi.net/vnstat/vnstat-2.10.tar.gz tar zxvf vnstat-2.10.tar.gz
Compile and install the binaries
cd vnstat-2.10 ./configure --prefix=/usr --sysconfdir=/etc && make all && make install
Install the service files 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
su -
Verify that root has been gained
whoami
which should reply "root".
Install needed development packages
yum install make gcc gd gd-devel wget sqlite sqlite-devel
Get the latest release and extract it
cd /usr/src wget http://humdi.net/vnstat/vnstat-2.10.tar.gz tar zxvf vnstat-2.10.tar.gz
Compile and install the binaries
cd vnstat-2.10 ./configure --prefix=/usr --sysconfdir=/etc && make all && make install
Install the service files and start the daemon
cp -v examples/init.d/centos/vnstat /etc/init.d/ chkconfig vnstat on service vnstat start
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.