If that doesn't work then you can put a script in /etc/NetworkManager/dispatcher.d/
Code:
#!/bin/sh
case "$2" in
up)
/usr/bin/vnstat -u -i eth0
;;
down)
/usr/bin/vnstat -u -i eth0
;;
*)
exit 0
;;
esac
You'll have to install vnstat same warnings it is on OBS so consider disabling the repo after install or removing completely.
On first run after install you have to vnstat-create-db interface my example using eth0 you can also use a nick alias man vnstat. With that in the dispatcher.d folder you have to make sure it is executable, now it'll run on up and down updating the database. If you suspend to disk then I suspect sync maybe better, well either way I also suspect rather than just updating you want enable and disable..
My example is just that an example..
Running vnstat as user will give you the stats as user, so from here you could present it better. Kdialog maybe for example..
http://packages.opensuse-community.o...rchTerm=vnstat
Bookmarks