File: install.html

package info (click to toggle)
xymon 4.3.30-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 11,288 kB
  • sloc: ansic: 69,112; sh: 3,595; makefile: 857; javascript: 452; perl: 48
file content (585 lines) | stat: -rw-r--r-- 28,159 bytes parent folder | download | duplicates (6)
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
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
	<title>Installing Xymon</title>
</head>

<body>
<h1>Installing Xymon</h1>

<p>This describes how to setup a Xymon server for monitoring your systems.
It assumes that you are setting up a full Xymon server - i.e. either you
do not have a Big Brother server, or you will replace it completely with
Xymon.</p>

<p>Note to Big Brother users: Although some of the Xymon tools have evolved 
from the bbgen toolkit that was used on top of a Big Brother server installation, 
the Xymon versions of these tools now require that you run Xymon - not 
Big Brother. If you are migrating from Big Brother to Xymon, then you should 
follow the <a href="bb-to-xymon.html">migration guide</a>.</p>

<h2>Prerequisites - before you install Xymon</h2>
<p><b>You may want to check the <a href="#commonsystems">list of common systems</a>
		which has brief instructions for installing Xymon for these types of systems.</b></p>

<p>There are a few things you should check before you begin to install Xymon.
Don't be scared of the number of items here - it is likely that you already have
most or all of it in place.</p>

<h4>A webbrowser capable of handling HTML 4, JavaScript and CSS</h4>
<p>This includes most browsers available today - Internet Explorer 5 or
later, all Mozilla/Firefox versions, Konqueror, Netscape 6 and several others. 
The old Netscape 4.x browsers are known NOT to work.</p>

<h4>A Unix-like operating system</h4>
<p>Xymon is written for Unix-based systems, e.g. Linux, FreeBSD, or Solaris.
It will probably work on any Unix-like system that supports the Unix System V
IPC mechanisms (shared memory, semaphores) - that should be just about anything
Unix-like you are likely to have.</p>

<h4>Sufficient SYSV IPC resources on your system</h4>
<p>Xymon uses 8 shared memory segments, ranging in size from 32 KB to 512 KB (2336 KB
total) in the default configuration; and 8 sets of 3 semaphores. Experience shows that 
some systems need tuning to provide the necessary IPC resources that Xymon uses. 
Specifically, when installing on Solaris you must increase the "shmseg" kernel parameter 
from the default 6 to at least 8. Since other programs on your system may also use shared 
memory, a higher value may be required.  See <a href="http://www.xymon.com/archive/2005/08/msg00183.html">http://www.xymon.com/archive/2005/08/msg00183.html</a> for more information about these issues.</p>

<h4>A webserver</h4>
<p>Xymon is designed with a web-based front-end. So you should have a webserver
such as <a href="http://httpd.apache.org/">Apache</a> running on the server where
you install Xymon.</p>

<h4>A working C compiler, GNU make.</h4>
<p>Xymon is written in C, so you need a working C compiler, e.g. <a href="http://gcc.gnu.org/">gcc</a>. 
You will also need a "make" utility - many systems have one by default, but you need to use the
<a href="http://directory.fsf.org/make.html">GNU make</a> utility. On some systems,
this is pre-installed as "gmake" or "gnumake". The configure-script checks this for you.</p>

<p><b>HP-UX users</b> should note that the HP-supplied C compiler is known to mis-compile the
lib/environ.c file, and produces an output file lib/environ.o of length 0 bytes.
HP-UX users on the Xymon mailing list agree that the default C compiler shipped with
HP-UX should not be used to compile Xymon - it is only for re-building the HP-UX kernel.
The GNU C compiler works fine on HP-UX. More details in 
<a href="http://www.xymon.com/archive/2005/06/msg00079.html">this e-mail</a> from
the Xymon mailing list.</p>

