mrtg-nw-guide(1)

NAME

mrtg-nw-guide - MRTG for NetWare

SYNOPSIS

This guide is intended to aid in the installation and configuration of MRTG on a NetWare server.

OVERVIEW

MRTG is a relative newcomer to the NetWare platform. Ear
lier versions of NetWare could not run MRTG natively for several
reasons:
· Absence of NetWare OS support in the MRTG package.
· A NetWare server commandline length limitation.
· Absence of the Rateup executable (Rateup.nlm).
· A standard installation method.
· Problems with NetWare's implementation of Perl.
Support for the NetWare OS has now been fully added into
MRTG, beginning with MRTG release 2.12.2.
Liberallly minded operating systems support a commandline
length approaching 1000 characters. In such environments it was
an easy matter to pass the sometimes high number of parameters
used by MRTG's Rateup executable directly on the commandline. Un
til NetWare 6.5, NetWare had a commandline limit of 512 charac
ters. This limitation was also removed for NetWare 6.0 by Service
Pack 5. For other NetWare versions and earlier Service Packs,
this limitation remains. To permit a 'standard' interface for
NetWare, the Rateup executable has been modified to also read its
parameters from a file, and the MRTG script has been modified to
support this method on a NetWare platform. (See New Rateup
Switch)
A Rateup NLM is now available, along with the necessary
scripts to build it if required. See the NetWare Support section
of this document for further details. Additionally, mrtg.pl has
been revised because of the unique (to NetWare) name of executa
bles (NLM).
The absence of a specific installation procedure has
caused MRTG to fail in the past because the Perl script could not
find or load the Rateup executable. The installation method sup
plied here will solve this problem for now.
The MRTG.pl script in the 2.12.2 (or later) version of
MRTG has been configured to suit all likely versions of NetWare
able to use Perl5, and bypasses all of the known problems with
NetWare Perl running MRTG.

PREREQUISITES

You will need the following:

· Perl 5.8.0 for NetWare with latest Perl Updates
(February, 2005 or later; previous versions MAY work)
· NetWare 5.1 w/ SP8, NetWare 6.0 w/ SP5 or NetWare 6.5
w/ SP2.
· A copy of the MRTG Package (v2.12.2 at time of writ
ting)
· Three .ncf files to execute the Perl scripts at the
NetWare server console.
· A copy of the Rateup NLM (Pre-built or compiled)
· Optionally, any NetWare supported Web Server
(Netscape, Apache 1.3 or 2.0)
For copies of the .ncf files and Rateup NLM, see NetWare
Support in this document.

INSTALLING MRTG

1. Install the latest Perl 5.8.x release on your server.
See the Perl documentation for details.
2. Create the following directories:

SYS:/Mrtg
SYS:/Mrtg/bin
SYS:/Mrtg/contrib (Optional for this docu
ment)
SYS:/Mrtg/doc (Optional for this docu
ment)
SYS:/Mrtg/html
SYS:/Mrtg/html/images
SYS:/Mrtg/html/work
SYS:/Mrtg/lib
SYS:/Mrtg/logs
SYS:/Mrtg/translate
3. Copy fromSthe MRTG package the following files:
:
/n All files. See Note 1.
M
Note 1: Add a .pl extension to the mrtg, cfgmaker
and indexmaker files.
t The rateup.exe will NOT be needed on the
NetWare server.
g
/ oc to
SYS:/Mrtg/doc/ All files
images to SYS:/Mrtg/html/images/ All
files
ranslate to SYS:/Mrtg/translate/ All
files. See Note 2.
Note 2: For English-only language support, all
ranslate files EXCEPT Locales_mrtg may be deleted.

to SYS:/Mrtg/lib Include
sub-directories. See Note 3.
Note 3: This will create the SYS:/Mrtg/lib/mrtg2
and ./pod directories.
4. Create copies of the three .ncf files and install
them:

*.ncf to SYS:/Mrtg/bin
See NetWare Support in this document for details on
how to create copies of these files.
n
5. See Compiling Rateup.nlm"> in this document for de
tails on compiling the Rateup NLM yourself if desired. A prebuit
verion is available in the .tgdrectory where it must remain.

CONFIGURING MRTG

· Refer to Novell documentation on configuring and load
ing SNMP support on your server if this is the device to be moni
tored.
· Edit sys:/mrtg/bin/MakeMrtgCfg.ncf:

