pkgsrc-Changes archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
CVS commit: pkgsrc/net/vnstat
Module Name: pkgsrc
Committed By: sborrill
Date: Wed Apr 8 13:35:58 UTC 2026
Modified Files:
pkgsrc/net/vnstat: Makefile PLIST distinfo
pkgsrc/net/vnstat/files: vnstatd.sh
Added Files:
pkgsrc/net/vnstat: Makefile.common
Removed Files:
pkgsrc/net/vnstat: options.mk
Log Message:
vnstat: update to 2.13 and split into two packages
vnstati, the tool to output images, was previously an option enabled by
default. It requires gd which is rather large (from a dependency point
of view) for a CLI-only system. Therefore, split vnstati into a separate
package allowing the main vnstat package to have no dependencies.
Thanks to kim@ for the idea.
Changes since 1.14:
2.13 / 8-Feb-2025
- Fixed
- Opening of body html tag was missing on some pages in image output
example cgi (examples/vnstat.cgi)
- New
- Add database data merge support as --merge
- Add --db for specifying database file for queries (vnstat and vnstati)
- Add exit status 2 options to --alert for making it possible to
differentiate alerts from errors (exit status 1)
- Add --dbiflist also to vnstati command
- Image output example cgi (examples/vnstat.cgi) improvements
- Remove dependency to vnstat command
- Add option for selecting how many images are shown per row on the index
page when the database has more than one interface
- Add option for selecting which image output is used on the index page
when the database has more than one interface
- Add options for selecting which interfaces are shown or hidden from the
index page without disabling access to all interface specific page when
the database has more than one interface
- Harmonize layout style between pages
2.12 / 21-Jan-2024
- Fixed
- QueryMode documentation in configuration file didn't match implementation
or man page description
- Daemon didn't try to import legacy databases when --noadd was used and no
current version database initially existed resulting in the process
exiting even when something could have been done
- Daemon didn't try to import legacy databases when --initdb was used and
no current version database initially existed, this behaviour can still
be enabled by using --noadd in combination with --initdb
- Using --nodaemon and --initdb at the same time didn't result in an error
being shown
- New
- Add 95th percentile output as --95th, also available via --alert, --json,
--xml and image output, requires 5MinuteHours configuration to be set to
at least 744 for storing all the necessary data
- Add --json support for --alert
- Database queries resulting in error exit with status 1
- Show spinning animation at the beginning of -l / --live output line,
visibility configurable using LiveSpinner configuration option
- Add -ic / --invert-colors option to image output for facilitating for
example dark mode switching without needing to have multiple separate
color configurations
- Add dark mode option to image output example cgi (examples/vnstat.cgi)
- Add option 4 to QueryMode for selecting summary output of single
interface regardless of the number of interfaces in the database
- Add optional mode parameter to -q / --query for overriding QueryMode
for summary output and for enabling control of summary output style
regardless of the number of interfaces in the database
- Add --startempty option to daemon for starting and keeping the daemon
running even if no interfaces were discovered and the database is empty
- Add --noremove option to daemon for disabling the automatic removal of
interfaces from database that aren't currently visible and haven't seen
any traffic
- Add third mode option to --iflist and --dbiflist for getting only the
interface count as output
2.11 / 19-Aug-2023
- Fixed
- Database queries worked only if SQLite double-quoted string (DQS)
feature (https://www.sqlite.org/quirks.html#dblquote) was enabled
- Disabling data resolutions in data retention configuration didn't result
in possibly existing database entries getting removed from the database
- Disabling data resolutions in data retention configuration didn't result
in the data resolution getting disabled but instead storing data forever
- "expr: syntax error" during configure in BSD (pull request by namtsui)
- Image output summary would show only "no data available" text in case of
zero total traffic even when the historical data of no traffic could have
been shown instead
- Image output "-o -" content could get corrupted due to info, warning and
error messages also using stdout, configuration file warnings being the
most likely source, now uses stderr in image output
- Configuration validation was too heavily limiting and enforcing image
output 5 minute graph related configuration options for combinations that
would have resulted in usable images
- New
- Database cleanup has been changed to interpret data retention
configuration as number of entries to be kept instead of calendar time,
this restores the behaviour to similar as it was up to version 1.18, the
difference is visible only on systems that aren't powered all the time
- Database is vacuumed during daemon startup and reload, behaviour is
configurable using VacuumOnStartup and VacuumOnHUPSignal configuration
options
- Add configuration option InterfaceOrder for controlling the interface
order in outputs with multiple interfaces
- Used data retention configuration is made visible during daemon startup
and after configuration reloads
- Daemon will no longer start if all data resolutions have been disabled
in the configuration file
- SQLite version is visible in --version outputs
- Notes
- "Not enough data available yet." message has been replaced with
"No data. Timestamp of last update is same YYYY-MM-DD HH:MM:SS as of
database creation." to better explain the reason why there's nothing to
show, this message is expected to disappear within configured
SaveInterval if the interface is active
2.10 / 22-Oct-2022
- Fixed
- BandwidthDetection in BSD wasn't correctly converting kernel reported
bits per second values to Mbits per second resulting in a sanity check
being triggered and detected values not being used expect for PPPoE
interfaces which incorrectly were detected as 64000 Mbit
- Image output of 5 minute graph wasn't possible if data retention of the
5 minute time period was configured as unlimited
(pull request by Sebastian Lechte)
- Estimates and average rates weren't calculated correctly for daily,
monthly and yearly time periods when monitoring of the interface had been
started during the ongoing time period
- Estimates weren't being shown in summary output when OutputStyle or
--style was configured with a value less than 2 (vnstat)
- Alignment of column header in short output wasn't correct when
OutputStyle or --style was configured with the value 0 (vnstat)
- New
- Support input of more than 31 characters in interface name when using
interface1+interface2 syntax data merge queries
- Support passing --config option multiple times, later files override
earlier files if settings overlap (vnstat and vnstati)
- Add configuration option EstimateVisible for controlling the visibility
of the estimate line
- Add configuration option EstimateText for modifying the default
"estimated" text string when the estimate line is visible
- Add --style support to -tr / --traffic output
- Add summary option to --json and --xml outputs
- Add timestamps to --json and --xml outputs
- Add Prometheus compatible metrics endpoint cgi to examples
(examples/vnstat-metrics.cgi)
2.9 / 23-Jan-2022
- Fixed
- RescanDatabaseOnSave configuration option wasn't being read from the
configuration file resulting in the feature always being enabled
- Hourly graph image output using large fonts didn't correctly fade out
the x-axis line for hours not having data available
- New
- Add --alert for producing output and/or specific exit status when
configured condition and transfer limit is exceeded, can also be used
for "quota remaining" type of queries depending on used parameters
- Add configuration option InterfaceMatchMethod which allows configuring
the possibility of specifying an interface for database queries by using
its alias instead of system provided interface name, enabled by default
to support case insensitive matching of the beginning of interface
aliases (vnstat and vnstati)
- Image output file extension allows selecting the used image file format
as long as the used LibGD supports it, PNG is no longer the only option
- Add configuration option HourlyGraphMode for changing the output mode
of the graph, 0 = 24 hour sliding window (default, as in previous
releases), 1 = graph begins from midnight
- Add mode parameter for -hg / --hoursgraph options for overriding the
HourlyGraphMode configuration option setting from the command line
- Add vertical line to image output hourly graph to visualize midnight
- Add -t / --timestamp options to daemon for enabling timestamps to prints
when the daemon is running in the foreground attached to a terminal
- Accept ; as comment character in configuration file in addition to #
- Comment out keywords which are using default values with ; character in
provided configuration file and --showconfig output
2.8 / 4-Sep-2021
- Fixed
- Using a combination of --live and --json wasn't flushing stdout after
each line resulting in buffered output if the output was being piped
- Image output would fail to show the last line bar graph in list outputs
if EstimateStyle was 0, BarColumnShowsRate was 1 and the last line had a
higher traffic rate than other lines
- Image output didn't correctly horizontally align the "no data available"
message in 5 minute graph depending on the width of the image
- Image output related configuration warnings could get shown when image
output wasn't being used
- Warnings of mismatches between image output and data retention
configuration didn't provide relevant details for solving the issues
- BandwidthDetection was being used for tun interfaces even when the
Linux kernel had the information hardcoded to 10 Mbit regardless of the
used real interface, interface specific MaxBW will now be used instead
or MaxBandwidth as fallback
- Configured interface specific MaxBW values were getting overridden by
BandwidthDetection when something could be detected
- Image output horizontal rx/tx bars often had one pixel too much width in
the tx section resulting in slightly wrong ratio getting shown
- Top days list wasn't always sorting entries with exactly the same traffic
sum using ascending date
- 64bitInterfaceCounters with value -2 always assumed 32-bit on Linux
systems until a 64-bit value was seen if kernel headers weren't available
when binaries were built
- New
- Add the possibility of specifying an interface without using the
-i / --iface options (vnstat and vnstati)
- The daemon can discover added interfaces from the database without
requiring a restart, configurable with option RescanDatabaseOnSave
- Add configuration option UseUTC for using UTC as timezone for database
entries instead of following the system timezone configuration
- --iflist uses user configured interface specific MaxBW values in the
output when available instead of showing only the kernel provided
information when detected
- Add configuration option AlwaysAddNewInterfaces to expose the daemon
--alwaysadd command line option which gains an optional mode parameter
- Image output uses LibGD filled arc bug workaround only for LibGD
versions that are known to be broken
- Image output example cgi (examples/vnstat.cgi) improvements
- Automatically lists all monitored interfaces instead of requiring the
list to be filled manually, server name in page title comes from
hostname command by default
- Provides links for most available images to more detailed or longer
versions of each image
- Allows direct interface specific page access with /interfacename suffix
for the cgi if the used httpd supports PATH_INFO
- Page auto refresh can be enabled with configurable interval
2.7 / 16-May-2021
- Fixed
- Possibility of segmentation fault with image list output when database
existed but no data was available
- ./configure output could show invalid install paths with some parameter
combinations (pull request by Severin Glöckner)
- Columns in text hours graph output could get misaligned if the selected
system locale used a UTF-8 sequence for the thousands separator instead
of a single character
- New
- Add -5g / --fivegraph options to image output with sizing related
parameters for the output of a 5 minute resolution bar graph
- Add configuration option SummaryGraph and optional parameter for
--hsummary and --vsummary for selecting which graph is shown next to
the summary data in the horizontal and vertical summary image outputs
- Add --large / --small options and configuration option LargeFonts for
controlling the image output font size
- Add --scale and configuration option ImageScale for scaling the image
output to a given percent
- Add configuration option LineSpacingAdjustment for adjusting the line
spacing of list format image outputs
- Add bar visualizations for traffic estimations in image output
- Allow writing image output to a filename starting with -
- Add --initdb to daemon for creating a new empty database without having
the daemon process staying running, doesn't discard data if a database
already exists
- Add configuration option BarColumnShowsRate for having the bar column in
image list outputs be scaled according to the average rate column values
when those values are visible, disabled by default
- Add --dbiflist for getting a list of interfaces in the database, both
--iflist and --dbiflist also get alternative more parseable outputs
- Add configuration option for large font output and make 5 minute
resolution graph visible in vnstat.cgi
2.6 / 20-Jan-2020
- Fixed
- --json and --xml didn't support having both mode and limit parameters
defined at the same time as documented, broken since previous release
- Documentation was using a mix of "count" and "limit" for the option of
limiting the maximum number of shown entries in queries
- Summary image output would segmentation fault when the database existed
but didn't yet contain any daily or monthly data for the selected
interface
- New
- Add --limit as an alternative way for controlling the length of outputs
2.5 / 14-Jan-2020
- Fixed
- Automatic interface selection wasn't done for --traffic and --live when
the Interface configuration setting was left empty
- --setalias didn't do anything when used in combination with --add
- -l / --live and -tr default to first interface instead of producing an
error if a interface merge is requested
2.4 / 18-Aug-2019
- Fixed
- Daemon didn't correctly wait when acquiring database lock for data write
which could result in unnecessary errors and even process exit if an
external database read operation had exactly the same timing as the
daemon write operation
- Daemon didn't fork() even when requested to with --daemon when started
by PID 1 (issue seen at least in Docker containers)
- Move vnstatd man page from section 1 to section 8
- New
- Add --rename for renaming interfaces already existing the database
2.3 / 10-Jul-2019
- Fixed
- Traffic rate wasn't being shown for the last entry of most lists during
the first update of the next period (first SaveInterval minutes of each
new hour, day, month and year)
- Systemd example service file could result in database file write issues
if the used systemd version supported ProtectSystem=strict but didn't
support StateDirectory (issue seen at least with systemd 232 in Debian 9)
- Debian and Red Hat init.d example files had wrong path for the pid file
- Interfaces could end up staying marked as 'disabled' in the database even
after becoming back active and monitored, only the shown status was wrong
without resulting in any data loss
- Some image outputs didn't allocate enough height for the image resulting
in the last row having less space below it than intended
- New
- Automatic interface selection when the Interface configuration setting
is left empty (new default)
- Add configuration option DatabaseWriteAheadLogging to enable SQLite
Write-Ahead Logging mode which may provide some disk i/o benefits,
see https://www.sqlite.org/wal.html for more details and note that
SQLite 3.22.0 or later is required to support read-only operations
- Add configuration option DatabaseSynchronous for changing the SQLite
setting of the "synchronous" flag, see
https://www.sqlite.org/pragma.html#pragma_synchronous for more details
- Show warning in log if writing cached data to database is slow
- Try database query for up to 5 seconds when database is busy or locked
instead of giving up immediately
- Continue daemon process execution with data caching if database writes
fail due to disk being full
2.2 / 28-Apr-2019
- Fixed
- O_CLOEXEC undeclared error when compiling with glibc older than 2.12
- Image output --headertext wasn't being applied to some output types
- DefaultDecimals setting wasn't controlling all outputs
- Traffic rate for the last entry of the 5 minute resolution list wasn't
being correctly calculated
- New
- Detection of 32-bit / 64-bit kernel interface counters for improving
traffic calculations in rollover situations, cfg: 64bitInterfaceCounters
- Possibility in queries to merge data from multiple interfaces to one
output with interface1+interface2 syntax
- Highlight current day in top list when visible
- Changes in interface specific detected bandwidth limits are reported
in the log
- UpdateInterval value is automatically adjusted during daemon startup if
found to be too high compared to the value of MaxBandwidth
- Notes
- Added clarification to the man page that the 'jsonversion' and
'xmlversion' fields in the --json and --xml outputs should be seen as
the API version and compared to the previously used version in 3rd party
implementations for verifying compatibility
- Default value of UpdateInterval is now 20 instead of previous 30 seconds
2.1 / 6-Dec-2018
- Fixed
- --oneline could segmentation fault if database had total traffic values
set but didn't have any daily or monthly traffic (Arch bug #60588)
- No proper error message was produced when querying interface which didn't
exist in the database
- Several typos and spelling mistakes in documentation
- Daemon:waittimesync_does_not_wait_with_new_interfaces test was failing if
the system used a time zone with a negative numeric value
- Traffic estimate and average rate for ongoing month was not being
calculated correctly when MonthRotate had a value greater than 1
- Accuracy of traffic estimate and average rate for the ongoing month could
be slightly skewed depending on the used time zone
- New
- Remove possible PollInterval and UpdateInterval drift over time
- Sync SaveInterval to full minutes
2.0 / 21-Oct-2018
- Fixed
- Data rate calculations when using SI decimal prefixes
- Workaround for filled arcs not drawn correctly with some versions
of libgd (libgd/libgd#351)
- New
- C struct dump database has been replaced with sqlite database,
full data import included from legacy databases of versions 1.3 - 1.18
- User configurable data retention durations for all resolutions with
following changed defaults:
v1.18 v2.0
5 minutes n/a 576 (48 hours)
hours 24 96 (4 days)
days 30 62 (2 full months)
months 12 25 (2 full years)
years n/a all
top days 10 20
- Option to select units to use SI decimal prefixes using calculations
with powers of 1000 (IEC and JEDEC prefixes use powers of 1024)
- Yearly and 5 minute resolution statistics
- Pebibyte and exbibyte support
- Options the configure the length of each list output
- Option to limit the length of --json and --xml outputs
- Hourly list output replaces the hourly graph when the -h parameter is used
- Hourly graph is accessible with -hg / --hoursgraph parameter
- Options -b / --begin and -e / --end for specifying query time range
- Configuration comes with ISO 8601 date formats as new defaults
- Removed
- Weekly output
- Merge of data from multiple interfaces to one output
- --testkernel
- --exportdb, use --oneline, --json or --xml instead
- --importdb, -u / --update and related options using vnstat command
- Old style (default in versions up to 1.7) summary layout in image output
1.18 / 4-Mar-2018
- Fix: Misspellings, compiler warnings and possible error situations
(pull requests by Christian Göttsche)
- Hardening added to examples/systemd/vnstat.service
(pull request by Christian Göttsche)
- Add RTC sanity check and sync wait to daemon startup, the possible wait
duration can be configured using the TimeSyncWait keyword
- Add optional parameter to --oneline output for forcing fields to output
in bytes
- Add --json support for -l / --live and -tr outputs
- Number of decimals used in outputs can be configured using DefaultDecimals
and HourlyDecimals
- Add section separators for improving readability of the vnstat -h output,
configurable using HourlySectionStyle
1.17 / 16-Feb-2017
- Fix: --importdb was creating invalid databases since version 1.15
- Fix: console output was being buffered which resulted in lack of output
in at least systemd log
- Add cross-compilation detection and improve install-data-hook to not
assume that the binaries can be executed in the host system
1.16 / 24-Dec-2016
- Fix: traffic rate calculation, SI decimal prefixes were shown but
calculation was done for IEC binary prefixes
- Add option for configure to disable image output support even if required
library is available, improve library detection
(pull request by Rodrigo Rebello)
- Add selection between SI decimal prefixes (kbit/s...) (default) and
IEC binary prefixes (Kibit/s...) for traffic rate using RateUnitMode
keyword in configuration file
- Improve database handling resilience
- Inherit database file ownership from database directory if UpdateFileOwner
configuration option is enabled (default: enabled) when adding new
interfaces for monitoring as root. This solves database file ownership
mismatches when the daemon is started as a non-root user and an interface
gets added for monitoring with a sudo command as root
- Improve user guidance in error situations related to the configured default
interface
1.15 / 22-Dec-2015
- Fix: XML output had extra commas, broken since previous version
- Fix: unintended shared pointer modification in mosecs() sometimes resulted
in wrong month name to be shown for the current month
- Fix: possible buffer overflow in /proc/net/dev parsing, requires corrupted
content in /proc/net/dev or use of address sanitizer (found by Hanno Böck)
- Use ANSI escape codes in -l and -tr modes for cursor location manipulation
instead of printing backspaces, hide cursor while output is active
- Improve database import robustness
- Improve support for Asian UTF-8 date strings
- Replace hand written Makefiles with Autotools
- Add --alwaysadd parameter to daemon for allowing automatic addition of
interfaces even if the database directory was populated during startup
To generate a diff of this commit:
cvs rdiff -u -r1.30 -r1.31 pkgsrc/net/vnstat/Makefile
cvs rdiff -u -r0 -r1.1 pkgsrc/net/vnstat/Makefile.common
cvs rdiff -u -r1.3 -r1.4 pkgsrc/net/vnstat/PLIST
cvs rdiff -u -r1.7 -r1.8 pkgsrc/net/vnstat/distinfo
cvs rdiff -u -r1.1.1.1 -r0 pkgsrc/net/vnstat/options.mk
cvs rdiff -u -r1.1.1.1 -r1.2 pkgsrc/net/vnstat/files/vnstatd.sh
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: pkgsrc/net/vnstat/Makefile
diff -u pkgsrc/net/vnstat/Makefile:1.30 pkgsrc/net/vnstat/Makefile:1.31
--- pkgsrc/net/vnstat/Makefile:1.30 Thu Oct 23 20:38:56 2025
+++ pkgsrc/net/vnstat/Makefile Wed Apr 8 13:35:58 2026
@@ -1,66 +1,29 @@
-# $NetBSD: Makefile,v 1.30 2025/10/23 20:38:56 wiz Exp $
+# $NetBSD: Makefile,v 1.31 2026/04/08 13:35:58 sborrill Exp $
-DISTNAME= vnstat-1.14
-PKGREVISION= 15
-CATEGORIES= net
-MASTER_SITES= http://humdi.net/vnstat/
-#DISTFILES= ${DISTNAME}.tar.gz
-
-MAINTAINER= sborrill%NetBSD.org@localhost
-HOMEPAGE= https://humdi.net/vnstat/
-COMMENT= Small network traffic monitor
-LICENSE= gnu-gpl-v2
+CONF_FILES= ${VNSTAT_EGDIR}/vnstat.conf ${VNSTAT_CONFIG}
-USE_TOOLS+= gmake
+CONFIGURE_ARGS+= --disable-image-output
+RCD_SCRIPTS= vnstatd
VNSTAT_CONFIG= ${PKG_SYSCONFDIR}/vnstat.conf
VNSTAT_EGDIR= ${PREFIX}/share/examples
-SUBST_CLASSES+= fix-dbpath
-SUBST_STAGE.fix-dbpath= pre-configure
-SUBST_MESSAGE.fix-dbpath= Fixing path to database files
-SUBST_FILES.fix-dbpath= src/common.h cfg/vnstat.conf
-SUBST_FILES.fix-dbpath+= man/vnstat.1 man/vnstatd.1
-SUBST_FILES.fix-dbpath+= man/vnstati.1
-SUBST_SED.fix-dbpath= -e 's,/var/lib/,${VARBASE}/db/,g'
-
-SUBST_CLASSES+= fix-etcpath
-SUBST_STAGE.fix-etcpath= pre-configure
-SUBST_MESSAGE.fix-etcpath= Fixing path to configuration files
-SUBST_FILES.fix-etcpath= src/cfg.c
-SUBST_FILES.fix-etcpath+= man/vnstat.1 man/vnstatd.1
-SUBST_FILES.fix-etcpath+= man/vnstati.1
-SUBST_SED.fix-etcpath= -e 's,/etc/,${PKG_SYSCONFDIR}/,g'
-
-CONF_FILES= ${VNSTAT_EGDIR}/vnstat.conf ${VNSTAT_CONFIG}
-
-RCD_SCRIPTS= vnstatd
-
-BUILD_DEFS+= VARBASE
-
INSTALLATION_DIRS= bin ${VNSTAT_EGDIR} ${PKGMANDIR}/man1 \
- ${PKGMANDIR}/man5
-
-.include "options.mk"
+ ${PKGMANDIR}/man5 ${PKGMANDIR}/man8
do-install:
- ${INSTALL_PROGRAM} ${WRKSRC}/src/vnstat \
+ ${INSTALL_PROGRAM} ${WRKSRC}/vnstat \
${DESTDIR}${PREFIX}/bin/vnstat
- ${INSTALL_PROGRAM} ${WRKSRC}/src/vnstatd \
+ ${INSTALL_PROGRAM} ${WRKSRC}/vnstatd \
${DESTDIR}${PREFIX}/bin/vnstatd
${INSTALL_DATA} ${WRKSRC}/cfg/vnstat.conf \
${DESTDIR}${VNSTAT_EGDIR}/vnstat.conf
${INSTALL_MAN} ${WRKSRC}/man/vnstat.1 \
${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/vnstat.1
- ${INSTALL_MAN} ${WRKSRC}/man/vnstatd.1 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/vnstatd.1
+ ${INSTALL_MAN} ${WRKSRC}/man/vnstatd.8 \
+ ${DESTDIR}${PREFIX}/${PKGMANDIR}/man8/vnstatd.8
${INSTALL_MAN} ${WRKSRC}/man/vnstat.conf.5 \
${DESTDIR}${PREFIX}/${PKGMANDIR}/man5/vnstat.conf.5
- if [ ${PLIST.gd:Q} = "yes" ]; then \
- ${INSTALL_PROGRAM} ${WRKSRC}/src/vnstati \
- ${DESTDIR}${PREFIX}/bin/vnstati; \
- ${INSTALL_MAN} ${WRKSRC}/man/vnstati.1 \
- ${DESTDIR}${PREFIX}/${PKGMANDIR}/man1/vnstati.1; \
- fi
+.include "Makefile.common"
.include "../../mk/bsd.pkg.mk"
Index: pkgsrc/net/vnstat/PLIST
diff -u pkgsrc/net/vnstat/PLIST:1.3 pkgsrc/net/vnstat/PLIST:1.4
--- pkgsrc/net/vnstat/PLIST:1.3 Tue Mar 11 14:05:12 2014
+++ pkgsrc/net/vnstat/PLIST Wed Apr 8 13:35:58 2026
@@ -1,9 +1,7 @@
-@comment $NetBSD: PLIST,v 1.3 2014/03/11 14:05:12 jperkin Exp $
+@comment $NetBSD: PLIST,v 1.4 2026/04/08 13:35:58 sborrill Exp $
bin/vnstat
bin/vnstatd
-${PLIST.gd}bin/vnstati
man/man1/vnstat.1
-man/man1/vnstatd.1
-${PLIST.gd}man/man1/vnstati.1
man/man5/vnstat.conf.5
+man/man8/vnstatd.8
share/examples/vnstat.conf
Index: pkgsrc/net/vnstat/distinfo
diff -u pkgsrc/net/vnstat/distinfo:1.7 pkgsrc/net/vnstat/distinfo:1.8
--- pkgsrc/net/vnstat/distinfo:1.7 Thu Oct 10 19:56:01 2024
+++ pkgsrc/net/vnstat/distinfo Wed Apr 8 13:35:58 2026
@@ -1,6 +1,6 @@
-$NetBSD: distinfo,v 1.7 2024/10/10 19:56:01 nia Exp $
+$NetBSD: distinfo,v 1.8 2026/04/08 13:35:58 sborrill Exp $
-BLAKE2s (vnstat-1.14.tar.gz) = eacaf36bd1c84175e265d5879bc644a51db3c8d5bd643d8f2b013f4c34f989df
-SHA512 (vnstat-1.14.tar.gz) = a2aebcdd0c4aa4a821579b751af587af44a5c3f14864d3022a05f65c4df2b9ddece0ed414097346d95124a3ea5fb89ea26bf44c68d3c7ca7237573dd5f1e8239
-Size (vnstat-1.14.tar.gz) = 103281 bytes
+BLAKE2s (vnstat-2.13.tar.gz) = 5def825fa8dc8ee5b50bce73847691ea6b0028287f9881374c8330c3ccb3038e
+SHA512 (vnstat-2.13.tar.gz) = 9b5d7b5085ab2ae39fd6b0d59afe56eb927b6e4ca1ca30ee7710afe2a412c4a1a8d756e095e9c3c81d182e3d6bb2efcd9a2a266e0048cac249477a09c1368969
+Size (vnstat-2.13.tar.gz) = 336647 bytes
SHA1 (patch-src_common.h) = abd8b9f44cb7b5acc3a0952a7caddaf66a01d4bf
Index: pkgsrc/net/vnstat/files/vnstatd.sh
diff -u pkgsrc/net/vnstat/files/vnstatd.sh:1.1.1.1 pkgsrc/net/vnstat/files/vnstatd.sh:1.2
--- pkgsrc/net/vnstat/files/vnstatd.sh:1.1.1.1 Thu Nov 19 15:48:19 2009
+++ pkgsrc/net/vnstat/files/vnstatd.sh Wed Apr 8 13:35:58 2026
@@ -1,6 +1,6 @@
#!@RCD_SCRIPTS_SHELL@
#
-# $NetBSD: vnstatd.sh,v 1.1.1.1 2009/11/19 15:48:19 sborrill Exp $
+# $NetBSD: vnstatd.sh,v 1.2 2026/04/08 13:35:58 sborrill Exp $
#
# PROVIDE: vnstatd
@@ -13,8 +13,16 @@ rcvar=$name
command="@PREFIX@/bin/${name}"
pidfile="/var/run/${name}.pid"
command_args="-d -p $pidfile"
-required_dirs="@VARBASE@/db/vnstat"
+dbdir="@VARBASE@/db/vnstat"
required_files="@PKG_SYSCONFDIR@/vnstat.conf"
+start_precmd="${name}_precmd"
+
+vnstatd_precmd()
+{
+ if [ ! -d $dbdir ]; then
+ mkdir -p $dbdir
+ fi
+}
load_rc_config $name
run_rc_command "$1"
Added files:
Index: pkgsrc/net/vnstat/Makefile.common
diff -u /dev/null pkgsrc/net/vnstat/Makefile.common:1.1
--- /dev/null Wed Apr 8 13:35:58 2026
+++ pkgsrc/net/vnstat/Makefile.common Wed Apr 8 13:35:58 2026
@@ -0,0 +1,34 @@
+# $NetBSD: Makefile.common,v 1.1 2026/04/08 13:35:58 sborrill Exp $
+#
+# used by net/vnstat/Makefile
+# used by net/vnstati/Makefile
+
+DISTNAME= vnstat-2.13
+CATEGORIES= net
+MASTER_SITES= http://humdi.net/vnstat/
+
+MAINTAINER= sborrill%NetBSD.org@localhost
+HOMEPAGE= https://humdi.net/vnstat/
+COMMENT= Small network traffic monitor
+LICENSE= gnu-gpl-v2
+
+GNU_CONFIGURE= yes
+USE_TOOLS+= gmake
+
+SUBST_CLASSES+= fix-dbpath
+SUBST_STAGE.fix-dbpath= pre-configure
+SUBST_MESSAGE.fix-dbpath= Fixing path to database files
+SUBST_FILES.fix-dbpath= src/common.h cfg/vnstat.conf
+SUBST_FILES.fix-dbpath+= man/vnstat.1 man/vnstatd.8
+SUBST_FILES.fix-dbpath+= man/vnstati.1
+SUBST_SED.fix-dbpath= -e 's,/var/lib/,${VARBASE}/db/,g'
+
+SUBST_CLASSES+= fix-etcpath
+SUBST_STAGE.fix-etcpath= pre-configure
+SUBST_MESSAGE.fix-etcpath= Fixing path to configuration files
+SUBST_FILES.fix-etcpath= src/cfg.c
+SUBST_FILES.fix-etcpath+= man/vnstat.1 man/vnstatd.8
+SUBST_FILES.fix-etcpath+= man/vnstati.1
+SUBST_SED.fix-etcpath= -e 's,/etc/,${PKG_SYSCONFDIR}/,g'
+
+BUILD_DEFS+= PKG_SYSCONFDIR VARBASE
Home |
Main Index |
Thread Index |
Old Index