2009-09-01 Sancho Lerena <slerena@artica.es>
* pandora_server.spec: Using chkconfig for service install. Using the new logrotate config for automatic logfile management. * pandora_server_installer: Using new logrotate config file. * bin/pandora_server: Enterprise load notice are shown after main banner. * lib/PandoraFMS/Config.pm: Updated version (again). * util/pandora_logrotate: New conf file for /etc/logrotate.d/ git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@1900 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
13b2d71e71
commit
50ebfd1375
|
@ -1,3 +1,16 @@
|
|||
2009-09-01 Sancho Lerena <slerena@artica.es>
|
||||
|
||||
* pandora_server.spec: Using chkconfig for service install. Using the new
|
||||
logrotate config for automatic logfile management.
|
||||
|
||||
* pandora_server_installer: Using new logrotate config file.
|
||||
|
||||
* bin/pandora_server: Enterprise load notice are shown after main banner.
|
||||
|
||||
* lib/PandoraFMS/Config.pm: Updated version (again).
|
||||
|
||||
* util/pandora_logrotate: New conf file for /etc/logrotate.d/
|
||||
|
||||
2009-08-28 Ramon Novoa <rnovoa@artica.es>
|
||||
|
||||
* pandora_server.spec,
|
||||
|
|
|
@ -33,9 +33,6 @@ use PandoraFMS::WMIServer;
|
|||
use PandoraFMS::PluginServer;
|
||||
use PandoraFMS::PredictionServer;
|
||||
|
||||
# Load enterprise module
|
||||
enterprise_load () && print " [*] Pandora FMS Enterprise module loaded.\n";
|
||||
|
||||
# Global vars
|
||||
my %Config;
|
||||
my @Servers;
|
||||
|
@ -83,6 +80,9 @@ $SIG{'ALRM'} = 'IGNORE';
|
|||
pandora_init(\%Config, 'Pandora FMS Server');
|
||||
pandora_load_config (\%Config);
|
||||
|
||||
# Load enterprise module
|
||||
enterprise_load () && print " [*] Pandora FMS Enterprise module loaded.\n";
|
||||
|
||||
# Daemonize and put in background
|
||||
if ($Config{'daemon'} == 1) {
|
||||
print_message (\%Config, " [*] Backgrounding Pandora FMS Server process.\n\n", 0);
|
||||
|
|
|
@ -37,7 +37,7 @@ our @EXPORT = qw(
|
|||
|
||||
# version: Defines actual version of Pandora Server for this module only
|
||||
my $pandora_version = "3.0-dev";
|
||||
my $pandora_build = "PS090819";
|
||||
my $pandora_build = "PS090901";
|
||||
our $VERSION = $pandora_version." ".$pandora_build;
|
||||
|
||||
# Setup hash
|
||||
|
|
|
@ -76,16 +76,11 @@ rm -fr $RPM_BUILD_ROOT
|
|||
exit 0
|
||||
|
||||
%post
|
||||
ln -s /etc/init.d/pandora_server /etc/rc.d/rc5.d/S99pandora_server
|
||||
ln -s /etc/init.d/pandora_server /etc/rc.d/rc3.d/S99pandora_server
|
||||
ln -s /etc/init.d/pandora_server /etc/rc.d/rc2.d/S99pandora_server
|
||||
ln -s /etc/init.d/pandora_server /etc/rc.d/rc0.d/K99pandora_server
|
||||
ln -s /etc/init.d/tentacle_serverd /etc/rc.d/rc5.d/S99tentacle_serverd
|
||||
ln -s /etc/init.d/tentacle_serverd /etc/rc.d/rc3.d/S99tentacle_serverd
|
||||
ln -s /etc/init.d/tentacle_serverd /etc/rc.d/rc2.d/S99tentacle_serverd
|
||||
ln -s /etc/init.d/tentacle_serverd /etc/rc.d/rc0.d/K99tentacle_serverd
|
||||
chkconfig -s pandora_server on
|
||||
chkconfig -s tentacle_serverd on
|
||||
echo "/usr/share/pandora_server/util/pandora_db /etc/pandora/pandora_server.conf" > /etc/cron.daily/pandora_db
|
||||
chmod 750 /etc/cron.daily/pandora_db
|
||||
cp -aRf util/pandora_logrotate /etc/logrotate.d/pandora
|
||||
|
||||
if [ ! -d /etc/pandora ] ; then
|
||||
mkdir -p /etc/pandora
|
||||
|
@ -108,15 +103,8 @@ fi
|
|||
%if "%{_vendor}" == "redhat"
|
||||
/sbin/chkconfig --del pandora_server
|
||||
%endif
|
||||
rm -Rf /etc/pandora/pandora_server.conf
|
||||
rm -Rf /etc/rc.d/rc5.d/S99pandora_server
|
||||
rm -Rf /etc/rc.d/rc3.d/S99pandora_server
|
||||
rm -Rf /etc/rc.d/rc2.d/S99pandora_server
|
||||
rm -Rf /etc/rc.d/rc0.d/K99pandora_server
|
||||
rm -Rf /etc/rc.d/rc5.d/S99tentacle_serverd
|
||||
rm -Rf /etc/rc.d/rc3.d/S99tentacle_serverd
|
||||
rm -Rf /etc/rc.d/rc2.d/S99tentacle_serverd
|
||||
rm -Rf /etc/rc.d/rc0.d/K99tentacle_serverd
|
||||
chkconfig -d pandora_server
|
||||
chkconfig -d tentacle_serverd
|
||||
|
||||
%files
|
||||
|
||||
|
|
|
@ -146,6 +146,9 @@ install () {
|
|||
ln -s /usr/bin/pandora_server /usr/local/bin/pandora_server 2> /dev/null
|
||||
fi
|
||||
|
||||
echo "Creating logrotate.d entry for Pandora FMS log management"
|
||||
cp util/pandora_logrotate /etc/logrotate.d/pandora
|
||||
|
||||
if [ "$SECOPT" != "--no-tentacle" ]
|
||||
then
|
||||
if [ "$DISTRO" == "UBUNTU" ]
|
||||
|
|
|
@ -0,0 +1,13 @@
|
|||
/var/log/pandora/* {
|
||||
weekly
|
||||
missingok
|
||||
rotate 52
|
||||
compress
|
||||
delaycompress
|
||||
notifempty
|
||||
create 640 root root
|
||||
sharedscripts
|
||||
postrotate
|
||||
for i in `ls -1 /etc/init.d/pandora_*`;do $i stop; $i start; done
|
||||
endscript
|
||||
}
|
Loading…
Reference in New Issue