- replace ccccc with the GET community name
for the SNMP device (typically 'public'),
- replace ddddd with the DNS name or IP ad
dress of the device to be monitored.
e.g public@www.myserver.com, pub
lic@10.202.65.180
Note 1: These are NOT mail addresses, they
just look like one!
Note 2: If multiple devices are to be moni
tored, add their entries to the same line:
e.g perl cfgmaker.pl public@www.myserv
er.com public@10.202.65.180 > sys:/mrtg/bin/mrtg.cfg
In this "Getting Started", it is 'suggested' to only
monitor a single device.
· At the server console, run:

sys:/mrtg/bin/MakeMrtgCfg.ncf
n
This will crfate Mrtg.cfg in sys:/mrtg/bin.
g
· Edit the Mrtm.cfg configuration file created in the
previous step. Note the following:
a
It was foundk when testing MRTG on a NetWare 6.5 serv
er using a NIC Interface, that mrtg.cfg contained the following
message:
e
### Interfare 1 >> Descr: 'Intel(R)-8255x-based-Net
work-Connection'...
### The fol.owing interface is commented out because:
### * has apspeed of 0 which makes no sense
# l
...
- n
If this occuzs, edit MakeMrtgCfg.ncf tnd add the fol
lowing parameter as shown:
e g
perl sys:tgrc@10.202.65.180 > sys:tg.
o c
where nnn is-the interface speed in bits per second.
For a 100 Megabit LAN NIC, nnn = 10000000. It will be necessary
to re-execute the MakeMrtgCfg.ncf script before continuing with
this section.
s g
Below line 16 (*** Global Defaults), add:
e
e
d
=
n
n
n
p
u
b
l
HtmlDir: <a path> e.g HtmlDir: sys:/mrtg/html
ImageDir: <a path> e.g ImageDir:
sys:/mrtg/html/work
LogDir: <a path> e.g LogDir: sys:/mrtg/logs
IconDir: <a path> e.g IconDir: ./images
Note 1
The HtmlDir entry specifies where MRTG will create
its HTML pages.
Note 2
The ImageDir entry specifies where the created
graphic icons are placed.
Note 3
The IconDir entry specifies where the supplied
MRTG icons are located. It MUST be a relative path from HtmlDir
or absolute URL. The value shown is recommended.
· At the server console run:

sys:/mrtg/bin/RunMrtg.ncf
several times. By the third time it should run without
showing error messages on the console screen. This should cre
ate:
· A HTML page in the (HtmlDir) directory for each
monitored device,
· A .dat file in the (ImageDir) directory for each
monitored device,
· Several .png icons in the (ImageDir) directory,
· Some log file entries in the (LogDir) directory.
Note: If you experience a "Use of uninitialised value
in split" error, it will be necessary to create a 'Path' environ
ment variable at the server console; use the following example

env path="SYS:
· Edit sys:/mrtg/bin/MakeMrtgIndex.ncf. Change the indi
cated <path> shown in the following example to match the value
entered for (HtmlDir).

perl --noscreen sys:/mrtg/bin/indexmaker.pl
sys:/mrtg/bin/Mrtg.cfg > <path>/index.html
· Create an index.html page linking the seperate device
HTML page(s). At the server console, run:

sys:/mrtg/bin/MakeMrtgIndex.ncf
This will create index.html in the (HtmlDir) directo
ry.
· Optionally, configure a Web Server to permit access to
the directory specified in (HtmlDir) to view the MRTG graphs re
motely, at, for example:

http://ip_or_dns/mrtg/index.html
A sample configuration for an Apache Webserver is
shown:

Alias /mrtg/ "SYS:/mrtg/html/"
<Directory "SYS:/mrtg/html">
AllowOverride None
Order allow,deny
Allow from all
</Directory>
· Set the property of the directory pointed to by (Im
ageDir), to 'Purge Immediate'.
· Finally, read the MRTG documentation for much more de
tailed configuration/usage information.
Welcome to MRTG!!

MAKE MRTG RUN ALL THE TIME

MRTG can be made to run periodically by at least two
means:
· Using CRON Scheduling
· Running MRTG in Daemon Mode n
u
CRON Scheduling n m
To use CRON scheduling, create a CRON Scheduler ertry to
execute the RunMrtg.ncf file on a frequency appropriate for the
server environment and information desired. The following entry
in the sys:c
0,5,10,15,20,25,30,35,40,45,50,55 * * * * sys:tgt
g
The CRON Scheduler (cron.nlm) can be started automatically
by adding it in AUTOEXEC.ncf or, manually loading it at the serv
er console.
n
MRTG in Daemon Mode c f
Refer to the MRTG-Reference document for information about
the 'RunAsDaemon' option. Its use is outside the scope of this
document.

