資源描述:
《linux下cacti安裝與配置》由會員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在應(yīng)用文檔-天天文庫。
1、Linux下Cacti安裝與配置原文鏈接:http://www.linuxidc.com/Linux/2011-11/46712.htm這個是linux下安裝配置Nagios和Cacti的第一個步驟,即配置一個web的環(huán)境,這里采用的是lamp的架構(gòu)!這里采用的linux平臺是RHEL5.4的版本首先是mysql的編譯安裝(GCC和MAKE都要安裝上,其他的套件按需安裝)免費(fèi)下載地址在http://linux.linuxidc.com/用戶名與密碼都是www.linuxidc.com[root@localhos
2、thttpd]#useraddmysql[root@localhost~]#llmysql-5.1.59.tar.gz-rw-r--r--1rootroot24325443Oct1422:38mysql-5.1.59.tar.gz[root@localhost~]#tarzxvfmysql-5.1.59.tar.gz[root@localhostmysql-5.1.59]#./configure--prefix=/usr/local/mysql--enable-local-infile--with-charse
3、t=gbk--with-extra-charsets=all--with-low-memory--with-mysqld-user=mysql--enable-thread-safe-client[root@localhostmysql-5.1.59]#make&&makeinstall[root@localhostmysql-5.1.59]#cd/usr/local/mysql/[root@localhostmysql]#chown-Rmysql.mysql.[root@localhostmysql]#./b
4、in/mysql_install_db--user=mysql[root@localhostmysql]#chown-Rroot.[root@localhostmysql]#chown-Rmysql/var/[root@localhostmysql]#./bin/mysqld_safe--user=mysql&[root@localhostmysql]#netstat-tulnp
5、grep3306tcp000.0.0.0:33060.0.0.0:*LISTEN20438/mysqld[root@localhos
6、tmysql]#cd~(這部分是制作mysql的開機(jī)啟動項)[root@localhost~]#echo"/usr/local/mysql/lib/mysql">>/etc/ld.so.conf[root@localhost~]#ldconfig-v[root@localhost~]#ln-s/usr/local/mysql/bin/mysql/usr/local/bin/mysql[root@localhost~]#cpmysql-5.1.59/support-files/mysql.server/etc/i
7、nit.d/mysqld[root@localhost~]#chmod775/etc/init.d/mysqld[root@localhost~]#cpmysql-5.1.59/support-files/my-medium.cnf/etc/my-cnf[root@localhost~]#chkconfig--addmysqld[root@localhost~]#chkconfigmysqldon[root@localhost~]#chkconfig--list
8、grepmysqldmysqld0:off1:o
9、ff2:on3:on4:on5:on6:of接著是apache的編譯安裝[root@localhost~]#llhttpd-2.2.6.tar.gz-rw-r--r--1rootroot6028951Sep62007httpd-2.2.6.tar.gz[root@localhost~]#tarzxvfhttpd-2.2.6.tar.gz[root@localhost~]#cdhttpd-2.2.6[root@localhosthttpd-2.2.6]#./configure--prefix=/usr/local
10、/httpd--enable-so--enable-rewrite--enable-ssl--with-ssl=/usr/local/openssl--with-zlib--enable-mods-shared=all--enable-track-vars--with-mysql=/usr/local/mysql[root@localhosthttpd-2.2.6]#make&&mak