2009-10-30 Miguel de Dios <miguel.dedios@artica.es>
* Fix the mistake in SVN. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2065 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
816ab89efe
commit
f6f47894ed
|
@ -0,0 +1 @@
|
|||
/etc/pandora/pandora_agent.conf
|
|
@ -0,0 +1,10 @@
|
|||
package: PandoraFMS-Agent
|
||||
Version: 3.0.0.rc1
|
||||
Architecture: all
|
||||
Priority: optional
|
||||
Section: admin
|
||||
Installed-Size: 260
|
||||
Maintainer: Miguel de Dios <miguel.dedios@artica.es>
|
||||
Homepage: http://pandorafms.org/
|
||||
Depends: coreutils, perl
|
||||
Description: andora FMS agents are based on native languages in every platform: scripts that can be written in any language. It’s possible to reproduce any agent in any programming language and can be extended without difficulty the existing ones in order to cover aspects not taken into account up to the moment. These scripts are formed by modules that each one gathers a "chunk" of information. Thus, every agent gathers several "chunks" of information; this one is organized in a data set and stored in a single file, called data file.
|
|
@ -0,0 +1,36 @@
|
|||
#!/bin/bash
|
||||
|
||||
PANDORA_LOG=/var/log/pandora/pandora_agent.log
|
||||
PANDORA_BIN=/usr/bin/pandora_agent
|
||||
PANDORA_HOME=/usr/share/pandora_agent
|
||||
PANDORA_TEMP=/var/spool/pandora/data_out
|
||||
PANDORA_CFG=/etc/pandora
|
||||
|
||||
LOG_TIMESTAMP=`date +"%Y/%m/%d %H:%M:%S"`
|
||||
|
||||
echo "Linking Pandora FMS Agent plugins directory to $PANDORA_CFG/plugins..."
|
||||
rm $PANDORA_CFG/plugins 2> /dev/null
|
||||
ln -s $PANDORA_HOME/plugins $PANDORA_CFG 2> /dev/null
|
||||
|
||||
echo "Linking Pandora FMS Agent configuration to $PANDORA_CFG/pandora_agent.conf..."
|
||||
rm $PANDORA_CFG/pandora_agent.conf 2> /dev/null
|
||||
ln -s $PANDORA_HOME/pandora_agent.conf $PANDORA_CFG/pandora_agent.conf
|
||||
|
||||
echo "Start log of agent."
|
||||
echo "$LOG_TIMESTAMP Pandora FMS installer has created this file at startup" > $PANDORA_LOG
|
||||
|
||||
echo "Setting secure permissions and ownership for all Pandora FMS Agent files..."
|
||||
chmod 700 $PANDORA_BIN
|
||||
chmod 600 $PANDORA_HOME/pandora_agent.conf
|
||||
chmod -R 700 $PANDORA_HOME/plugins
|
||||
chown -R root $PANDORA_HOME
|
||||
chmod -R 600 $PANDORA_TEMP
|
||||
chmod 640 $PANDORA_LOG
|
||||
chgrp root $PANDORA_LOG
|
||||
chown -R root:root $PANDORA_BIN
|
||||
|
||||
INITLV=`cat /etc/inittab | grep "[0-9]\:initdefault" | cut -f 2 -d ":"`
|
||||
echo "Linking start-up daemon script to /etc/rc$INITLV.d";
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc$INITLV.d/S90pandora_agent
|
||||
|
||||
echo "Please, now setup the $PANDORA_HOME/pandora_agent.conf and before start the /etc/init.d/pandora_agent_daemon"
|
|
@ -0,0 +1,12 @@
|
|||
#!/bin/bash
|
||||
|
||||
echo Stop Pandora agent daemon
|
||||
/etc/init.d/pandora_agent_daemon stop
|
||||
|
||||
PANDORA_CFG=/etc/pandora
|
||||
|
||||
rm -rf $PANDORA_CFG/plugins
|
||||
rm -rf $PANDORA_CFG/pandora_agent.conf
|
||||
|
||||
INITLV=`cat /etc/inittab | grep "[0-9]\:initdefault" | cut -f 2 -d ":"`
|
||||
rm /etc/rc$INITLV.d/S90pandora_agent
|
Loading…
Reference in New Issue