<h4>PCRE, RRDtool, OpenSSL, OpenLDAP libraries.</h4>
<p>Xymon relies on a number of Open-Source libraries - these must be installed
before you start building Xymon. On many systems you already have these 
pre-installed - they are commonly installed by default on Linux systems, and
FreeBSD has all of them in the "ports" collection.</p>

<p>Note: Although many systems have these libraries pre-installed, they often
include only the run-time libraries and not the files that are needed to compile
and build programs such as Xymon. So if you think you have all of these libraries
installed but Xymon will not build, do check that you have the development
files installed as well. Often these are in packages called "something<em>-dev</em>".</p>

<ul>
	<li>PCRE - Perl Compatible Regular Expression library - is a library 
	for matching text-strings. It is available from
	<a href="http://www.pcre.org/">http://www.pcre.org/</a></li>

	<li>RRDtool is a library for handling the Round-Robin Databases used
	to hold the historical data Xymon gathers. It is available from 
	<a href="http://www.mrtg.org/rrdtool/">http://www.mrtg.org/rrdtool/</a>.
	Xymon has been tested with version 1.2, 1.3 and 1.4 of RRDtool, so
	use one of these - many Linux- and *BSD-systems have pre-packaged
	versions of it.<br>
	Note that RRDtool requires various graphics-libraries. RRDtool 1.2.x uses
	libpng, newer versions rely on the Cairo graphics library.</li>

	<li>OpenSSL is a library for communicating with network services, that
	use SSL encryption - e.g. secure websites. Although this library is
	not absolutely required for Xymon, I strongly recommend that you install
	it because sooner or later you will probably need it anyway. It is 
	available from <a href="http://www.openssl.org/">http://www.openssl.org/</a>.
	Note: If you are building on Solaris, you should check that you have a
	random-data generator, either the prngd daemon (available on 
	<a href="http://www.sunfreeware.com/">Sun Freeware</a>) or the Solaris 
	/dev/random driver from Solaris patch 112438.</li>

	<li>OpenLDAP is used to query LDAP directory servers. If you would like
	to test that your directory server is up and running, you will need this
	library. It is available from <a href="http://www.openldap.org/">http://www.openldap.org/</a></li>
</ul>

<p>The configure-script will attempt to locate all of these libraries on 
your system, and complain if the required ones are missing.</p>


<h4>A "xymon" userid on your system</h4>
<p>A core element of Xymon is a network daemon. To keep your system secure and
limit the amount of damage that can be done if someone finds a security problem
in Xymon, I strongly recommend that you create a dedicated userid for the Xymon
programs. This user should <em>not</em> be a member of any other groups on your
system.</p>

<p>Xymon will install the <u>xymonping</u> tool as <b>setuid-root</b>(only on
the Xymon server). This program requires root privileges to be able to perform
network &quot;ping&quot; tests. It will drop root privileges immediately after 
obtaining the network socket needed for this, and will not run with root
privileges at all while handling network traffic or doing file I/O. </p>


<h2>Building Xymon</h2>
<p>After unpacking Xymon from the tar-file, run the <tt>configure</tt> script.
This script asks a series of questions, but all of the questions have a reasonable
default response. So if you are in doubt about what to answer, use the default 
setting. You can <a href="configure.txt">see what it looks like</a>.</p>

<p>When the configure script finishes, it tells you to run <tt>make</tt> to 
build the Xymon programs. If your default "make" tool is not GNU make, you 
should use the command for running GNU make instead, e.g. <tt>gmake</tt>.
You will now see a lot of commands being run to build the programs, it usually
takes a minute or two.</p>
<p>When it is finished, you finish the installation by running <tt>make install</tt>.</p>

<p>The first time you run <tt>make install</tt>, besides installing the Xymon programs 
it also creates the default directory structure used by Xymon, and installs an 
initial set of configuration files that you can use as the basis for setting up 
monitoring of your entire network.</p>

