I don't think it works that way - or at least I can't figure it out. From the vnstat.conf
So I think that only sets a default should nothing else be specified on the command line. It is set to vtnet0 by the install script and adding interfaces seems to change nothing. As I mentioned earlier this leads me to believe all interfaces are being monitored:
So to say this in a different way ala bug report style
Bug description: The VNStat interace drop down does not choose which interfaces to monitor. Instead it chooses interfaces to report on in the subsequent tabs with a seeming limit of 4 interfaces. Additionally, when multiple interfaces are chosen, an aggregate output is created.
Steps to reproduce: use the interface
Expected behavior: When choosing interfaces in the drop down, one would expect that this uses the equivalent of vnstat --enable/--disable in the back ground to either start or stop monitoring an interface and putting the results in the database. Then the hourly, monthly, year tabs would show an output related to the enabled interfaces on the first tab. For an example on the hourly tab, essentially recursing 'vnstat -h -i vtnet0' for each enabled interface.
So one of two things needs to happen in my mind. The plugin needs to be coded to do what I would expect to happen OR the help needs to be updated to say what the drop down actually does as the help is just wrong. I'm happy to make a pull request to clean up the help, but I figured I'd get this in the public eye in case the plugin actually isn't working as expected. My gut is it is a very simple implementation and the help is just very misleading.
QuoteInterface
Default interface used when no other interface is specified on the command line. Leave empty for automatic selection. The automatic selection will prioritize the interface with most traffic for outputs doing database queries. Queries not using the database will first check if the database is available and select the interface with most traffic out those that are currently visible in the system. If no database can be read then the first available interface will be used. (vnstat and vnstati only)
So I think that only sets a default should nothing else be specified on the command line. It is set to vtnet0 by the install script and adding interfaces seems to change nothing. As I mentioned earlier this leads me to believe all interfaces are being monitored:
Code Select
vnstat --dbiflist
Interfaces in database: enc0 ovpns1 pflog0 pfsync0 vtnet0 vtnet1 vtnet2 vtnet3 vtnet4 vtnet5 vtnet6 wg0 wg1 wg2 wg3So to say this in a different way ala bug report style
Bug description: The VNStat interace drop down does not choose which interfaces to monitor. Instead it chooses interfaces to report on in the subsequent tabs with a seeming limit of 4 interfaces. Additionally, when multiple interfaces are chosen, an aggregate output is created.
Steps to reproduce: use the interface
Expected behavior: When choosing interfaces in the drop down, one would expect that this uses the equivalent of vnstat --enable/--disable in the back ground to either start or stop monitoring an interface and putting the results in the database. Then the hourly, monthly, year tabs would show an output related to the enabled interfaces on the first tab. For an example on the hourly tab, essentially recursing 'vnstat -h -i vtnet0' for each enabled interface.
So one of two things needs to happen in my mind. The plugin needs to be coded to do what I would expect to happen OR the help needs to be updated to say what the drop down actually does as the help is just wrong. I'm happy to make a pull request to clean up the help, but I figured I'd get this in the public eye in case the plugin actually isn't working as expected. My gut is it is a very simple implementation and the help is just very misleading.
"