1UPSCMD(8) Network UPS Tools (NUT) UPSCMD(8)
2
3
4
6 upscmd - UPS administration program for instant commands
7
9 upscmd -h
10
11 upscmd -l ups
12
13 upscmd [-u username] [-p password] ups command
14
15
17 upscmd allows you to invoke "instant commands" in your UPS hardware.
18 Not all hardware supports this, so check the list with -l to see if
19 anything will work on your equipment.
20
21 On hardware that supports it, you can use this program to start and
22 stop battery tests, invoke a front panel test (beep!), turn the load on
23 or off, and more.
24
25
27 -h Display the help message.
28
29
30 -l ups Show the list of supported instant commands on that UPS. Some
31 hardware may not support any of them.
32
33
34 -u username
35 Set the username for the connection to the server. This is
36 optional, and you will be prompted for this when invoking a com‐
37 mand if -u is not used.
38
39
40 -p password
41 Set the password to authenticate to the server. This is also
42 optional like -u, and you will be prompted for it if necessary.
43
44
45 ups Connect to this UPS. The format is upsname@hostname[:port].
46
47
49 If you run this program inside a shell script or similar to invoke a
50 command, you will need to specify all of the information on the command
51 line. This means using -u and -p. Otherwise it will put up a prompt
52 and your program will hang.
53
54 This is not necessary when displaying the list, as the username and
55 password are not required for read‐only mode.
56
57
59 Some drivers like apcsmart(8) have built‐in paranoia for the dangerous
60 commands like load.off. To make them actually turn off the load, you
61 will have to send the command twice within a short window. That is,
62 you will have to send it once, then send it again after 3 seconds
63 elapse but before 15 seconds pass.
64
65 This paranoia is entirely defined within the driver. upsd and upscmd
66 have no control over the timing.
67
68
70 upscmd won't work unless you provide a valid username and password. If
71 you get "access denied" errors, make sure that your upsd.users(5) has
72 an entry for you, and that the username you are using has permissions
73 to SET variables.
74
75
77 There is currently no way to tell the user when the driver requires
78 confirmation to invoke a command such as load.off. Similarly, there is
79 not yet a way to tell the user if a command succeeds or fails.
80
81 This is on the list of things to fix in the future, so don't despair.
82 It involves magic cookies.
83
84
86 upsd(8), upsrw(8)
87
88
89 Internet resources:
90 The NUT (Network UPS Tools) home page: http://www.networkupstools.org/
91
92
93
94 Sat May 10 2003 UPSCMD(8)