<p>It is safe to run <tt>make install</tt> when upgrading a Xymon server. It installs the 
programs, adds new template-files that were not present in your previous version,
and updates your configuration files with any new sections that have been added.
Any changes you have made yourself are preserved.</p>

<h2>Configuring your webserver</h2>
<p>Xymon uses a web-based front-end. So you need to configure your webserver so
that it knows where the Xymon webpages can be found, and what CGI scripts can
run as part of Xymon. This usually means adding a few lines to your webserver
configuration that sets up a URL which points at the <em>~/server/www/</em> directory,
and which tells your webserver that the <em>~/cgi-bin/</em> directory holds CGI
scripts that the webserver should run when they are requested.</p>

<p>If you are using the Apache webserver, you will find the necessary additions
to the Apache configuration in <em>~/server/etc/xymon-apache.conf</em> - 
it looks like <a href="xymon-apacheconf.txt">this</a>. After changing the webserver 
configuration, you probably need to restart the webserver.</p>

<a name="htpasswd">
<p>If you configured Xymon to put the Administration CGI scripts into a separate
directory (recommended for better security), you will also need to setup the
password-file that controls access to this directory. Use the <tt>htpasswd</tt>
command both to create the password file and to add or delete users:<br>
<pre><tt>
	# /usr/sbin/htpasswd -c /usr/lib/xymon/server/etc/xymonpasswd admin
	New password:
	Re-type new password:
	Adding password for user admin
	#
</tt></pre>
<p>The <b>-c</b> option should only be used the first time, to create the password
file. See the Apache documentation for details about how to use htpasswd.</p>

<h2>Starting Xymon</h2>
<p>You can now login as the "xymon" user, and run the command <tt>./server/xymon.sh start</tt>
to start Xymon. After a few seconds, it should have started and you now have the following
processes running: <br><img src="xymonprocs.png" alt="Xymon processes"></p>
<p>Quite a few, but all of them controlled by the master <tt>xymonlaunch</tt> process.
A quick run-down of what each of them does:</p>
<ul>
	<li><tt>xymond</tt> is the network daemon that receives status updates from
	the clients and the network test tool. It also provides the current status of
	all your systems to the tool that generates the webpages.</li>
	<li><tt>xymond_channel</tt> provides the communication between xymond and 
	all of the helper modules that implement other server-based functions.</li>
	<li><tt>xymond_history</tt> takes care of recording the history of status
	changes for each item you monitor. This is used to track what has happened
	with a single status over time - when it was red, when it was green, what the
	error reported at 2:51 AM last Friday looked like. The history file format is
	compatible with the format used by the Big Brother package.</li>
	<li><tt>xymond_filestore</tt> stores files with information about the current
	status of the systems monitored by Xymon. There may be several of these
	running, but normally you will only need the one that stores information about
	hosts that have been disabled, which is the one you see here.</li>
	<li><tt>xymond_alert</tt> takes care of sending out alerts when your servers
	begin to report a critical status.</li>
	<li><tt>xymond_rrd</tt> updates the RRD database files with the numeric data
	collected from the status reports, to track e.g. how the disk utilization of
	a server changes over time. There are two of these processes, because the
	data can arrive in two different ways.</li>
</ul>
<p>After a couple of minutes, you should have data available for the Xymon server itself.
If you open a webbrowser with the Xymon URL - usually http://your.server/xymon/ - you
should see something like this:<br><img src="xymonmain.png" alt="Xymon main window"></p>
<p>Each of the little faces indicate an item that is being monitored for this host. Here
you see the default set of items that the Xymon installation sets up for a Xymon server:</p>
<ul>
	<li><em>bbd</em> is the availability of the Xymon network daemon.</li>
	<li><em>conn</em> is a simple &quot;ping&quot; test of the host.</li>
	<li><em>http</em> is the status of the HTTP-server running on the Xymon server.</li>
	<li><em>info</em> contains information about how the host is configured in Xymon,
	such as what IP-address it has, what network tests are being run against this
	host etc.</li>
	<li><em>trends</em> is a collection of the various RRD graphs available for this host.</li>
	<li><em>xymond</em> is the status of the Xymon daemon, with statistics about
	how many monitored items are being tracked.</li>
	<li><em>xymongen</em> is the status of the xymongen tool, which updates the webpages.</li>
	<li><em>xymonnet</em> is the status of the xymonnet network tester that performs
	all of the network tests you configure in Xymon.</li>
