Installation Guide - Debian Linux
Before you start
- For supported Debian releases please refer to platforms.
- When planning your system please see our design notes for further information on planning for separate database servers, disk partitioning and security.
Preparation
Prerequisites
See the installation prerequisites information to setup users, groups and MySQL.
Importing Repository Signatures
For security, this repository is gpg signed. Follow our instructions to add the key to your server.
If you do not import our gpg keys, you could see errors such as:
W: GPG error: https://downloads.opsview.com squeeze Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY FB4C675977CB2CF6
The “NO_PUBKEY” portion of this message indicates that your system does not have the public key for this repository and so cannot verify its contents. You can ignore these warnings and import the keys later.
You could also see:
WARNING: The following packages cannot be authenticated! opsview-perl opsview-base libapache2-mod-auth-tkt-prefork-opsview opsview-core opsview-web opsview Install these packages without verification [y/N]?
You can continue, though we recommend you verify the packages.
Opsview repositories
To install Opsview, use your favourite editor to edit the file /etc/apt/sources.list
(or create a new file /etc/apt/sources.list.d/opsview.list
) and add the following line to it:
# Opsview packages deb http://downloads.opsview.com/opsview-core/latest/apt <OS> main
Where:
- OS is your distribution name, such as etch or lenny
For example:
deb http://downloads.opsview.com/opsview-core/latest/apt lenny main
Updating the Package Lists
When configuration is complete, update the repository information:
apt-get update
Installation
Once the sources list has been updated to include the Opsview apt repository, the latest release of Opsview can be installed by running the following command as root.
apt-get install opsview
You may get prompted for the mysql root user password. This is required to setup the databases used by Opsview.
The Opsview Web server is now listening on port 3000, i.e. http://opsview.example.com:3000/.
/usr/local/nagios/etc/opsview.conf
, add the following and change the secret value to be a unique string:
$authtkt_shared_secret = "shared-secret-please-change";
Restart Opsview Web for this value to take effect: /etc/init.d/opsview-web restart
.
Using Apache as a proxy server
The performance of Opsview will be significantly improved by using Apache at the front end. All the following commands should be run as root
.
Firstly, copy the Apache configuration file into the appropriate location:
cp /usr/local/nagios/installer/apache_proxy.conf /etc/apache2/sites-available/opsview a2ensite opsview a2dissite default
Then, edit the Apache configuration file so that the same shared secret is used:
TKTAuthSecret "shared-secret-please-change"
You will also need to install the Apache proxy_html module in order to use this configuration. On Debian, you can install the libapache2-mod-proxy-html package:
apt-get install libapache2-mod-proxy-html a2enmod proxy_http
Now Apache can be restarted
/etc/init.d/apache2 force-reload
You can now access Opsview at http://opsview.example.com/
Logging in
Once Opsview has been installed, a single administrative user will have been created. The credentials for this user are:
username: admin password: initial
You should change this password to prevent unauthorised access to Opsview - this can be done from the Administrator link at the top right of the page.
Check out our quick start guide to help you get familiar with Opsview.
Upgrading Opsview
Opsview can be upgraded by running the following command as root:
apt-get install opsview
See the upgrade notes before doing any upgrades.
Troubleshooting
SNMP MIBs Missing
On Debian squeeze
, SNMP MIBs are not installed by default.
You will need to install the SNMP MIBs manually with:
apt-get install snmp-mibs-downloader
See http://wiki.debian.org/SNMP for more information.
Note, you may still get some MIB reading errors, for example:
$ snmpwalk -mALL -v2c -cpublic host | head Unlinked OID in IPATM-IPMC-MIB: marsMIB ::= { mib-2 57 } Undefined identifier: mib-2 near line 18 of /usr/share/mibs/ietf/IPATM-IPMC-MIB Bad operator (INTEGER): At line 73 in /usr/share/mibs/ietf/SNMPv2-PDU Undefined OBJECT-GROUP (diffServMIBMultiFieldClfrGroup): At line 2195 in /usr/share/mibs/ietf/IPSEC-SPD-MIB Undefined OBJECT-GROUP (diffServMultiFieldClfrNextFree): At line 2157 in /usr/share/mibs/ietf/IPSEC-SPD-MIB Undefined OBJECT-GROUP (diffServMIBMultiFieldClfrGroup): At line 2062 in /usr/share/mibs/ietf/IPSEC-SPD-MIB Expected "::=" (RFC5644): At line 493 in /usr/share/mibs/iana/IANA-IPPM-METRICS-REGISTRY-MIB Expected "{" (EOF): At line 651 in /usr/share/mibs/iana/IANA-IPPM-METRICS-REGISTRY-MIB Bad object identifier: At line 651 in /usr/share/mibs/iana/IANA-IPPM-METRICS-REGISTRY-MIB Bad parse of OBJECT-IDENTITY: At line 651 in /usr/share/mibs/iana/IANA-IPPM-METRICS-REGISTRY-MIB RFC1213-MIB::sysDescr.0 = STRING: "Cisco Internetwork Operating System Software IOS (tm) C2600 Software (C2600-J1S3-M), Version 12.2(15)T7, RELEASE SOFTWARE (fc2) TAC Support: http://www.cisco.com/tac Copyright (c) 1986-2003 by cisco Systems, Inc. Compiled Sat 09-Aug-03 07:18 by ccai" RFC1213-MIB::sysObjectID.0 = OID: SNMPv2-SMI::enterprises.9.1.186 DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (813825536) 94 days, 4:37:35.36 RFC1213-MIB::sysContact.0 = STRING: "support@opsera.com" RFC1213-MIB::sysName.0 = STRING: "2611" RFC1213-MIB::sysLocation.0 = STRING: "Reading"
MRTG Emails Due to Permissions
NOTE: there maybe a bug in the mrtg
package which may cause a warning email to be sent to the system administrator every 5 minutes. This can be fixed by running:
sudo mkdir /var/www/mrtg
See this bug report and also this one for more information
MRTG Warning Email
Subroutine SNMP_Session::sockaddr_in6 redefined at /usr/share/perl/5.14/Exporter.pm line 67. at /usr/share/perl5/SNMP_Session.pm line 149
Subroutine SNMPv1_Session::pack_sockaddr_in6 redefined at /usr/share/perl/5.14/Exporter.pm line 67. at /usr/share/perl5/SNMP_Session.pm line 608
If the system administrator receives an email containing messages similar to the ones above, the cause is the system MRTG having an issue with the system SNMP_Session. This is not an Opsview problem as such, but can be rectified by replacing all “import Socket6;” lines in /usr/share/perl5/SNMP_Session.pm with “Socket6->import(qw(inet_pton getaddrinfo));”. We've only seen this on Debian 7 systems.