CentOS vnstat error: Unable to create database backup

On CentOS 5.4, the vnstat cron job generates an error:

Error: Unable create database backup "/var/lib/vnstat/.venet0".

By default, vnstat cron job runs as "nobody", yet the database file "/var/lib/vnstat/venet0" was owned by root, changing its ownership to "nobody", fixed the problem:

chown nobody:nobody /var/lib/vnstat/*

Leave a comment

NOTE: Enclose quotes in <blockquote></blockquote>. Enclose code in <pre lang="LANG"></pre> (where LANG is one of these).