</ul>
<p>You can click on each of the green icons to see a more detailed status.</p>

<h2>Next steps</h2>
<p>Congratulations, you now have a running Xymon server!</p>
<p>The next step is to configure it to monitor your servers and applications, and to set up
the alerts to send you e-mail, call a pager, or send an SMS in case of trouble. For that, see
the <a href="xymon-config.html">Xymon configuration guide</a>.</p>

<h2><a name="commonsystems">Appendix: Installing on common systems</a></h2>
<p>This appendix details how to install Xymon on some of the more common types of systems.</p>
<ul>
	<li><a href="#commonrhel6">Red Hat Enterprise Linux 6 / CentOS 6</a></li>
	<li><a href="#commonrhel5">Red Hat Enterprise Linux 5 / CentOS 5</a></li>
	<li><a href="#commonrhel4">Red Hat Enterprise Linux 4 / CentOS 4</a></li>
	<li><a href="#commonrhel3">Red Hat Enterprise Linux 3 / CentOS 3</a></li>
	<li><a href="#commonfedora17">Fedora Linux 17</a></li>
	<li><a href="#commondebian6">Debian 6 (Squeeze)</a></li>
	<li><a href="#commonubuntu1204">Ubuntu 12.04 LTS (Precise Pangolin)</a></li>
	<li><a href="#commonfreebsd">FreeBSD 7, 8 and 9</a></li>
	<li><a href="#commonopenbsd">OpenBSD 4, 5</a></li>
	<li><a href="#commonsolaris10x86csw">Solaris 10/x86 (using OpenCSW)</a></li>
	<li><a href="#commonsolaris10x86sfw">Solaris 10/x86 (using Sun Freeware)</a></li>
	<li><a href="#commonmacosx">Mac OSX</a></li>
</ul>

<h4><a name="commonrhel6">Red Hat Enterprise Linux 6 / CentOS 6</a></h4>
<p>RHEL6 has all of the necessary tools except fping included in the core distribution.</p>
<pre><tt>groupadd xymon
useradd -g xymon -m xymon

yum install gcc make

wget http://fping.org/dist/fping-3.2.tar.gz
tar zxf fping-3.2.tar.gz
cd fping-3.2
./configure
make &amp;&amp; make install
cd ..

yum install pcre-devel openssl-devel openldap-devel rrdtool-devel
cd xymon-4.3.10
./configure --server
make &amp;&amp; make install
</tt></pre>

<p>Copy <tt>rpm/xymon-init.d</tt> to <tt>/etc/init.d/xymon</tt> and make sure it is executable. Edit /etc/init.d/xymon 
and change &quot;/usr/lib/xymon&quot; in the DAEMON line to the directory where you installed Xymon - 
e.g. &quot;/home/xymon&quot;.</p>

<p>Configure Apache with the Xymon definitions:<br>
<tt>ln -s /home/xymon/server/etc/xymon-apache.conf /etc/httpd/conf.d/</tt></p>

<p>To enable automatic start of Xymon and apache:<br>
<pre><tt>chkconfig httpd on
chkconfig --add xymon
chkconfig xymon on
</tt></pre></p>

<h4><a name="commonrhel5">Red Hat Enterprise Linux 5 / CentOS 5</a></h4>
<p>RHEL5 does not include RRDtool in the core distribution. So download it and install it in /usr/local/rrdtool. Also, fping is not included.</p>
<pre><tt>groupadd xymon
useradd -g xymon -m xymon

