首页 > 其他 > 详细

Redhat安装icinga2

时间:2015-12-30 20:02:29      阅读:386      评论:0      收藏:0      [点我收藏+]

Redhat安装icinga2

 

所需rpm包下载网址:http://packages.icinga.org/epel/

http://mirrors.hypo.cn/icinga/fedora/21/release/noarch  icingaweb2包)

 

php-intlphp-pecl-imagick需要单独下

 

 

需要的包:libboost_system1libboost_thread1libboost_regex1libeditboost-licenseicinga2icinga2-binicinga2-commonicingaweb2icingaweb2-commonicingaweb2-vendor-*6个)、php-icingaicingacli

 

安装httpd

# yuminstall httpd

# yuminstall php php-gd

 

 

# rpm –ilibboost* boost-license (需先下载好)

# rpm –iicinga2*       (需先下载好)

 

# cp –rv/etc/icinga2/icinga2.conf /etc/httpd/conf.d/

# cp –rv/etc/icinga2/constants.conf /etc/httpd/

# cp –rv/etc/icinga2/zones.conf /etc/httpd/

 

安装mysql

# yuminstall mysql-server

 

# mysql–u root  

  • use mysql;

  • update user set password=password(’xxxx’) where user=’root’;

  • flush privileges;

  • quit

 

# mysql –uroot –p’xxxx’

  • create database icinga2;

  • grant all on icinga2.* to icinga2@localhost identified by ‘xxxxxx’;

  • flush privileges;

  • quit

 

# mysql –uroot –p’xxxx’  icinga2 </usr/share/icinga2-ido-mysql/schema/mysql.sql

 

 

# rpm –iicingaweb2-*

 

#service httpd restart

 

页面访问:http://ip/icingaweb2

 

暂时还不能登录,点击账号上面的web-basedsetup-wizard

 

然后照着提示在命令行里操作:

 

#icingacli setup config directory --group icingaweb2

#icingacli setup token create

# su -c"mkdir -m 2770 /etc/icingaweb2;chgrp icingaweb2 /etc/icingaweb2;head -c 12/dev/urandom | base64 | tee /etc/icingaweb2/setup.token;chmod 0660/etc/icingaweb2/setup.token;"

 

然后将乱码贴到页面上

 

模块部分全勾,然后会提示the phpconfig ‘date.timezone‘ is not defined

 

# vi/etc/php5/apache2/php.ini

 

date.timezone= Asia/Shanghai   (默认是注释掉的)

 

:wq

#service apache2 restart

 

再点击refresh即可(其它黄色提示可忽略)——Database——将数据库、用户名等补上,勾上Skip Validation——设置管理账号及密码

 

 

 


本文出自 “linux” 博客,请务必保留此出处http://yangzhiming.blog.51cto.com/4849999/1729991

Redhat安装icinga2

原文:http://yangzhiming.blog.51cto.com/4849999/1729991

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!