PDA

View Full Version : Probleme demarrage nagios


gangan
07-27-2007, 11:28 PM
bonsoir a tous,

alors voila j'ai un ptit soucis :

/usr/local/nagios/bin/nagios –v

Nagios 2.9
Copyright (c) 1999-2007 Ethan Galstad (http://www.nagios.org)
Last Modified: 04-10-2007
License: GPL

Error: Cannot open main configuration file '/usr/local/nagios/etc/–v' for reading!
Nagios 2.9 starting... (PID=10103)
Bailing out due to one or more errors encountered in the configuration files. Run Nagios from the command line with the -v option to verify your config before restarting. (PID=10103)

meme chose dans nagios.log (je croyais qu'il allait me parler plus bin non :( )

les fichiers de dans /usr/local/nagios/var on les droits suivant :

-rwxrwxrwx 1 www-data nagios

pareil pour les fichiers qui se trouvent dans etc

chui dans le brouillard :(

une ame charitable pour m'aider ??

en tout cas bonne soirée a vous et bon week end

claneys
07-30-2007, 11:55 AM
la commande s'écrit comme suit :

nagios -v <main_config_file>


Comme tu le devines <main_config_file> désigne le fichier nagios.cfg dans ton dossier etc.

Mais je trouve étonnant qu'il veuille lire un fichier "-v" Oo il prend pas -v en tant qu'argument mais en tant que fichier de config. J'ai la même version de nagios que toi et la commande incomplète nagios -v sans indiquer le fichier de conf ne me donne pas du tout cette sortie là.

Essaye en indiquant le fichier de conf et dis nous le résultat

gangan
08-07-2007, 12:54 PM
bon je reprend :) voici mon probleme :s

11:54:38 root@portix:/usr/local/nagios/etc 37$ /usr/local/nagios/bin/nagios -v nagios.cfg

Nagios 2.9
Copyright (c) 1999-2007 Ethan Galstad (http://www.nagios.org)
Last Modified: 04-10-2007
License: GPL

Reading configuration data...

Error: Timeperiod '24x7' has already been defined
Error: Could not register timeperiod (config file '/usr/local/nagios/etc/timeperiods.cfg', starting on line 20)

***> One or more problems was encountered while processing the config files...

gangan
08-07-2007, 12:55 PM
j'ai que ca dans mon fichier timeperiod.cfg

define timeperiod{
timeperiod_name 24x7
alias 24_Hours_A_Day,_7_Days_A_Week
sunday 00:00-24:00
monday 00:00-24:00
tuesday 00:00-24:00
wednesday 00:00-24:00
thursday 00:00-24:00
friday 00:00-24:00
saturday 00:00-24:00

gangan
08-20-2007, 12:08 PM
j'ai avancé un peu j'ai mis un # devant le localhost.cfg dans nagios.cfg
et maintenant j'ai cette erreur en faisant :

/usr/local/nagios/bin/nagios -v nagios.cfg

Reading configuration data...

Running pre-flight check on configuration data...

Checking services...
Error: Service check command 'check-server-alive' specified in service 'Ping' for host 'maliaisonamoi' not defined anywhere!
Error: Service check command 'check-server-alive' specified in service 'Ping' for host 'zalix' not defined anywhere!