moba에서 nat키고
ssh -i .ssh/id_rsa root@nms.bonghyeon2.shop
nat 탭 복제 하고
ssh -i .ssh/id_rsa root@ns.bonghyeon2.shop
mysql -u root -p mysql < /usr/share/mysql/mysql_test_data_timezone.sql # 뭔말이지?
mysql -u root -p
GRANT SELECT ON mysql.time_zone_name TO cactiuser@'%';
flush privileges;
exit
vi /etc/my.cnf.d/server.cnf
[mysqld]
character-set-client-handshake=FALSE
character-set-server=utf8mb4
collation-server=utf8mb4_unicode_ci
max_heap_table_size=128M
max_allowed_packet=16777216
tmp_table_size=78M
join_buffer_size=155M
innodb_file_per_table=on
innodb_buffer_pool_size=1207M
innodb_doublewrite=on
#innodb_additional_mem_pool_size=80M
innodb_file_format=Barracuda
innodb_lock_wait_timeout=50
innodb_flush_log_at_trx_commit=2
innodb_large_prefix=1
systemctl restart mariadb.service
yum -y install cacti
mysqldump -u root -p wordpress > wordpress.sql # wordpress sql 내보내기
rpm -qa | grep MariaDB
yum autoremove -y MariaDB
systemctl status mariadb
yum install -y mariadb-server
systemctl enable --now mariadb
mysql -h ns.bonghyeon2.shop -u cactiuser -p cacti < /usr/share/doc/cacti-*/cacti.sql # cacti sql을 우리가 만든 cacti db에 주입
vi /usr/share/cacti/include/config.php
$database_password = 'Kosa0220!';
vi /etc/cron.d/cacti
*/5 * * * * apache /usr/bin/php /usr/share/cacti/poller.php > /dev/null 2>&1 # "/5" : 5분마다라는뜻 5뒤에 별 순서대로 (연도, 월, 일수, 요일)
vi /etc/httpd/conf.d/cacti.conf
Require host localhost --> Require all granted
Allow from localhost --> Allow from all
vi /etc/php.ini
date.timezone = Asia/Seoul
memory_limit = 800M
max_execution_time = 60
systemctl restart httpd.service
systemctl restart mariadb.service
systemctl restart snmpd.service
firewall-cmd --permanent --add-service=http
firewall-cmd --reload
reboot
vi /etc/haproxy/haproxy.cfg
safari 추가
systemctl restart haproxy
systemctl status haproxy # active 부분 확인