Zibbix下载地址:
http://sourceforge.net/projects/zabbix/files/ZABBIX%20Latest%20Stable/2.4.5/zabbix-2.4.5.tar.gz/download
一、设置静态IP
# vi /etc/sysconfig/network-scripts/ifcfg-eth0
# vi/etc/resolv.conf
# servicenetwork restart
二、改服务器主机名和网关
设置主机名
约定:主机名命名规范:业务.机房.主备.域名
这里设置主机名为:bbs.hz.m.osyunwei.com
1、hostname “bbs.hz.m.osyunwei.com”
#设置主机名为bbs.hz.m.osyunwei.com
2、vi/etc/sysconfig/network #编辑配置文件
HOSTNAME=bbs.hz.m.osyunwei.com
#修改localhost.localdomain为bbs.hz.m.osyunwei.com
wq! #保存退出
3、vi /etc/hosts #编辑配置文件
127.0.0.1 bbs.hz.m.osyunwei.com localhost
#修改localhost.localdomain为bbs.hz.m.osyunwei.com
:wq! #保存退出
shutdown -rnow #重启系统
三、安装wget工具
#yum installwget
四、换源
#cd/etc/yum.repos.d/
#wget http://mirrors.163.com/.help/CentOS6-Base-163.repo
#mvCentOS6-Base-163.repo CentOS-Base.repo
#yum cleanall
#yummakecache
五、安装NGINX
# mkdir/usr/local/src/software
# mkdir/usr/local/src/tarbag
# cd tarbag
#wget http://www.nginx.org/download/nginx-1.9.0.tar.gz
#wget http://labs.frickle.com/files/ngx_cache_purge-1.3.tar.gz
#wget http://labs.frickle.com/files/ngx_cache_purge-2.3.tar.gz
#cdnginx-1.9.0/
./configure
--prefix=/usr/local/nginx-1.0.6\
--with-http_stub_status_module\
--with-http_ssl_module\
--with-http_realip_module\
--add-module=../ngx_cache_purge-2.3
#make install
启动、关闭、重置nginx
启动:直接执行以下命令,nginx 就启动了,不需要改任何配置文件,nginx 配置多域名虚拟主机请参考后续文章.
/usr/local/nginx-1.0.6/sbin/nginx
试试访问:我这边不贴图,直接使用 curl 命令来读取 web 信息
[root@ns conf]# curl -s http://localhost | grepnginx.com
nginx.com.
关闭:
/usr/local/nginx-1.0.6/sbin/nginx -s stop
重置:当你有修改配置文件的时候,只需要 reload 以下即可
/usr/local/nginx-1.0.6/sbin/nginx -s reload
整个 nginx 的安装就到这里结束了。
六、安装PHP 和NGINX 配置
#cd/usr/local/src/tarbag
#下载PHP最新版
#wget http://cn2.php.net/distributions/php-5.6.8.tar.bz2
#安装依赖包
#yum installgcc make gd-devel libjpeg-devel libpng-devel libxml2-devel bzip2-devellibcurl-devel �Cy
#tar -xjfphp-5.5.0.tar.bz2
#cd php-5.5.0
./configure--prefix=/usr/local/php-5.6.8 --with-config-file-path=/usr/local/php-5.6.8/etc--with-bz2 --with-curl --enable-ftp --enable-sockets --disable-ipv6 --with-gd--with-jpeg-dir=/usr/local --with-png-dir=/usr/local--with-freetype-dir=/usr/local --enable-gd-native-ttf--with-iconv-dir=/usr/local --enable-mbstring --enable-calendar --with-gettext--with-libxml-dir=/usr/local --with-zlib --with-pdo-mysql=mysqlnd--with-mysqli=mysqlnd --with-mysql=mysqlnd --enable-dom --enable-xml--enable-fpm --with-libdir=lib64
#make install
#cpphp.ini-production /usr/local/php-5.6.8/etc/php.ini
#cp/usr/local/php-5.6.8/etc/php-fpm.conf.default/usr/local/php-5.6.8/etc/php-fpm.conf
启动php
#/usr/local/php-5.6.8/sbin/php-fpm
检查
#netstat -lnt|grep 9000
#mkdir -p/data/logs/nginx
#mkdir -p/data/site/test.ttlsa.com/
#vi/data/site/test.ttlsa.com/info.php
#cd/usr/local/nginx-1.9.0/
#vinginx.conf
#killall -9nginx
#/usr/local/nginx-1.9.0/sbin/nginx -s stop
#/usr/local/nginx-1.9.0/sbin/nginx
七、安装mysql
1. 安装必要的组件
# yuminstall �Cy autoconf automake imake libxml2-devel expat-devel cmake gcc gcc-c++libaio libaio-devel bzr bison libtool ncurses5-devel
#cd/usr/local/src/tarbag
#wget -c http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.14-linux-glibc2.5-x86_64.tar.gz/from/http://cdn.mysql.com/