Outils personnels

Installation de Shinken sur une Debian : Différence entre versions

De wikiGite

(Aucune différence)

Version du 31 mai 2011 à 14:57

Version Arch & Perl

perl -e 'use Config; print "$Config{archname} \n"'
perl -e 'use Config; print "$Config{version} \n"'
Configuration file folder : /etc/shinken
Log file : /var/lib/shinken/nagios.log
Shinken startup script : /etc/init.d/shinken
Thruk web interface URL : http://<hostname>:3000

Pour relancer Shinken:

/etc/init.d/shinken restart

If you follow these instructions, here's what you'll end up with:

Shinken and the plugins will be installed underneath

”/usr/local/shinken”

Required Packages

sudo apt-get install python pyro git-core python-setuptools
apt-get install python python-dev python-setuptools pyro libgd2-xpm-dev nagios-plugins git-core

Create Account Information

Become the root user.

sudo su -

Create a new shinken user account and give it a password.

/usr/sbin/useradd -m shinken
passwd shinken

On Ubuntu server edition (9.10 and possible newer versions), you will need to also add a shinken group (it's not created by default). You should be able to skip this step on desktop editions of Ubuntu.

/usr/sbin/groupadd shinken
/usr/sbin/usermod -G shinken shinken

Add the apache user to this group to allow external commands to be send from the web interface.

/usr/sbin/usermod -G shinken www-data

Download Shinken and the Plugins

Create a directory for storing the downloads.

mkdir ~/downloads
cd ~/downloads

Download the source code of Shinken and the Shinken plugins (visit http://www.nagios.org/download/ for links to the latest versions of the plugins). At the time of writing, the latest versions plugins were 1.4.13.

git clone git://shinken.git.sourceforge.net/gitroot/shinken/shinken

Install Shinken (repasser en utilisateur normal)

cd shinken
python setup.py install --install-scripts=/usr/bin

Don't start Shinken yet - there's still more that needs to be done… Customize Configuration

Sample configuration files have now been installed in the ”/etc/shinken/” directory. These sample files should work fine for getting started with Shinken. You'll need to make just one change before you proceed… Install the Nagios Plugins to use with Shinken

You can download plugins from source, but your debian-like administrator will just will you :

cp libexec/* /usr/lib/nagios/plugins/

Start Shinken

Configure Shinken to automatically start when the system boots.

ln -s /etc/init.d/shinken-scheduler /etc/rcS.d/S98shinken-scheduler
ln -s /etc/init.d/shinken-poller /etc/rcS.d/S98shinken-poller
ln -s /etc/init.d/shinken-reactionner /etc/rcS.d/S98shinken-reactionner
ln -s /etc/init.d/shinken-broker /etc/rcS.d/S98shinken-broker
ln -s /etc/init.d/shinken-arbiter /etc/rcS.d/S98shinken-arbiter

Verify the sample Shinken configuration files.

/usr/bin/shinken-arbiter -v -c /etc/shinken/nagios.cfg -c /etc/shinken/shinken-specific.cfg

If there are no errors, start Shinken.

/etc/init.d/shinken-scheduler start
/etc/init.d/shinken-poller start
/etc/init.d/shinken-broker start
/etc/init.d/shinken-reactionner start
/etc/init.d/shinken-arbiter start