Hello Everyone;
I am running Debian Etch and I tried to upgrade from 3.0 to 3.5 and I am
getting an error I don't understand. I removed all the opsview packages
and tried reinstalling a few times, but I am out of ideas.
apt-get install opsview
Reading package lists... Done
Building dependency tree... Done
Correcting dependencies... Done
The following extra packages will be installed:
opsview-base opsview-core opsview-perl opsview-web
The following NEW packages will be installed:
opsview-base opsview-core opsview-perl opsview-web
0 upgraded, 4 newly installed, 0 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 0B/23.6MB of archives.
After unpacking 118MB of additional disk space will be used.
Do you want to continue [Y/n]? y
WARNING: The following packages cannot be authenticated!
opsview-base opsview-perl opsview-core opsview-web
Install these packages without verification [y/N]? y
Preconfiguring packages ...
Selecting previously deselected package opsview-base.
(Reading database ... 22689 files and directories currently installed.)
Unpacking opsview-base (from .../opsview-base_3.5.0.3643-1etch1_i386.deb)
...
Selecting previously deselected package opsview-perl.
Unpacking opsview-perl (from .../opsview-perl_3.5.0.256-1etch1_i386.deb) ...
Setting up opsview-base (3.5.0.3643-1etch1) ...
Selecting previously deselected package opsview-core.
(Reading database ... 31025 files and directories currently installed.)
Unpacking opsview-core (from .../opsview-core_3.5.0.3643-1etch1_all.deb) ...
Selecting previously deselected package opsview-web.
Unpacking opsview-web (from .../opsview-web_3.5.0.3643-1etch1_all.deb) ...
Setting up opsview-perl (3.5.0.256-1etch1) ...
Setting up opsview-core (3.5.0.3643-1etch1) ...
Cannot read /usr/local/nagios/etc/opsview.conf: at -e line 3
Compilation failed in require at -e line 3.
BEGIN failed--compilation aborted at -e line 3.
Then I get a screen that says:
MySQL remote setup
â
â
â
â Since the opsview database is on the remote server , you
will need to run â
â some commands on the remote server as the mysql root user.
Please run: â
â /usr/local/nagios/bin/db_mysql
-t â
â to list the commands
required â
â
â
â <Ok>
I ran the command /usr/local/nagios/bin/db_mysql -t and I get the
following:
jabba:~# /usr/local/nagios/bin/db_mysql -t
Cannot read /usr/local/nagios/etc/opsview.conf: at -e line 3
Compilation failed in require at -e line 3.
BEGIN failed--compilation aborted at -e line 3.
CREATE DATABASE IF NOT EXISTS ;
GRANT ALL ON .* TO @localhost IDENTIFIED BY '';
GRANT ALL ON .* TO @'%' IDENTIFIED BY '';
GRANT SELECT ON .* TO @'%' IDENTIFIED BY '';
GRANT SELECT ON .* TO @'%' IDENTIFIED BY '';
CREATE DATABASE IF NOT EXISTS ;
GRANT ALL ON .* TO @localhost IDENTIFIED BY '';
GRANT ALL ON .* TO @'%' IDENTIFIED BY '';
GRANT SELECT ON .* TO @localhost IDENTIFIED BY '';
GRANT SELECT ON .* TO @'%' IDENTIFIED BY '';
GRANT SELECT, INSERT, DELETE, UPDATE ON .* TO @localhost IDENTIFIED BY '';
GRANT SELECT, INSERT, DELETE, UPDATE ON .* TO @'%' IDENTIFIED BY '';
CREATE DATABASE IF NOT EXISTS ;
GRANT ALL ON .* TO @localhost IDENTIFIED BY '';
GRANT ALL ON .* TO @'%' IDENTIFIED BY '';
GRANT SELECT ON .* TO @localhost IDENTIFIED BY '';
GRANT SELECT ON .* TO @'%' IDENTIFIED BY '';
CREATE DATABASE IF NOT EXISTS ;
GRANT ALL ON .* TO @localhost IDENTIFIED BY '';
GRANT ALL ON .* TO @'%' IDENTIFIED BY '';
So from looking at the error "Cannot read
/usr/local/nagios/etc/opsview.conf: at -e line 3"
I checked my opsview.conf and it looks good, I posted it below:
#
# Defaults configuration file for Opsview
#
# If you need to override any of these values, amend opsview.conf
# **WARNING** This file will be overwritten on an upgrade
#
# Rules for overriding:
# This file is read first
# Any variables in opsview.conf will override these
#
# To access from shell script, use: ". bin/opsview.sh"
# NOTE: If you change the passwords for an existing system, you need to
reload and restart Opsview and Opsview Web
# See http://docs.opsview.org/doku.php?id=opsview3:faq
# DB for Opsview
$dbuser = "opsview";
$dbpasswd = "password";
$db = "opsview";
$dbhost = "localhost";
$dbi = "dbi:mysql";
# ODW db information for datawarehousing
$odw_dbuser = "odw";
$odw_dbpasswd = "password";
$odw_db = "odw";
$odw_dbhost = "localhost";
$odw_dbi = "dbi:mysql";
# Use Catalyst::Engine::HTTP::Prefork
# This provides a persistent application server, but uses more memory
# See http://docs.opsview.org/doku.php?id=opsview3.0:prefork for details
$use_prefork = 0;
# Set $use_lighttpd to 1 to use Lighttpd between apache and opsview-web
# This is not fully supported yet
$use_lighttpd = 0;
$lighttpd_daemons = 16;
$lighttpd_socket = "/usr/local/nagios/var/opsview_web_socket";
# Set below to 1 if apache has been set up for port 443 use
$use_https = 0;
# DB information for Runtime
$runtime_dbuser = "nagios";
$runtime_dbpasswd = "password";
$runtime_db = "runtime";
$runtime_dbhost = "localhost";
$runtime_dbi = "dbi:mysql";
# Reports database
$reports_dbuser = "reporter";
$reports_dbpasswd = "password";
$reports_db = "reports";
$reports_dbhost = "localhost";
$reports_dbi = "dbi:mysql";
# Opsview will export database and create tarball of /usr/local/nagios/*
$backup_dir = "/usr/local/nagios/var/backups";
$backup_retention_days = 30;
# Set below to 1 for "rc.opsview cron_daily" to create backups
# else set to 0 to disable - backups can still be performed manually with
# "rc.opsview backup"
$daily_backup = 1;
# Directory to put automatically generated reports
$reports_archive = "/usr/local/nagios/var/reports";
# Days to keep snmptrapexceptions in runtime db
$snmptrapexception_retention_days = 60;
# Days to keep Nagios archive logs (holds availability information)
$archive_retention_days = 180;
# Days to keep non-updated rrd and mrtg files
$rrd_retention_days = 30;
# Days to keep snmptrap_tracing files in var/traps.db
$snmptrap_tracing_retention_days = 8;
# Number of concurrent tasks within Opsview
# Only affects nagconfgen at the moment. Usually linked to number of cpus
# A value of 0 means run everything at once
$max_parallel_tasks = 4;
# Turn off drag/drop ability in list view if below is set to 1
#$dragdrop_disabled = 1;
# If you want to change the logo used in the sidenav. Should be around 140 x
32 in size
# Should be the path as taken by the webserver
#$logo_path = "/images/weblogo1.png";
# Web page authentication
#
# This defines what to use for authentication. If "htpasswd", passwords
# for contacts will be stored in the DB and the Apache htpasswd file will be
# generated for logging in
$authentication = "htpasswd";
# This is the shared secret that the auth ticket system will use for
authentication
# It should be automatically changed in opsview.conf
$authtkt_shared_secret = "shared-secret-please-change";
# This is the domain name to set on the authtkt cookie so that it
# can be shared between servers. It should match the subdomain of all
# other servers that also use this cookie. If blank it defaults
# to the FQDN of the opsview server. NOTE: any browser logged in
# prior to changing the domain must manually remove the cookie or wait
# until the cookie expires before access can be regained
$authtkt_domain = '';
# SNMP trap debugging. Increases load on snmptrap processing. Switch on for
short periods only
#$snmptrap_debug = 1;
# For reverse initiated slaves, need to set below to 1
# Ports from 25800 upwards maybe used on master
# NOTE: requires 'autossh' to be installed on the slaves
$slave_initiated = 0;
$slave_base_port = 25800;
# Changes nagios.cfg's interval_length to seconds
# This will be on by default sometime in the future
# If off, uses minutes as the interval
# WARNING 1: If you have already entered values into any host or service
pages, you must update them appropriately, specifically
# the check_interval, retry_check_interval and notification_interval
# WARNING 2: You must change the values in Advanced->SNMP Interface Polling
manually
$nagios_interval_length_in_seconds = 0;
# This is the instance id for Opsview, to allow multiple Opsview masters to
write to a single
# ODW database. This can be any integer from 1 to 20. Ensure this value is
not duplicated between
# all the Opsview instances.
# WARNING: See
http://docs.opsview.org/doku.php?id=opsview{version}:sharedodw for other
limitations
$opsview_instance_id = 1;
# NMIS settings
# change the number of threads to use when collecting data from devices
$nmis_maxthreads = 2;
##########################################################################################################
# The next section contains examples of how to change configuration
parameters in nagios.cfg and cgi.cfg
# If you wish to change any parameters then copy entire section over to
opsview.conf including 'EOF' line,
# then uncomment relevant line or add your own in.
# See http://docs.opsview.org/ for more details
$overrides = <<'EOF';
# Uncomment next line to change pager/SMS number for Opsview administrator
# [email protected]
# Uncomment next line to set maximum concurrent service checks, use this to
tune performance settings
# nagios_max_concurrent_checks=50
# Uncomment next line to disable notifications (for system upgrades and
maintenance)
# nagios_enable_notifications=0
# Uncomment next line to disable authentication for access to monitoring UI,
use for debugging only
# cgi_use_authentication=0
# Uncomment next line to change refresh rate for Nagios monitoring screens
# cgi_refresh_rate=30
# Uncomment next line to enable logging of passive check results
# nagios_log_passive_checks=1
EOF
1;
John Harris
The Sage Colleges
Have a technology question? Check out the new Knowledge Base
http://kb.sage.edu for answers to some of the most common technology
questions we have received.
Think Green! Before printing this e-mail ask the question, is it
necessary?
CONFIDENTIALITY NOTICE:This email, including any attachments, is for the
sole use of the intended recipient(s) and may contain confidential and
privileged information. Any unauthorized review, use, disclosure, or
distributions prohibited. If you received this email and are not the
intended recipient, please inform the sender by email reply and destroy all
copies of the original message.
_______________________________________________
Opsview-users mailing list
[email protected]
http://lists.opsview.org/lists/listinfo/opsview-users