File: README.asciidoc

package info (click to toggle)
wmnut 0.70-2
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 408 kB
  • sloc: ansic: 1,119; makefile: 55; sh: 13
file content (289 lines) | stat: -rw-r--r-- 10,099 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
WMNut
=====

Description
-----------

WMNut is a program to monitor multiple UPS devices' statistics through the NUT
(link:http://www.networkupstools.org[Network UPS Tools]) framework on Linux
and other systems.

It is a dockapp that is supported natively by X window managers such as
Window Maker, AfterStep, BlackBox, FluxBox, and Enlightenment.

WMNut will run as a simple 64*64 pixels window in other Window Managers, or
when using *-w*.

image:images/WMnut_desc.png[]

WMNut provides multiple UPS's monitoring with:

- Status of power supply (battery or AC Power),
- Communication status with UPS (Red/Green "C"),
- Percentage of battery remaining (numeric and meter),
- Load level percentage on output (numeric, if available),
- Runtime to empty, i.e. time left to battery depletion (MM:SS),
- High/Low/Critical battery status (Red/Yellow/Green colored meter and battery).

It is known to run on GNU/Linux, FreeBSD, OpenBSD and OpenIndiana (based on
illumos/Solaris), but should also run on any other system supporting X11.

Like NUT, it may require C99 or newer compiler support.

Download
--------

- link:https://github.com/networkupstools/wmnut/releases[Tagged official releases on GitHub]
- link:https://github.com/networkupstools/wmnut/releases/download/v0.69/wmnut-0.69.tar.gz[wmnut-0.69.tar.gz]
- link:https://github.com/networkupstools/wmnut/raw/master/ChangeLog[ChangeLog]

////////////////////////////////////////////////////////////////////////////////
- link:http://github.com/networkupstools/wmnut/raw/master/HINTS[HINTS]
- link:http://github.com/networkupstools/wmnut/raw/master/TODO[TODO]
////////////////////////////////////////////////////////////////////////////////

- link:http://packages.debian.org/wmnut[Debian packages]
- link:http://www.rpmfind.net/linux/rpm2html/search.php?query=wmnut[RPM packages]

Note that you can also access the
link:http://web.archive.org/web/20110913170506/http://wmnut.mgeops.org/files/arch/[old]
and
link:http://web.archive.org/web/20110913170506/http://wmnut.mgeops.org/files/testing/[testing]
WMNut releases.

Installation instructions
-------------------------

Requirements
~~~~~~~~~~~~

WMNut requires the:

- X Window client and Xpm libraries and development files.
  * For example on a Debian GNU/Linux system, you need to install the packages
    `libxext-dev` and `libxpm-dev`.
- NUT client library, version 2.8.0 or higher.
  * For example on a Debian GNU/Linux system, you need to install the package
    `libupsclient-dev` (note that some stable distributions still ship older
    NUT v2.7.4 based packages!)
  * WMNut may actually still work with 2.4.0 or higher -- but at the expense
    of build warnings with data type mismatches and some needed tweaks of the
    `configure.ac` script and possibly wmnut codebase itself.
    It may be easier to just take wmnut-0.67 or an older release then.

In order to compile WMNut using the `Makefile`, GNU `make` should be used.

NOTE: For FreeBSD, OpenBSD and OpenIndiana users, the default BSD `make` or
Sun `dmake` programs respectively in modern releases (2020's) do also work
for the simple recipes used here; however in case of reported `Makefile`
syntax problems -- remember to try using `gmake` instead!

Installation
~~~~~~~~~~~~

1) Download WMNut source code (from GitHub) or archive (`.tar.gz` or `.tar.bz2`)

Either get an archive file from
link:https://github.com/networkupstools/wmnut/releases[WMNut releases on GitHub]
or clone the git repository using:

	$ git clone https://github.com/networkupstools/wmnut.git

2) Uncompress the archive (not needed for github source code)

	$ tar -zxvf wmnut-X.YZ.tar.gz
	$ tar -jxvf wmnut-X.YZ.tar.bz2

3) Switch to WMNut source code directory

	$ cd wmnut-X.YZ

If you are using the git source code, use:

	$ cd wmnut

4) Prepare the source for building

[NOTE]
================================================================================
when using the git repository, be sure to first call:

	$ autoreconf -i

It is also wrapped into a simple `autogen.sh` script for consistency
with other NUT source code repositories.
================================================================================

Just call the usual:

	$ ./configure

