1NUTUPSDRV(8)                      NUT Manual                      NUTUPSDRV(8)
2
3
4

NAME

6       nutupsdrv - generic manual for unified NUT drivers
7

SYNOPSIS

9       nutupsdrv -h
10
11       nutupsdrv [OPTIONS]
12

DESCRIPTION

14       nutupsdrv is not actually a driver. This is a combined man page for the
15       shared code that is the core of many drivers within the Network UPS
16       Tools package.
17
18       For information on the specific drivers, see their individual man
19       pages.
20
21       UPS drivers provide a communication channel between the physical UPS
22       hardware and the upsd(8) server. The driver is responsible for
23       translating the native protocol of the UPS to the common format used by
24       the rest of this package.
25
26       The core has three modes of operation which are determined by the
27       command line switches. In the normal mode, the driver will periodically
28       poll the UPS for its state and parameters, as per the pollinterval
29       parameter in ups.conf(5). The results of this command are presented to
30       upsd. The driver will also handle setting variables and instant
31       commands if available.
32
33       In the second mode, using -k, the driver can instruct the UPS to shut
34       down the load, possibly after some delay. This mode of operation is
35       intended for cases when it is known that the UPS is running out of
36       battery power and the systems attached must be turned off to ensure a
37       proper reboot when power returns.
38
39       In the third mode, using -d, the driver will exit after some update
40       loops, dumping the data tree (in upsc-like format) to stdout. This can
41       be useful to complement the nut-scanner to discover devices, along with
42       in-depth data.
43
44           Note
45           You probably don’t want to use any of these options directly. You
46           should use upsdrvctl(8) to control your drivers, and ups.conf(5) to
47           configure them. The rest of this manual describes options and
48           parameters that generally are not needed by normal users.
49

OPTIONS

51       -h
52           Display a help message without doing anything else. This will also
53           list possible values for -x in that driver, and other help text
54           that the driver’s author may have provided.
55
56       -a id
57           Autoconfigure this driver using the id section of ups.conf(5).
58           This argument is mandatory when calling the driver directly.
59
60       -s id
61           Configure this driver only with command line arguments instead of
62           reading ups.conf(5). To be used instead of -a option when need to
63           run a driver not present in driver configuration file. Instead,
64           driver configuration have to be set with -x options directly in the
65           command line. As the driver instance cannot be controlled by
66           upsdrvctl(8), this option should be used for specific needs only.
67
68       -D
69           Raise the debugging level. Use this multiple times to see more
70           details. Running a driver in debug mode will (by default) prevent
71           it from backgrounding after startup. It will keep on logging
72           information to the console until it receives a SIGINT (usually
73           Ctrl-C) or SIGTERM signal.
74
75           The level of debugging needed depends both on the driver and the
76           problem you’re trying to diagnose. Therefore, first explain the
77           problem you have with a driver to a developer/maintainer, before
78           sending them debugging output. More often than not, if you just
79           pick a level, the output may be either too limited or too verbose
80           to be of any use.
81
82       -d update_count
83           Dump the data tree (in upsc-like format) to stdout after running
84           the driver update loop for update_count times and exit. By default
85           this prevents the driver process from backgrounding after startup.
86           Note that the driver banner will be printed too, so when using this
87           option in scripts, don’t forget to trim the first line.
88
89       -q
90           Raise log level threshold. Use this multiple times to log more
91           details.
92
93           The debugging comment above also applies here.
94
95       -F
96           Enforce running the driver as a foreground process, regardless of
97           debugging or data-dumping settings.
98
99       -B
100           Enforce running the driver as a background process, regardless of
101           debugging or data-dumping settings.
102
103       -i interval
104           Set the poll interval for the device. The default value is 2 (in
105           seconds).
106
107       -V
108           Print only version information, then exit.
109
110       -L
111           Print a parsable list of driver variables. Mostly useful for
112           configuration wizard programs.
113
114       -k
115           ("Kill" power) Forced shutdown mode. The UPS will power off the
116           attached load, if possible.
117
118           You should use upsdrvctl shutdown whenever possible instead of
119           calling this directly.
120
121       -r directory
122           The driver will chroot(2) to directory during initialization. This
123           can be useful when securing systems.
124
125           In addition to the state path, many systems will require /dev/null
126           to exist within directory for this to work. The serial ports are
127           opened before the chroot call, so you do not need to create them
128           inside the jail. In fact, it is somewhat safer if you do not.
129
130       -u username
131           Override the unprivileged username that the driver may use after
132           startup. If started as root, after opening configuration files (and
133           optionally calling chroot(2), as described in the previous option),
134           the driver will look up username in the passwd database, then
135           change to the user and group identities associated with username.
136           (If started with a nonzero UID or effective UID, the driver will
137           silently ignore this option.)
138
139           When compiling NUT from source, the default username is typically
140           nobody, and this may cause permission errors when the driver opens
141           the UPS device node. You can use this option to temporarily
142           override the defaults. For testing purposes, you can set this
143           option to root to bypass permission errors, especially with
144           USB-based drivers. However, you will want to remove this option
145           later in order to avoid permission conflicts between the driver and
146           the unprivileged copy of upsd(8).
147
148       -g groupname
149           Override the unprivileged group name that the driver may use after
150           startup to set permissions for the filesystem socket so upsd may
151           still access it if the run-time user of the driver normally would
152           deny that access.
153
154       -x var=val
155           Define a variable called var with the value of var in the driver.
156           This varies from driver to driver - see the specific man pages for
157           more information.
158
159           This is like setting var=val in ups.conf(5), but -x overrides any
160           settings from that file.
161

