Modified: trunk/CHANGES
===================================================================
--- trunk/CHANGES 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/CHANGES 2013-02-04 16:23:05 UTC (rev 11339)
@@ -24,6 +24,7 @@
Added logging for check_snmp_interfaces_cascade for situations where threshold > 100%
Changed Nagios CGI date format to be iso8601 on fresh installs
Updated NRD configuration to apply results into checkresults with timestamp value for Nagios to process in order
+ Removed all use_prefork and use_lighttpd references from code
NOTICES:
Only a subset of Nagios environment macros are available. Plugins will only get environment variables if
specified within the plugin. Notifications and event handlers have a limited set of macros. See
Modified: trunk/opsview-core/bin/opsview.sh
===================================================================
--- trunk/opsview-core/bin/opsview.sh 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/bin/opsview.sh 2013-02-04 16:23:05 UTC (rev 11339)
@@ -64,11 +64,7 @@
RUNTIME_DBUSER="$Settings::runtime_dbuser"
RUNTIME_DBPASSWD="$Settings::runtime_dbpasswd"
RUNTIME_DBHOST="localhost"
-USE_PREFORK="$Settings::use_prefork"
BIND_ADDRESS="$Settings::bind_address"
-USE_LIGHTTPD="$Settings::use_lighttpd"
-LIGHTTPD_DAEMONS="$Settings::lighttpd_daemons"
-LIGHTTPD_SOCKET="$Settings::lighttpd_socket"
USE_HTTPS="$Settings::use_https"
NMIS_MAXTHREADS="$Settings::nmis_maxthreads"
STATUS_DAT="$Settings::status_dat"
Deleted: trunk/opsview-core/bin/rc.lighttpd-solaris
===================================================================
--- trunk/opsview-core/bin/rc.lighttpd-solaris 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/bin/rc.lighttpd-solaris 2013-02-04 16:23:05 UTC (rev 11339)
@@ -1,75 +0,0 @@
-#!/bin/sh
-#
-# AUTHORS:
-# Copyright (C) 2003-2012 Opsview Limited. All rights reserved
-#
-# This file is part of Opsview
-#
-# Opsview 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.
-#
-# Opsview 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 Opsview; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-#
-
-LIGHTTPD=/opt/coolstack/lighttpd/sbin/lighttpd
-CONF=/usr/local/nagios/installer/lighttp_fastcgi_solaris.conf
-OPSVIEW=/usr/local/nagios/bin/opsview.sh
-
-start(){
- $LIGHTTPD -f $CONF
-}
-
-stop() {
- pkill -f $LIGHTTPD
-}
-
-restart() {
- stop
- sleep 2
- start
-}
-
-verify() {
- $LIGHTTPD -t -f $CONF 1>/dev/null
-}
-
-if [ ! -f $LIGHTTPD ]; then
- echo "Coolstack Lighttpd not installed"
- exit 1
-fi
-
-if [ ! -f $OPSVIEW ]; then
- echo "Opsview not installed"
- exit 1
-fi
-
-eval `$OPSVIEW`
-
-if [ "$USE_LIGHTTPD" = 0 ]; then
- exit 0
-fi
-
-if [ ! -d /var/log/lighttpd ]; then
- mkdir -p /var/log/lighttpd
- chown nobody:nogroup /var/log/lighttpd
-fi
-
-case "$1" in
- start) verify && start;;
- stop) stop;;
- restart) verify && restart;;
- reload) verify && restart;;
- *)
- echo "Usage: $0 {start|stop|restart}"
- exit 1
- ;;
-esac
Modified: trunk/opsview-core/etc/opsview.defaults
===================================================================
--- trunk/opsview-core/etc/opsview.defaults 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/etc/opsview.defaults 2013-02-04 16:23:05 UTC (rev 11339)
@@ -19,18 +19,8 @@
$db = "opsview";
$dbi = "dbi:mysql";
-# Use Catalyst::Engine::HTTP::Prefork
-# This provides a persistent application server, but uses more memory
-# See http://docs.opsview.com/doku.php?id=opsview-core:prefork for details
-$use_prefork = 1;
$bind_address = "0.0.0.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;
Modified: trunk/opsview-core/filelist
===================================================================
--- trunk/opsview-core/filelist 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/filelist 2013-02-04 16:23:05 UTC (rev 11339)
@@ -648,7 +648,6 @@
f nagios:nagios 0444 /usr/local/nagios/installer/crontab-slave.nagios installer/crontab-slave.nagios
f nagios:nagios 0444 /usr/local/nagios/installer/crontab.nagios installer/crontab.nagios
f nagios:nagios 0555 /usr/local/nagios/installer/import_excel.xls installer/import_excel.xls
-f nagios:nagios 0444 /usr/local/nagios/installer/lighttp_fastcgi.conf installer/lighttp_fastcgi.conf
f nagios:nagios 0444 /usr/local/nagios/installer/logrotate_opsview installer/logrotate_opsview
f nagios:nagios 0555 /usr/local/nagios/installer/migrate_nagios installer/migrate_nagios
f nagios:nagios 0555 /usr/local/nagios/installer/migrate_rrds installer/migrate_rrds
Modified: trunk/opsview-core/lib/Opsview/Config.pm
===================================================================
--- trunk/opsview-core/lib/Opsview/Config.pm 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/lib/Opsview/Config.pm 2013-02-04 16:23:05 UTC (rev 11339)
@@ -57,12 +57,8 @@
sub overrides { return $Settings::overrides }
sub logo_path { return $Settings::logo_path || '' }
-sub use_prefork { return $Settings::use_prefork }
-sub use_lighttpd { return $Settings::use_lighttpd }
-sub lighttpd_daemons { return $Settings::lighttpd_daemons }
-sub lighttpd_socket { return $Settings::lighttpd_socket }
-sub use_https { return $Settings::use_https }
-sub bind_address { return $Settings::bind_address || "0.0.0.0" }
+sub use_https { return $Settings::use_https }
+sub bind_address { return $Settings::bind_address || "0.0.0.0" }
sub authentication { return $Settings::authentication || "htpasswd" }
Modified: trunk/opsview-core/t/002filelist.t
===================================================================
--- trunk/opsview-core/t/002filelist.t 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/t/002filelist.t 2013-02-04 16:23:05 UTC (rev 11339)
@@ -68,7 +68,6 @@
"bin/fakeslavegen" => 1,
"bin/mrtghtmlgen.pl" => 1,
"bin/rc.opsview.fakeslaves" => 1,
- "bin/rc.lighttpd-solaris" => 1,
"bin/wmic" => 1,
"version" => 1,
"version.in" => 1,
Modified: trunk/opsview-core/t/10master_config.t
===================================================================
--- trunk/opsview-core/t/10master_config.t 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/t/10master_config.t 2013-02-04 16:23:05 UTC (rev 11339)
@@ -22,26 +22,21 @@
slave_initiated => 0,
slave_base_port => 25800,
- # For hudson tests, prefork is set to 0
- use_prefork => 0,
- use_lighttpd => 0,
- lighttpd_daemons => 16,
- lighttpd_socket => '/usr/local/nagios/var/opsview_web_socket',
- use_https => 0,
- authentication => 'htpasswd',
- authtkt_shared_secret => Opsview::Test::Cfg->shared_secret,
- authtkt_domain => '',
- dbi => 'dbi:mysql',
- db => Opsview::Test::Cfg->opsview,
- dbuser => 'opsview',
- dbpasswd => Opsview::Test::Cfg->opsview_passwd,
- runtime_dbi => 'dbi:mysql',
- runtime_db => Opsview::Test::Cfg->runtime,
- runtime_dbuser => 'nagios',
- runtime_dbpasswd => Opsview::Test::Cfg->runtime_passwd,
- archive_retention_days => 180,
- rrd_retention_days => 30,
- opsview_instance_id => 1,
+ use_https => 0,
+ authentication => 'htpasswd',
+ authtkt_shared_secret => Opsview::Test::Cfg->shared_secret,
+ authtkt_domain => '',
+ dbi => 'dbi:mysql',
+ db => Opsview::Test::Cfg->opsview,
+ dbuser => 'opsview',
+ dbpasswd => Opsview::Test::Cfg->opsview_passwd,
+ runtime_dbi => 'dbi:mysql',
+ runtime_db => Opsview::Test::Cfg->runtime,
+ runtime_dbuser => 'nagios',
+ runtime_dbpasswd => Opsview::Test::Cfg->runtime_passwd,
+ archive_retention_days => 180,
+ rrd_retention_days => 30,
+ opsview_instance_id => 1,
nagios_interval_length_in_seconds => 0,
max_parallel_tasks => 4,
backup_dir => '/usr/local/nagios/var/backups',
Modified: trunk/opsview-core/t/12master_opsview_sh.t
===================================================================
--- trunk/opsview-core/t/12master_opsview_sh.t 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-core/t/12master_opsview_sh.t 2013-02-04 16:23:05 UTC (rev 11339)
@@ -34,11 +34,7 @@
RUNTIME_DBUSER="nagios"
RUNTIME_DBPASSWD="' . Opsview::Test::Cfg->runtime_passwd . '"
RUNTIME_DBHOST="localhost"
-USE_PREFORK="0"
BIND_ADDRESS="0.0.0.0"
-USE_LIGHTTPD="0"
-LIGHTTPD_DAEMONS="16"
-LIGHTTPD_SOCKET="/usr/local/nagios/var/opsview_web_socket"
USE_HTTPS="0"
NMIS_MAXTHREADS="2"
STATUS_DAT="/usr/local/nagios/var/status.dat"
Modified: trunk/opsview-web/bin/opsview-web
===================================================================
--- trunk/opsview-web/bin/opsview-web 2013-02-04 15:47:19 UTC (rev 11338)
+++ trunk/opsview-web/bin/opsview-web 2013-02-04 16:23:05 UTC (rev 11339)
@@ -76,19 +76,8 @@
wrapper="./opsview-web-server"
fi
printf "Starting opsview-web: "
- if [ "$USE_LIGHTTPD" = "0" ] && [ "$USE_PREFORK" = "0" ]; then
- $wrapper script/opsview_web_server.pl $args
- RETVAL=$?
- else
- if [ "$USE_PREFORK" != "0" ] ; then
- # This no longer uses HTTP::Prefork. It looks like Catalyst always uses Starman now, which is fine
- $wrapper script/opsview_web_server.pl $args
- RETVAL=$?
- else
- $wrapper script/opsview_web_fastcgi.pl -e -d -n $LIGHTTPD_DAEMONS -p $pidfile -l $LIGHTTPD_SOCKET
- RETVAL=$?
- fi
- fi
+ $wrapper script/opsview_web_server.pl $args
+ RETVAL=$?
# Catalyst 5.9 returns back very quickly, before server is ready
# We cause this to wait until the server is ready by checking for pid file
@@ -152,14 +141,6 @@
return 1
fi
- # create a dummy socket file to move into place - this prevents lighttpd
- # version 1.4.15 and before from spinning when fastcgi process stops
- new_socket="${LIGHTTPD_SOCKET}.temp"
- rm -f $new_socket
- touch $new_socket
- chmod go-rwx $new_socket
- mv -f "$new_socket" "$LIGHTTPD_SOCKET"
-
printf "Stopping opsview-web: "
kill_then_wait_30_seconds_before_minus_nine $pid
rm -f $pidfile
@@ -218,7 +199,7 @@
. /usr/local/nagios/bin/profile
eval `/usr/local/nagios/bin/opsview.sh`
-test "x$USE_LIGHTTPD" = "x" && die "Couldn't run opsview.sh"
+test "x$DBUSER" = "x" && die "Couldn't run opsview.sh"
if [ "$USE_HTTPS" -eq 1 ]; then
HTTPS=on