FreeBSd > Soft

Nagios + Nconf

(1/5) > >>

srdemon:
Всем пиривэт, камрадэс!
Наткнулся вот на эту статейку о настройке nagios и nconf. *Автору большущее спасибо за подробное изложение материала*
Решил воспользоваться руководством, но столкнулся с проблемой.
При исполнении скрипта выгрузки конфигов из nconf (выполняю скрипт /usr/local/www/nconf/ADD-ONS/deploy_local.sh вручную) ругается - /usr/local/www/nconf/ADD-ONS/deploy_local.sh: Permission denied.  :-\

понимаю, что что-то не так с правами. но где и как выяснить, на что именно нет прав?
какие логи посмотреть, например?

понимаю, что по фотографии не лечится и экстрасенсов тут нет. Подскажите, какие листинги выложить, охотно поделюсь.
Спасибо за внимание.

muff:
От какого пользователя запускаешь скрипт? Если от рута - тогда не должно быть никаких проблем вообще. Если от своего аккаунта - дай права на запуск скрипта.
Проверить текущие разрешения можно командой:

--- Код: ---# ls -la /usr/local/www/nconf/ADD-ONS/
--- Конец кода ---

master:
Здравствуйте. Писал в комменты, но повторю тут:

Начал устанавливать по вашей статье.
Дошел до Generate Nagios config и получаю
 
--- Цитировать ---Error accessing or executing Nagios / Icinga binary '/usr/local/www/nconf/bin/nagios'.
 Cannot run the mandatory syntax check.
--- Конец цитаты ---


--- Цитировать --- /usr/local/www/nconf/bin/
--- Конец цитаты ---
nagios пустая.

 И при запуске nagios

--- Цитировать ---# /usr/local/etc/rc.d/nagios start
 Performing sanity check of nagios configuration: FAILED

 Nagios Core 3.2.3
 Copyright (c) 2009-2010 Nagios Core Development Team and Community Contributors
 Copyright (c) 1999-2009 Ethan Galstad
 Last Modified: 10-03-2010
 License: GPL

 Website: hттp:ww.nagios.org
 Reading configuration data...
 Read main config file okay...
 Processing object config directory '/usr/local/etc/nagios/global'...
 Processing object config directory '/usr/local/etc/nagios/Default_collector'...
 Read object config files okay...

 Running pre-flight check on configuration data...

 Checking services...
 Error: There are no services defined!
 Checked 0 services.
 Checking hosts...
 Error: There are no hosts defined!
 Checked 0 hosts.
 Checking host groups...
 Checked 0 host groups.
 Checking service groups...
 Checked 0 service groups.
 Checking contacts...
 Error: There are no contacts defined!
 Checked 0 contacts.
 Checking contact groups...
 Checked 0 contact groups.
 Checking service escalations...
 Checked 0 service escalations.
 Checking service dependencies...
 Checked 0 service dependencies.
 Checking host escalations...
 Checked 0 host escalations.
 Checking host dependencies...
 Checked 0 host dependencies.
 Checking commands...
 Checked 0 commands.
 Checking time periods...
 Checked 0 time periods.
 Checking for circular paths between hosts...
 Checking for circular host and service dependencies...
 Checking global event handlers...
 Checking obsessive compulsive processor commands...
 Checking misc settings...

 Total Warnings: 0
 Total Errors: 3

 ***> One or more problems was encountered while running the pre-flight check...

 Check your configuration file(s) to ensure that they contain valid
 directives and data defintions. If you are upgrading from a previous
 version of Nagios, you should be aware that some variables/definitions
 may have been removed or modified in this version. Make sure to read
 the HTML documentation regarding the config files, as well as the
 'Whats New' section to find out what has changed.

 /usr/local/etc/rc.d/nagios: WARNING: failed precmd routine for nagios
--- Конец цитаты ---

Прошу совета..

muff:
Попробуйте удалить каталог nconf, закачать по новому архив и повторно распаковать его, выполнив дальнейшие инструкции.

В моем случае в каталоге /usr/local/www/nconf/bin находятся такие файлы:

--- Код: ---# ls /usr/local/www/nconf/bin/
add_items_from_cfg.pl*         add_items_from_special_csv.pl* lib/                           parse_config_EXAMPLE.pl*
add_items_from_csv.pl*         generate_config.pl*            link_missing_items.pl*
--- Конец кода ---
А в каталоге /usr/local/www/nconf такие:

--- Код: ---# ls /usr/local/www/nconf/
ADD-ONS/                       clone_host_write2db.php        design_templates/              modify_attr.php                overview.php
CHANGELOG                      clone_service.php              detail.php                     modify_attr_write2db.php       show_attr.php
COPYRIGHT                      clone_service_write2db.php     detail_attributes.php          modify_class.php               show_class.php
LICENSE                        config.orig/                   detail_class.php               modify_class_write2db.php      static_cfg/
README                         config/                        generate_config.php            modify_item.php                static_file_editor.php
add_item.php                   delete_attr.php                history.php                    modify_item_service.php        temp/
add_item_step2.php             delete_class.php               id_wrapper.php                 modify_item_write2db.php
bin/                           delete_item.php                img/                           multimodify_attr.php
call_ajax.php                  dependency.php                 include/                       multimodify_attr_write2db.php
clone_host.php                 deploy_config.php              index.php                      output/
--- Конец кода ---


Получается, проблема именно с Nconf. А Nagios не запускается потому, что корректные файлы конфигурации для него не созданы.

master:
Сделал..
То же и осталось.
Жму "Generate Nagios config" и получаю:
Error accessing or executing Nagios / Icinga binary '/usr/local/www/nconf/bin/nagios'.
Cannot run the mandatory syntax check.

cd /usr/local/www/nconf/bin/
monitor# ls
add_items_from_cfg.pl           lib
add_items_from_csv.pl           link_missing_items.pl
add_items_from_special_csv.pl   parse_config_EXAMPLE.pl
generate_config.pl

Навигация

[0] Главная страница сообщений

[#] Следующая страница

Перейти к полной версии