2009-11-29 Raul Mateos <raulofpandora@gmail.com>
* linux/pandora_agent_installer: Added Ubuntu specific stop scripts. Added link removing with update-rc.d. Changed temp directory (it added duplicated data_out directories). Use tabs instead spaces. * linux/pandora_agent_daemon: Use log file in /var/log/pandora/ directory. * linux/pandora_agent.conf: Changed temp directory to the one created by installer. * linux/DEBIAN/control, DEBIAN/make_deb_package.sh: Changed string from rc2 to RC3. git-svn-id: https://svn.code.sf.net/p/pandora/code/trunk@2141 c3f86ba8-e40f-0410-aaad-9ba5e7f4b01f
This commit is contained in:
parent
957b7b4e88
commit
5458231989
|
@ -1,3 +1,17 @@
|
|||
2009-11-29 Raul Mateos <raulofpandora@gmail.com>
|
||||
|
||||
* linux/pandora_agent_installer: Added Ubuntu specific stop scripts.
|
||||
Added link removing with update-rc.d. Changed temp directory (it
|
||||
added duplicated data_out directories). Use tabs instead spaces.
|
||||
|
||||
* linux/pandora_agent_daemon: Use log file in /var/log/pandora/ directory.
|
||||
|
||||
* linux/pandora_agent.conf: Changed temp directory to the one created
|
||||
by installer.
|
||||
|
||||
* linux/DEBIAN/control, DEBIAN/make_deb_package.sh: Changed string from rc2
|
||||
to RC3.
|
||||
|
||||
2009-11-19 Sancho Lerena <slerena@artica.es>
|
||||
|
||||
* unix/pandora_agent_installer: Updated help to avoid confussion about force
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
package: PandoraFMS-Agent
|
||||
Version: 3.0.0.rc2
|
||||
Version: 3.0.0.RC3
|
||||
Architecture: all
|
||||
Priority: optional
|
||||
Section: admin
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
|
||||
pandora_agent_version="3.0.0.rc2"
|
||||
pandora_agent_version="3.0.0.RC3"
|
||||
|
||||
echo "Test if you has the tools for to make the packages."
|
||||
whereis dpkg-deb | cut -d":" -f2 | grep dpkg-deb > /dev/null
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
|
||||
server_ip localhost
|
||||
server_path /var/spool/pandora/data_in
|
||||
temporal /tmp
|
||||
temporal /var/spool/pandora/data_out
|
||||
logfile /var/log/pandora/pandora_agent.log
|
||||
|
||||
# Interval in seconds, 300 by default
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin
|
||||
PANDORA_PATH=/etc/pandora
|
||||
DAEMON=/usr/bin/pandora_agent
|
||||
LOGFILE=/var/log/pandora_agent.log
|
||||
LOGFILE=/var/log/pandora/pandora_agent.log
|
||||
|
||||
# This function replace pidof, not working in the same way in different linux distros
|
||||
|
||||
|
@ -57,7 +57,7 @@ case "$1" in
|
|||
echo "Pandora FMS Agent is not running, cannot stop it. Aborting now..."
|
||||
exit 1
|
||||
else
|
||||
echo "Stopping Pandora Agent."
|
||||
echo "Stopping Pandora FMS Agent."
|
||||
kill $PANDORA_PID > /dev/null 2>&1
|
||||
fi
|
||||
;;
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
# Linux Version (generic), for SuSe and Debian/Ubuntu only
|
||||
# other Linux distros could not work properly without modifications
|
||||
# Please see http://www.pandorafms.org
|
||||
# v3.0 Build 090810
|
||||
# v3.0.1 Build 091129
|
||||
# This code is licensed under GPL 2.0 license.
|
||||
# **********************************************************************
|
||||
|
||||
|
@ -67,6 +67,7 @@ get_distro () {
|
|||
}
|
||||
|
||||
uninstall () {
|
||||
DISTRO=`get_distro`
|
||||
echo "Removing Pandora FMS Agent..."
|
||||
rm -Rf $PANDORA_BIN
|
||||
rm -Rf $PANDORA_TEMP
|
||||
|
@ -75,11 +76,15 @@ uninstall () {
|
|||
rm -Rf $PANDORA_HOME
|
||||
rm -Rf $PANDORA_LOG
|
||||
rm -Rf $TENTACLE
|
||||
if [ "$DISTRO" == "UBUNTU" ]
|
||||
then
|
||||
# Removing linking daemon scripts
|
||||
update-rc.d -f pandora_agent_daemon remove
|
||||
fi
|
||||
echo "Done"
|
||||
}
|
||||
|
||||
install () {
|
||||
|
||||
DISTRO=`get_distro`
|
||||
OLDFILENAMETMP=`date +"%Y-%m-%d"`
|
||||
|
||||
|
@ -87,7 +92,7 @@ install () {
|
|||
|
||||
if [ -f $PANDORA_HOME ] && [ "$FORCE" = "0" ]
|
||||
then
|
||||
echo "Seems that default dir already exists. Please use --force to"
|
||||
echo "Seems that default dir already exists. Please use --force-install to"
|
||||
echo "force installer to install on $PANDORA_HOME"
|
||||
exit
|
||||
else
|
||||
|
@ -96,7 +101,7 @@ install () {
|
|||
|
||||
if [ -f $PANDORA_BIN ] && [ "$FORCE" = "0" ]
|
||||
then
|
||||
echo "Seems that $PANDORA_BIN already exists. Please use --force to"
|
||||
echo "Seems that $PANDORA_BIN already exists. Please use --force-install to"
|
||||
echo "force installer to reinstall overwriting it"
|
||||
echo " "
|
||||
exit
|
||||
|
@ -107,7 +112,7 @@ install () {
|
|||
# Create directories
|
||||
echo "Creating Pandora FMS Agent home directory at $PANDORA_HOME ..."
|
||||
mkdir $PANDORA_HOME 2> /dev/null
|
||||
mkdir -p $PANDORA_TEMP/data_out 2> /dev/null
|
||||
mkdir -p $PANDORA_TEMP 2> /dev/null
|
||||
mkdir $PANDORA_CFG 2> /dev/null
|
||||
mkdir /var/log/pandora 2> /dev/null
|
||||
|
||||
|
@ -157,7 +162,7 @@ install () {
|
|||
|
||||
echo "Setting secure permissions and ownership for all Pandora FMS Agent files..."
|
||||
chown -R root $PANDORA_HOME
|
||||
chmod -R 600 $PANDORA_TEMP/data_out
|
||||
chmod -R 600 $PANDORA_TEMP
|
||||
chmod 640 $PANDORA_LOG
|
||||
chgrp root $PANDORA_LOG
|
||||
|
||||
|
@ -167,11 +172,15 @@ install () {
|
|||
if [ "$DISTRO" == "UBUNTU" ]
|
||||
then
|
||||
echo "Linking start-up daemon script to /etc/rc2.d";
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc2.d/S90pandora_agent
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc2.d/S90pandora_agent_daemon
|
||||
echo "Linking stop daemon script";
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc0.d/K90pandora_agent_daemon
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc1.d/K90pandora_agent_daemon
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc6.d/K90pandora_agent_daemon
|
||||
else
|
||||
INITLV=`cat /etc/inittab | grep "[0-9]\:initdefault" | cut -f 2 -d ":"`
|
||||
echo "Linking start-up daemon script to /etc/rc.d/rc$INITLV.d";
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc.d/rc$INITLV.d/S90pandora_agent
|
||||
ln -s /etc/init.d/pandora_agent_daemon /etc/rc.d/rc$INITLV.d/S90pandora_agent_daemon
|
||||
fi
|
||||
|
||||
chown -R root:root $PANDORA_BIN
|
||||
|
|
Loading…
Reference in New Issue