DIAGNOSTICS

163       Information about the startup process is printed to stdout. Additional
164       messages after that point are available in the syslog. After upsd(8)
165       starts, the UPS clients such as upsc(8) can be used to query the status
166       of an UPS.
167

PROGRAM CONTROL

169       You should always use upsdrvctl(8) to control the drivers. While
170       drivers can be started by hand for testing purposes, it is not
171       recommended for production use.
172

FILES

174       ups.conf
175           Required configuration file. This contains all details on which
176           drivers to start and where the hardware is attached.
177

ENVIRONMENT VARIABLES

179       NUT_CONFPATH is the path name of the directory that contains upsd.conf
180       and other configuration files. If this variable is not set, upsd uses a
181       built-in default, which is often /usr/local/ups/etc.
182
183       NUT_STATEPATH is the path name of the directory in which upsd keeps
184       state information. If this variable is not set, upsd uses a built-in
185       default, which is often /var/state/ups. The STATEPATH directive in
186       upsd.conf(5) overrides this variable.
187
188       NUT_ALTPIDPATH is the path name of the directory in which upsd and
189       drivers store .pid files. If this variable is not set, upsd and drivers
190       use either NUT_STATEPATH if set, or ALTPIDPATH if set, or otherwise the
191       built-in default STATEPATH.
192

BUGS

194       Some of the drivers may have bugs. See their manuals for more
195       information.
196

SEE ALSO

198   Server:
199upsd(8)
200
201   Clients:
202upsc(8)
203
204upscmd(8)
205
206upsrw(8)
207
208upslog(8)
209
210upsmon(8)
211
212   CGI programs:
213upsset.cgi(8)
214
215upsstats.cgi(8)
216
217upsimage.cgi(8)
218
219   Driver control:
220nut-driver-enumerator(8)
221
222upsdrvctl(8)
223
224upsdrvsvcctl(8)
225
226   Drivers:
227adelsystem_cbi(8)
228
229al175(8)
230
231apcsmart-old(8)
232
233apcsmart(8)
234
235apcupsd-ups(8)
236
237asem(8)
238
239bcmxcp(8)
240
241bcmxcp_usb(8)
242
243belkin(8)
244
245belkinunv(8)
246
247bestfcom(8)
248
249bestfortress(8)
250
251bestuferrups(8)
252
253bestups(8)
254
255       •   blazer-common(8)
256
257blazer_ser(8)
258
259blazer_usb(8)
260
261clone(8)
262
263dummy-ups(8)
264
265etapro(8)
266
267everups(8)
268
269gamatronic(8)
270
271generic_modbus(8)
272
273genericups(8)
274
275huawei-ups2000(8)
276
277isbmex(8)
278
279ivtscd(8)
280
281liebert-esp2(8)
282
283liebert(8)
284
285       •   macosx-ups(8)
286
287masterguard(8)
288
289metasys(8)
290
291mge-shut(8)
292
293mge-utalk(8)
294
295microdowell(8)
296
297microsol-apc(8)
298
299netxml-ups(8)
300
301nut-ipmipsu(8)
302
303nutdrv_atcl_usb(8)
304
305nutdrv_qx(8)
306
307nutdrv_siemens_sitop(8)
308
309oneac(8)
310
311optiups(8)
312
313phoenixcontact_modbus(8)
314
315pijuice(8)
316
317powercom(8)
318
319       •   powerman-pdu(8)
320
321powerpanel(8)
322
323rhino(8)
324
325richcomm_usb(8)
326
327riello_ser(8)
328
329riello_usb(8)
330
331safenet(8)
332
333snmp-ups(8)
334
335socomec_jbus(8)
336
337solis(8)
338
339tripplite(8)
340
341tripplite_usb(8)
342
343tripplitesu(8)
344
345upscode2(8)
346
347usbhid-ups(8)
348
349victronups(8)
350
351   Internet resources:
352       The NUT (Network UPS Tools) home page: http://www.networkupstools.org/
353
354
355
356Network UPS Tools 2.8.0           04/26/2022                      NUTUPSDRV(8)
Impressum