[packages] vnstat: Update to v1.8 (closes #5664)

git-svn-id: svn://svn.openwrt.org/openwrt/packages@17214 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
acinonyx 2009-08-10 23:33:20 +00:00
parent e59080c3ca
commit 4a9fae915e
3 changed files with 28 additions and 107 deletions

View File

@ -8,12 +8,12 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=vnstat
PKG_VERSION:=1.7
PKG_RELEASE:=2
PKG_VERSION:=1.8
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=http://humdi.net/vnstat
PKG_MD5SUM:=e5788e8122e34f2c93561e2a84c19432
PKG_MD5SUM:=99a30716b5013e7e249e500ee6ee2985
include $(INCLUDE_DIR)/package.mk
@ -29,9 +29,9 @@ $(call Package/vnstat/Default)
endef
define Package/vnstat/description
vnStat is a network traffic monitor for Linux that keeps a log of daily
network traffic for the selected interface(s). vnStat isn't a packet
sniffer. The traffic information is analyzed from the /proc -filesystem,
vnStat is a network traffic monitor for Linux that keeps a log of daily
network traffic for the selected interface(s). vnStat isn't a packet
sniffer. The traffic information is analyzed from the /proc -filesystem,
so vnStat can be used without root permissions.
endef
@ -79,14 +79,14 @@ define Package/vnstat/install
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/vnstatd $(1)/usr/sbin/
$(INSTALL_DIR) $(1)/etc
$(INSTALL_DATA) ./files/vnstat.conf $(1)/etc
$(INSTALL_CONF) $(PKG_BUILD_DIR)/cfg/vnstat.conf $(1)/etc/
$(INSTALL_DIR) $(1)/etc/config
$(INSTALL_DATA) ./files/vnstat-uci.conf $(1)/etc/config/vnstat
$(INSTALL_CONF) ./files/vnstat-uci.conf $(1)/etc/config/vnstat
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/vnstat.init $(1)/etc/init.d/vnstat
endef
define Package/vnstati/install
define Package/vnstati/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/vnstati $(1)/usr/bin/
endef

View File

@ -1,98 +0,0 @@
# vnStat 1.7 config file
##
# location of the database directory
DatabaseDir "/var/lib/vnstat"
# locale (LC_ALL)
Locale "en_US"
# on which day should months change
MonthRotate 1
# date output formats for -d, -m, -t and -w
# see 'man date' for control codes
DayFormat "%d.%m."
MonthFormat "%b '%y"
TopFormat "%d.%m.%y"
# characters used for visuals
RXCharacter "%"
TXCharacter ":"
RXHourCharacter "r"
TXHourCharacter "t"
# how units are prefixed when traffic is shown
# 0 = IEC standard prefixes (KiB/MiB/GiB/TiB)
# 1 = old style binary prefixes (KB/MB/GB/TB)
UnitMode 0
# default interface
Interface "eth0"
# maximum bandwidth (Mbit) for all interfaces, 0 = disable feature
# (unless interface specific limit is given)
MaxBandwidth 100
# interface specific limits
# example 8Mbit limit for eth0 (remove # to activate):
#MaxBWeth0 8
# how many seconds should sampling for -tr take by default
Sampletime 5
# default query mode
# 0 = normal, 1 = days, 2 = months, 3 = top10
# 4 = dumpdb, 5 = short, 6 = weeks, 7 = hours
QueryMode 0
# filesystem disk space check (1 = enabled, 0 = disabled)
CheckDiskSpace 1
# database file locking (1 = enabled, 0 = disabled)
UseFileLocking 1
# how much the boot time can variate between updates (seconds)
BootVariation 15
# vnstatd
##
# how often (in seconds) interface data is updated
UpdateInterval 60
# how often (in seconds) interface status changes are checked
PollInterval 30
# how often (in minutes) interface data is saved to file
SaveInterval 30
# enable / disable logging (0 = disabled, 1 = logfile, 2 = syslog)
UseLogging 2
# file used for logging if UseLogging is set to 1
LogFile "/var/log/vnstat.log"
# file used as daemon pid / lock file
PidFile "/var/run/vnstat.pid"
# vnstati
##
HeaderFormat "%d.%m.%Y %H:%M"
# colors
CBackground "FFFFFF"
CEdge "AEAEAE"
CHeader "606060"
CHeaderTitle "FFFFFF"
CHeaderDate "FFFFFF"
CText "000000"
CLine "B0B0B0"
CLineL "-"
CRx "92CF00"
CTx "606060"
CRxD "-"
CTxD "-"

View File

@ -0,0 +1,19 @@
--- a/cfg/vnstat.conf
+++ b/cfg/vnstat.conf
@@ -69,13 +69,13 @@ TrafficlessDays 1
##
# how often (in seconds) interface data is updated
-UpdateInterval 30
+UpdateInterval 60
# how often (in seconds) interface status changes are checked
-PollInterval 5
+PollInterval 30
# how often (in minutes) interface data is saved to file
-SaveInterval 5
+SaveInterval 30
# enable / disable logging (0 = disabled, 1 = logfile, 2 = syslog)
UseLogging 2