yum install gcc make

wget http://fping.org/dist/fping-3.2.tar.gz
tar zxf fping-3.2.tar.gz
cd fping-3.2
./configure
make &amp;&amp; make install
cd ..

yum install freetype-devel libpng-devel libart_lgpl-devel tcl-devel
wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.2.30.tar.gz
tar zxf rrdtool-1.2.30.tar.gz
cd rrdtool-1.2.30
./configure --prefix=/usr/local/rrdtool
make &amp;&amp; make install
cd ..

yum install pcre-devel openssl-devel openldap-devel
cd xymon-4.3.10
./configure --server
make &amp;&amp; make install
</tt></pre>

<p>Copy <tt>rpm/xymon-init.d</tt> to <tt>/etc/init.d/xymon</tt> and make sure it is executable. Edit /etc/init.d/xymon 
and change &quot;/usr/lib/xymon&quot; in the DAEMON line to the directory where you installed Xymon - 
e.g. &quot;/home/xymon&quot;.</p>

<p>Configure Apache with the Xymon definitions:<br>
<tt>ln -s /home/xymon/server/etc/xymon-apache.conf /etc/httpd/conf.d/</tt></p>

<p>To enable automatic start of Xymon and apache:<br>
<pre><tt>chkconfig httpd on
chkconfig --add xymon
chkconfig xymon on
</tt></pre></p>



<h4><a name="commonrhel4">Red Hat Enterprise Linux 4 / CentOS 4</a></h4>
<p>RHEL4 does not include RRDtool in the core distribution. So download it and install it in /usr/local/rrdtool. Also, fping is not included and some of the development files are in a non-standard location.</p>
<pre><tt>groupadd xymon
useradd -g xymon -m xymon

yum install gcc make

wget http://fping.org/dist/fping-3.2.tar.gz
tar zxf fping-3.2.tar.gz
cd fping-3.2
./configure
make &amp;&amp; make install
cd ..

yum install freetype-devel libpng-devel libart_lgpl-devel tcl-devel
wget http://oss.oetiker.ch/rrdtool/pub/rrdtool-1.2.30.tar.gz
tar zxf rrdtool-1.2.30.tar.gz
cd rrdtool-1.2.30
./configure --prefix=/usr/local/rrdtool
make &amp;&amp; make install
cd ..

yum install pcre-devel openssl-devel openldap-devel
cd xymon-4.3.10
./configure --server --pcreinclude /usr/include/pcre --sslinclude /usr/include/openssl
make &amp;&amp; make install
</tt></pre>

<p>Copy <tt>rpm/xymon-init.d</tt> to <tt>/etc/init.d/xymon</tt> and make sure it is executable. Edit /etc/init.d/xymon 
and change &quot;/usr/lib/xymon&quot; in the DAEMON line to the directory where you installed Xymon - 
e.g. &quot;/home/xymon&quot;.</p>

<p>Configure Apache with the Xymon definitions:<br>
<tt>ln -s /home/xymon/server/etc/xymon-apache.conf /etc/httpd/conf.d/</tt></p>

<p>To enable automatic start of Xymon and apache:<br>
<pre><tt>chkconfig httpd on
chkconfig --add xymon
chkconfig xymon on
</tt></pre></p>


<h4><a name="commonrhel3">Red Hat Enterprise Linux 3 / CentOS 3</a></h4>
<p>Follow instructions for <a href="#commonrhel4">RHEL4</a>.</p>

<h4><a name="commonfedora17">Fedora 17</a></h4>
<p>Follow instructions for <a href="#commonrhel6">RHEL6</a>.</p>

<h4><a name="commondebian6">Debian 6 (Squeeze)</a></h4>
<p>NOTE: Pre-compiled Debian packages are provided on Sourceforge, along with the source distribution file.</p>
<p>Debian 6 has all of the necessary tools included in the core distribution.</p>
<pre><tt>apt-get install apache2 rrdtool librrd-dev libpcre3-dev libssl-dev ldap-utils libldap2-dev fping