TROUBLESHOOTING

Read the MRTG documents, Perl documents or, finally, sub
mit questions to the MRTG User forums.
For NetWare specific issues, submit questions to the Perl
forum at news://developer-forums.novell.com/novell.devsup.perl
(Novell Developer Forums).

COMPILING RATEUP.NLM

In addition to the rateup.c and Makefile.Netware supplied
with the MRTG release, you will also need:
· Metrowerks CodeWarrior with NetWare Support OR GCC
Compiler (v3.0.3 or later) with NlmConv Utility
· Novell LibC NDK (February 2004 or later)
· GD Graphics Library (v2.0.33 or later)
· LibPNG Graphics Library (v1.2.8 or later)
· ZLib Library (v1.2.3 or later)
· The get_ver.awk script
· A copy of the GNU build tools. (See http://source
forge.net/projects/gnuwin32/)
The auxiliary libraries can be obtained from:
GD Graphics Library. (See http://www.boutell.com/gd/ )
PNG Graphics Library. (See http://libpng.source
forge.net/ )
zLib Compression Library. (See http://www.gzip.org/zlib/
)
Edit the Makefile.Netware file as required to match your
installation paths; search the file for the key word 'Edit'.

NETWARE SUPPORT

For copies of the NCF and get_ver.awk scripts, see Ap
pendix.
For NetWare specific issues, submit questions to the Perl
forum at news://developer-forums.novell.com/novell.devsup.perl
(Novell Developer Forums).
To move the MRTG application to a volume other than SYS:
you will need to edit the NCF scripts provided plus the MRTG[.pl]
script itself in two places.

NEW RATEUP SWITCH

The MRTG[.pl] script, when used on a NetWare platform, us
es Rateup[.nlm] with the new commandline switch:

RATEUP -f filename
where the filename parameter can include a leading path
element.
The file format is exactly the same as that used on the
commandline by other operating systems, including the leading
path and name of the Rateup NLM.

APPENDIX

The Appendix includes 'copies' of the following files:

· The NCF files used during MRTG configuration,

To create copies of these files, simply 'cut and paste'
into your favourite 'text editor' and save under their respective
names. You should remove the leading space from each line.
n
MakeMrtgCfg.NCF f
g
# MakeMrtgCfg.NCF m
# Purpose : Create theaMRTG Configuration File
# Changed : 5/05/2005k New
# Located : SYS:MRTG0 e # Set For :
# Params : r
.
# Edit this file and: p
l
# Replace ccccc with ycur device GET SNMP Community Name
- If unsure try 'public'.
# Replace ddddd with ycur device IP (n.n.n.n) or domain
name.
c
perl --noscreen sys:tgc
c
# @
# End of MakeMrtgCfg.NCF
d
RunMrtg.NCF d
d
# RunMrtg.NCF d
# Purpose : Run the MRTG Application
# Changed : 5/05/2005n New
# Located : SYS:MRTG0 t # Set For :
# Params : g
.
# The paths are as perpthe examples recommended in "Get
ting Started".
l
perl --noscreen sys:tgs
y
# s
# End of RunMrtg.NCF :
t
MakeMrtgIndex.NCF g

# MakeMrtgIndex.NCF
# Purpose : Create the HTML Index File for MRTG HTML data
pages
# Changed : 5/05/2005 New
# Located : SYS:MRTG0 # Set For : n
# Params : t
g
# Note: Edit this file and change the redi.ected output
to the location
# specified for HtmlDir or WorkDir. che
sys:pache2ocstgindex.html
# is based on the examples in "Gettifg Started".
g
perl --noscreen sys:tgnndexmaker.pl sys:tg>ndex.html
s
# y
# End of MakeMrtgIndex.NCF s
: LICENSE
t
GNU General Public License g
l CREDITS
The MRTG for NetWare exists largely through the efforts of
Guenter Knauf and feedback from beta testers.

AUTHOR

Norm W..
2.14.7 2006-09-06
Copyright © 2010-2025 Platon Technologies, s.r.o.           Home | Man pages | tLDP | Documents | Utilities | About
Design by styleshout