ZABBIX - インストール/設定2011/05/22 |
[1] | ZABBIX インストール |
[root@master ~]#
yum --enablerepo=epel -y install zabbix-server-mysql zabbix-agent zabbix-web-mysql # EPELからインストール # ZABBIX データベース作成 [root@master ~]# mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3 Server version: 5.1.52 Source distribution
Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved.
This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL v2 license
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql>
create database zabbix; Query OK, 1 row affected (0.00 sec)
mysql>
grant all privileges on zabbix.* to zabbix@localhost identified by 'password'; Query OK, 0 rows affected (0.00 sec)
mysql>
flush privileges; Query OK, 0 rows affected (0.00 sec)
mysql>
[root@master ~]# exit Bye cd /usr/share/doc/zabbix-server-mysql-*/create/schema [root@master schema]# cat mysql.sql | mysql -u root -p zabbix Enter password: # MySQL rootパスワード [root@master schema]# cd ../data [root@master data]# cat data.sql | mysql -u root -p zabbix Enter password: [root@master data]# cat images_mysql.sql | mysql -u root -p zabbix Enter password: [root@master data]#
[root@master ~]#
vi /etc/zabbix/zabbix_server.conf # 110行目:コメント解除し Zabbix DB のパスワード追記 DBPassword= password
[root@master ~]#
vi /etc/zabbix/zabbix_agentd.conf # 91行目:自身のホスト名に変更 Hostname= master.srv.world
[root@master ~]#
vi /etc/php.ini # 440行目:Zabbix推奨値に変更 max_execution_time = 600
# 449行目:Zabbix推奨値に変更 max_input_time = 600
# 457行目:Zabbix推奨値に変更 memory_limit = 256M
# 729行目:Zabbix推奨値に変更 post_max_size = 32M
# 878行目:Zabbix推奨値に変更 upload_max_filesize = 16M
# 946行目:コメント解除しタイムゾーン追記 date.timezone = Asia/Tokyo
[root@master ~]#
vi /etc/httpd/conf.d/zabbix.conf
Alias /zabbix /usr/share/zabbix
<Directory "/usr/share/zabbix">
[root@master ~]# Options FollowSymLinks AllowOverride None Order allow,deny Allow from 10.0.0.0/24 # アクセス許可範囲に変更 </Directory> /etc/rc.d/init.d/zabbix-server start Starting ZABBIX server: [ OK ] [root@master ~]# /etc/rc.d/init.d/zabbix-agent start Starting ZABBIX agent: [ OK ] [root@master ~]# /etc/rc.d/init.d/httpd restart Stopping httpd: [ OK ] Starting httpd: [ OK ] [root@master ~]# chkconfig zabbix-server on [root@master ~]# chkconfig zabbix-agent on |
Sponsored Link |
|