[NOTE]
================================================================================
WMNut now uses `pkg-config` to determine the location of NUT library and
headers by default. Alternatively, you can point to systems-dependent
location of a custom NUT build or installation (`make install DESTDIR=...`)
area, like this:

	NUT_LIBS="-L${HOME}/nut/clients/.libs -lupsclient" \
	NUT_CFLAGS="-I${HOME}/nut/include -I${HOME}/nut/clients" \
	./configure
	
	# You would need to install that libdir or pass it with LD_LIBRARY_PATH
	# to run the built program experimentally, e.g.:
	LD_LIBRARY_PATH=${HOME}/nut/clients/.libs ./src/wmnut -w
================================================================================

5) Now compile WMNut

	$ make

Or (may be needed for *BSD and Solaris/illumos based systems):

	$ gmake

6) And install it on your system

Use the following command, as `root` (or using `sudo`):

	$ make install

Or simply copy the `wmnut` binary (and optionally its manual page) to the
right directories on your system.

7) Optionally, configure WMNut for your own use

WMNut will automatically connect to any local device(s).

So if you have remote system(s) that you want to monitor, edit and adapt your
`wmnutrc` file . Then copy it to your user home directory and/or to your system
`/etc` directory, using commands like:

	$ cp wmnutrc /etc/wmnutrc

and/or:

	$ cp wmnutrc ~/.wmnutrc

[NOTE]
================================================================================
- as of WMNut 0.65, `wmnutrc` is installed now, to `/etc` by default
- if both files exist, `~/.wmnutrc` takes precedence,
- command line options take precedence over configuration files,
- on Debian, a sample `wmnutrc` is located in `/usr/share/doc/wmnut/`.
================================================================================

8) Launch WMNut

	$ wmnut &

You can also use `wmnut -h` for help, or `man wmnut` to access the manual page.

If no parameter is given, wmnut will try to access the UPS at "localhost"
address. Otherwise try `wmnut -U upsname@hostname` or edit your `wmnutrc` files.

Be sure to read the `HINTS` and `TODO` files too!


Copyright and license
---------------------

WMNut is Copyright (C) 2002 - 2020 by
link:http://arnaud.quette.free.fr/contact.html[Arnaud Quette]

WMNut is Copyright (C) 2021 - 2024 by the
link:https://networkupstools.org[Network UPS Tools project]
and hosted at https://github.com/networkupstools/wmnut repository

wmnut is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA


Credits
-------

WMNut is based on `wmapm` originally written by Chris D. Faulhaber and
M.G. Henderson.

Huge thanks to:

- link:mailto:aquette.dev@gmail.com[Arnaud Quette] for the majority of
  initial development and maintenance of the WMNut project since 2002.
- Russell Kroll for having initiated and driven the NUT project
  (link:http://www.networkupstools.org[Network UPS Tools]), until 2004.
  Note that Arnaud had also taken over NUT leadership since 2005 to 2020.
- Bill Richter, Laszlo Hazy and David Butts for their support in beta test
  and improvement of WMNut,
- Martijm Pieterse and Antoine Nulle for a great (and somewhat standardized)
  interface which Arnaud used as a template (`wmmon.app` and `wmgeneral`),
- Luca Filipozzi for WMNut Debian package creation, later maintained by Arnaud,
  available at link:http://packages.debian.org/wmnut[Debian website].


Help
----
We are interested in having feedback about how WMNut runs on other platforms
(BSD, Solaris, ...) and searching for packagers on those platforms.

If you have nice suggestions, ideas, whatever, that are not
on TODO list, feel free to post issues and pull requests at
https://github.com/networkupstools/wmnut/releases

You can also try the NUT community support channels, as detailed at
https://networkupstools.org/support.html

FAQ
---

(How) Does WMNut support multiple UPS monitoring?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Yes, WMNut can monitor up to 9 UPSs since release 0.1. Take a look at `HINTS`
file and manual page for more details about using this feature.

Can I set the initial size of WMNut?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

No, WMNut is limited to 64*64.

I'm not running WindowMaker nor AfterStep. How can I run WMNut in windowed mode (i.e. not having transparent background !)?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Try running `wmnut -w`. See below for a screenshot.

I can't compile WMNut ("undefined reference to `upslogx'", "upsfetch.h/o not found" or "upsclient.h/o not found") or WMNut doesn't work!
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

There is always lots of improvements in both NUT and WMNut...

To solve your problem, you should upgrade to the most current release of NUT
and WMNut, and the problem should disappear -- it was solved in the past.

Screenshots
-----------

Withdrawn mode
~~~~~~~~~~~~~~

image:images/wmnut-0_09w.jpg[]

Windowed mode (-w)
~~~~~~~~~~~~~~~~~~

image:images/wmnut-0_09win.jpg[]

Windowed mode (-w) under KDE (Plastik)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

image:images/wmnut-0_60kde.jpg[]