/etc/vnstat.conf contains the following lines:
# enable / disable logging (0 = disabled, 1 = logfile, 2 = syslog)
;UseLogging 1
# set to 1, was 2 - ### CHANGE ###
# file used for logging if UseLogging is set to 1
;LogFile "/home/me/logs/vnstat/vnstat.log"
Yet when i do:
$ vnstat --showconfig
the output includes these lines:
# enable / disable logging (0 = disabled, 1 = logfile, 2 = syslog)
;UseLogging 2
# create dirs if needed (1 = enabled, 0 = disabled)
;CreateDirs 1
# update ownership of files if needed (1 = enabled, 0 = disabled)
;UpdateFileOwner 1
# file used for logging if UseLogging is set to 1
;LogFile "/var/log/vnstat/vnstat.log"
Question:
The config files was changed after vnstat has been run using the original config file.
Obviously i closed it first with:
$ sudo systemctl stop vnstat
And updated /etc/vnstat.conf using sudo
Does the database file contain a “copy” of the configuration file?
i.e. Does vnstat only read the /etc/conf file the first time it starts and then never read it again?
…it seems to be the case IMO.
Will i need to trash the database file to force a re-read of the /etc/config ?
Or is there another way?