1VNSTATI(1) User Manuals VNSTATI(1)
2
3
4
6 vnstati - png image output support for vnStat
7
8
10 vnstati [ -cdhimostv? ] [ --altdate ] [ --cache time ] [ --config file
11 ] [ --days ] [ --dbdir directory ] [ --headertext text ] [ --help ] [
12 --hours ] [ -hs ] [ --hsummary ] [ -i interface ] [ --iface interface ]
13 [ --locale locale ] [ --months ] [ -ne ] [ -nh ] [ -nl ] [ --noedge ] [
14 --noheader ] [ --nolegend ] [ --output file ] [ -ru ] [ --rateunit ] [
15 --style number ] [ --summary ] [ --top10 ] [ --transparent ] [ --ver‐
16 sion ] [ -vs ] [ --vsummary ]
17
18
20 The purpose of vnstati is to provide image output support for statis‐
21 tics collected using vnstat(1). The image file format is limited to
22 png. All basic outputs of vnStat are supported excluding live traffic
23 features. The image can be outputted either to a file or to standard
24 output.
25
26
28 --altdate
29 Use alternative date and time text location. The date and time
30 text will be moved from the upper right header section to the
31 lower left corner. This option will have no effect if -nh,
32 --noheader has been selected.
33
34
35 -c, --cache time
36 Update output file only if at least time minutes have passed
37 since the previous file update. This option is ignored if stdout
38 is used as output.
39
40
41 --config file
42 Use file as configuration file instead of using normal configu‐
43 ration file search functionality.
44
45
46 -d, --days
47 Output traffic statistics on a daily basis for the last 30 days.
48
49
50 --dbdir directory
51 Use directory as database directory instead of using the direc‐
52 tory specified in the configuration file or the hardcoded
53 default if no configuration file is available.
54
55
56 --headertext text
57 Show text in image header section instead of automatically gen‐
58 erated interface identification. text is limited to 64 charac‐
59 ters and may not get completely shown if longer than the width
60 of the image. Use with --altdate if maximal space is needed.
61 This option will have no effect if -nh, --noheader has been
62 selected.
63
64
65 -h, --hours
66 Output traffic statistics on a hourly basis for the last 24
67 hours.
68
69
70 -hs, --hsummary
71 Output traffic summary including hourly data using a horizontal
72 layout.
73
74
75 -i, --iface interface
76 Use interface instead of default or configured interface.
77
78
79 --locale locale
80 Use locale instead of using the locale setting specified in the
81 configuration file or the system default if no configuration
82 file is available.
83
84
85 -m, --months
86 Output traffic statistics on a monthly basis for the last 12
87 months.
88
89
90 -ne, --noedge
91 Remove darker edges from around the image.
92
93
94 -nh, --noheader
95 Remove header containing title and update time. Time of the pre‐
96 vious update will still be visible in the lower right corner
97 using a less visible color.
98
99
100 -nl, --nolegend
101 Remove legend containing rx and tx color mapping information
102 from the image.
103
104
105 -o, --output file
106 Write png image to file and exit. Output can be directed to std‐
107 out by giving "-" as filename.
108
109
110 -ru, --rateunit
111 Change the configured rate unit. If rate has been configured to
112 be shown in bytes then rate will be shown in bits if this option
113 is present. In the same way, if rate has been configured to be
114 shown in bits then rate will be shown in bytes when this option
115 is present. Alternatively 0 or 1 can be given as parameter for
116 this option in order to select between bytes (0) and bits (1)
117 regardless of the configuration file setting.
118
119
120 --style number
121 Modify the content and style of outputs. Setting number to 3
122 will show average traffic rate in all outputs where it is sup‐
123 ported. Other values will show bar graphics instead.
124
125
126 -s, --summary
127 Output traffic statistics summary.
128
129
130 -t, --top10
131 Output all time top 10 traffic days.
132
133
134 --transparent
135 Toggle background color transparency depending of the Transpar‐
136 entBg setting in the configuration file. Alternatively 0 or 1
137 can be given as parameter for this option in order to either
138 disable (0) or enable (1) transparency regardless of the config‐
139 uration file setting.
140
141
142 -v, --version
143 Show current version.
144
145
146 -vs, --vsummary
147 Output traffic summary including hourly data using a vertical
148 layout.
149
150
151 -?, --help
152 Show a command option summary.
153
154
156 /var/lib/vnstat/
157 Default database directory. Files are named according to the
158 monitored interfaces.
159
160 /etc/vnstat.conf
161 Config file that will be used unless $HOME/.vnstatrc exists. See
162 vnstat.conf(5) for more information.
163
165 vnstati -s -i eth0 -o /tmp/vnstat.png
166 Output traffic summary for interface eth0 to file
167 /tmp/vnstat.png.
168
169
170 vnstati -vs -i eth0+eth1+eth2 -o /tmp/vnstat.png
171 Output traffic summary with hourly data under the normal summary
172 for a merge of interfaces eth0, eth1 and eth2 to file
173 /tmp/vnstat.png.
174
175
176 vnstati -h -c 15 -o /tmp/vnstat_h.png
177 Output hourly traffic statistics for default interface to file
178 /tmp/vnstat_h.png if the file has not been updated within the
179 last 15 minutes.
180
181
182 vnstati -d -ne -nh -o -
183 Output daily traffic statistics without displaying the header
184 section and edges for default interface to standard output (std‐
185 out).
186
187
188 vnstati -m --config /home/me/vnstat.cfg -i -o -
189 Output monthly traffic statistics for default interface speci‐
190 fied in configuration file /home/me/vnstat.cfg to standard out‐
191 put (stdout).
192
193
195 Depending on the built-in fonts provided by the GD library, not all
196 characters may end up shown correctly when a UTF-8 locale is used.
197
198 Using long date output formats may cause misalignment in shown columns
199 if the length of the date exceeds the fixed size allocation.
200
201
203 Teemu Toivola <tst at iki dot fi>
204
205
207 vnstat(1), vnstatd(1), vnstat.conf(5), units(7)
208
209
210
211version 1.18 MARCH 2018 VNSTATI(1)