# Enable mod_rewrite in Apache
cd /etc/apache2/mods-enabled/
ln -s ../mods-available/rewrite.load .
/etc/init.d/apache2 reload
cd

tar zxf xymon-4.3.10.tar.gz
cd xymon-4.3.10
./build/makedeb.sh 4.3.10
mv debbuild/*.deb ../
cd ..
dpkg -i xymon*deb
</tt></pre></p>


<h4><a name="commonubuntu1204">Ubuntu 12.04 LTS (Precise Pangolin)</a></h4>
<p>Follow instructions for <a href="#commondebian6">Debian 6</a>.</p>

<h4><a name="commonfreebsd">FreeBSD 7,8 and 9</a></h4>
<p>Perform a standard install, make sure to install the "ports" collection. FreeBSD - in a minimal configuration - does not install any of the Xymon prerequisites, so starting from a minimal configuration you must run these commands to install the various tools and libraries needed. For those packages that have some configuration items, the defaults work fine:</p>
<pre><tt>cd /usr/ports/devel/gmake; make; make install
cd /usr/ports/devel/pcre; make; make install
cd /usr/ports/databases/rrdtool12; make; make install
cd /usr/ports/security/openssl; make; make install
cd /usr/ports/net/openldap23-client; make; make install
cd /usr/ports/net/fping; make; make  install
cd /usr/ports/www/apache22; make; make install
</tt></pre>
<p>Next, run the &quot;adduser&quot; utility and setup the &quot;xymon&quot; user.</p>
<p>After this you are ready to build and install Xymon:</p>
<pre><tt>setenv PATH ${PATH}:/usr/local/bin
setenv MAKE gmake
cd ~
gzip -dc xymon-4.3.10.tar.gz | tar xf -
cd xymon-4.3.10
./configure	# All defaults, except group-ID for webserver is "www"
gmake &amp;&amp; gmake install
chown 0:0 /home/xymon/server/bin/xymonping
chmod u+s /home/xymon/server/bin/xymonping

ln -s /home/xymon/server/etc/xymon-apache.cnf /usr/local/etc/apache22/Includes
</tt></pre>

<p>To enable automatic start of Xymon when the server is booted, you must create the <tt>/etc/rc.d/xymon</tt> script:</p>
<pre><tt>
#!/bin/sh

. /etc/rc.subr

name="xymon"
start_cmd="${name}_start"
stop_cmd="${name}_stop"

xymon_start()
{
	su xymon /home/xymon/server/xymon.sh start
}

xymon_stop()
{
	su xymon /home/xymon/server/xymon.sh stop
}

load_rc_config $name
run_rc_command "$1"
</tt></pre>

<p>Make sure the script is executable with<br>
<tt>chmod 755 /etc/rc.d/xymon</tt><br>
and add the line<br>
<tt>xymon_enable=&quot;YES&quot;</tt><br>
to the file /etc/rc.conf</p>

<p>A similar script can be used to start/stop Apache automatically. Use the commands<br>
<tt>/usr/local/sbin/apachectl start</tt><br>
and<br>
<tt>/usr/local/sbin/apachectl stop</tt><br>
in the apache_start() and apache_stop() functions, respectively.</p>


<h4><a name="commonopenbsd">OpenBSD 4 and 5</a></h4>
<p>All of the necessary packages are available from the OpenBSD &quot;ports&quot; collection. Note that when installing OpenBSD, you must install the &quot;xbase&quot; package, since this contains a library that is needed by RRDtool.</p>
<p>After installing the core OpenBSD system, use the ports-collection to install the necessary packages. See <a href="http://www.openbsd.org/faq/faq15.html#Intro">OpenBSD FAQ</a> for details about using this.</p>
<pre><tt>export PKG_PATH=ftp://ftp.openbsd.org/pub/OpenBSD/`uname -r`/packages/`uname -m`/
pkg_add -v gmake pcre rrdtool openldap-client fping apache-httpd
</tt></pre>
<p>Note: Check permissions on /usr/local/sbin/fping* - they must be suid root. On OpenBSD 4.6 it has been observed that this is not the case by default, so you must run<br><tt>chmod u+s /usr/local/sbin/fping*</tt><br>for them to be usable by the xymon user.</p>

<p>Run the <tt>adduser</tt> utility to setup the &quot;xymon&quot; user.</p>

<p>Configure, build and install Xymon with these commands. Configuration can use all defaults, except that the webserver group-ID is &quot;_apache2&quot;.</p>
<pre><tt>gzip -dc xymon-4.3.10.tar.gz | tar xf -
cd xymon-4.3.10
MAKE=gmake ./configure # All defaults except webserver group is "_apache2"
gmake &amp;&amp; gmake install
</tt></pre>
<p>In /etc/apache2/httpd2.conf, add this line at the bottom:<br>
<tt>Include /home/xymon/server/etc/xymon-apache.conf</tt></p>

<p>To enable automatic startup, add these commands to /etc/rc.local:<br>
<tt>/usr/local/sbin/apachectl2 start<br>su xymon /home/xymon/server/xymon.sh start<br></tt></p>

<h4><a name="commonsolaris10x86csw">Solaris 10/x86 (using OpenCSW)</a></h4>
<p>All of the necessary libraries and tools for building Xymon are available in the
<a href="http://www.opencsw.org/">OpenCSW archive</a>. This appears to be a newer
collection of Open Source tools, replacing the Sun Freeware archive which is now
a commercial project. See <a href="#commonsolaris10x86sfw">below</a> for instructions
on installing Xymon using the SFW packages.</p>

<p>Follow the <a href="http://www.opencsw.org/manual/for-administrators/getting-started.html">
&quot;Getting Started&quot;</a> instuctions on setting up your system to use the CSW archive.
Briefly, this means running these commands (as root):<br>
<pre><tt>pkgadd -d http://get.opencsw.org/now
PATH=$PATH:/opt/csw/bin
export PATH
pkgutil -i -y cswpki
cswpki --import
vi /etc/opt/csw/pkgutil.conf	# Define mirror, enable use_gpg and use_md5
pkgutil -U
</tt></pre></p>

<p>After setting up the CSW archive tool, you can install the necessary tools
and libraries that Xymon will use:<br>
<pre><tt>pkgutil -i -y gcc4core gcc4g++ gmake
pkgutil -i -y pcre libpcre_dev
pkgutil -i -y rrdtool rrdtool_dev
pkgutil -i -y openssl libssl_dev
pkgutil -i -y openldap_client openldap_dev
pkgutil -i -y fping</tt></pre></p>

<p>The &quot;fping&quot; tools must be installed suid-root so that the xymon
user can run them:<pre><tt>chmod u+s /opt/csw/sbin/fping*</tt></pre></p>

<p>Now, create the xymon user:<pre><tt>groupadd xymon; useradd -g xymon -d /export/home/xymon -m xymon</tt></pre></p>

<p>Configure and build Xymon. All tools and libraries should be automatically detected, but it is necessary to explicitly point at the CSW OpenSSL libraries, overriding the default Solaris version of OpenSSL:<br>
<pre><tt>PATH=$PATH:/usr/ccs/bin
export PATH
cd xymon-4.3.10
MAKE=gmake ./configure --server --sslinclude /opt/csw/include --ssllib /opt/csw/lib
gmake &amp;&amp; gmake install
</tt></pre></p>

<p>Install Apache and add the Xymon webserver configuration:<br>
<pre><tt>pkgutil -i -y apache2
ln -s /export/home/xymon/server/etc/xymon-apache.conf /opt/csw/apache2/etc/extra/
</tt></pre>
Add<br>
<tt><pre>  Include etc/extra/xymon-apache.conf</pre></tt>
to /opt/csw/apache2/etc/httpd.conf.
</p>

<p>The CSW Apache implementation supports the Solaris SMF (svcadm) setup, but conflicts with the default Apache version that is installed with Solaris. So disable the default version, and enable the CSW version:<pre><tt>/etc/init.d/apache stop
rm /etc/rc?.d/*apache
svcadm clear cswapache2</tt></pre></p>

<p>To enable automatic startup of Xymon when the server boots, put this into /etc/init.d/xymon:<pre><tt>#!/bin/sh
su xymon /export/home/xymon/server/xymon.sh $*
exit $?
</tt></pre> and then enable this via the &quot;legacy&quot; startup scripts by running these commands:<pre><tt>ln -s /etc/init.d/xymon /etc/rc3.d/S80xymon
ln -s /etc/init.d/xymon /etc/rc0.d/K20xymon
ln -s /etc/init.d/xymon /etc/rc1.d/K20xymon
ln -s /etc/init.d/xymon /etc/rcS.d/K20xymon
</tt></pre></p>

<h4><a name="commonsolaris10x86sfw">Solaris 10/x86 (using Sun Freeware)</a></h4>
<p>All of the necessary libraries and tools for building Xymon are available in the
<a href="http://www.sunfreeware.com/">Sun Freeware archive</a>. You must install these
packages to build Xymon:</p>
<ul>
	<li>db (SMCdb47)</li>
	<li>freetype (SMCftype)</li>
	<li>gcc (SMCgcc)</li>
	<li>libart_lgpl (SMClibart)</li>
	<li>libpng (SMClibpng)</li>
	<li>libtool (SMClibt)</li>
	<li>libiconv (SMCliconv)</li>
	<li>libintl (SMClintl)</li>
	<li>make (SMCmake)</li>
	<li>openldap (SMColdap)</li>
	<li>openssl (SMCossl)</li>
	<li>pcre (SMCpcre)</li>
	<li>rrdtool (SMCrrdt)</li>
	<li>sasl (SMCsasl)</li>
	<li>zlib (SMCzlib)</li>
</ul>

<p>After installing these, you must set PATH and LD_LIBRARY_PATH to pick up the new tools, then you can compile Xymon the usual way:</p>
<pre><tt>groupadd xymon
useradd -d /usr/local/xymon xymon
PATH=$PATH:/usr/local/bin:/usr/ccs/bin; export PATH
LD_LIBRARY_PATH=/usr/local/lib; export LD_LIBRARY_PATH
./configure
make
make install
</tt></pre>
<p>The SunFreeware libraries are installed in /usr/local/lib, which is <em>NOT</em> searched by default by the Solaris runtime linker. You must either set LD_LIBRARY_PATH globally to include /usr/local/lib, or you can use the &quot;crle&quot; utility to add /usr/local/lib to the set of directories searched by default. Typically this means running this command:</p>
<pre><tt>	crle -c /var/ld/ld.config -l /usr/lib:/usr/lib/secure:/usr/local/lib </tt></pre></p>
<p>The latter method using &quot;crle&quot; is the recommended method, since LD_LIBRARY_PATH settings can be difficult to setup so they work for all invocations of the Xymon binaries.</p>

<h4><a name="commonmacosx">Mac OSX 10.6, 10.7 and 10.8</a></h4>
<p>Xymon is available for OSX 10.6, 10.7 and 10.8 through the <a href="http://www.macports.org/">macports project</a>.</p>

<p>The ports can be found here:<a href="http://www.macports.org/ports.php?by=name&substr=xymon">http://www.macports.org/ports.php?by=name&amp;substr=xymon</a>, and there's a page on <a href="https://trac.macports.org/wiki/howto/SetupXymonServer">how to make xymon server on a Mac</a>.</p>

</body>
</html>