欧美一区二区三区老妇人-欧美做爰猛烈大尺度电-99久久夜色精品国产亚洲a-亚洲福利视频一区二区

安裝Tengine

建站服務(wù)器 1.安裝VMware

創(chuàng)新互聯(lián)建站服務(wù)項目包括延慶網(wǎng)站建設(shè)、延慶網(wǎng)站制作、延慶網(wǎng)頁制作以及延慶網(wǎng)絡(luò)營銷策劃等。多年來,我們專注于互聯(lián)網(wǎng)行業(yè),利用自身積累的技術(shù)優(yōu)勢、行業(yè)經(jīng)驗、深度合作伙伴關(guān)系等,向廣大中小型企業(yè)、政府機構(gòu)等提供互聯(lián)網(wǎng)行業(yè)的解決方案,延慶網(wǎng)站推廣取得了明顯的社會效益與經(jīng)濟效益。目前,我們服務(wù)的客戶以成都為中心已經(jīng)輻射到延慶省份的部分城市,未來相信會繼續(xù)擴大服務(wù)區(qū)域并繼續(xù)獲得客戶的支持與信任!2.安裝CentOS6.5

3.配置網(wǎng)絡(luò)
a.修改/etc/sysconfig/network-scripts/ifcfg-eth0配置文件,添加如下內(nèi)容
DEVICE=eth0
HWADDR=00:0C:29:96:01:6B
TYPE=Ethernet
UUID=41cbd943-024b-4341-ac7a-e4d2142b4938
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=none
IPADDR=xxx.xxx.x.xxx
#例如:IPADDR=192.168.2.140
NETMASK=255.255.255.0
GATEWAY=192.168.2.2

b.修改/etc/resolv.conf配置文件,添加如下內(nèi)容
nameserver192.168.2.2

c.servicenetworkrestart

d.ifconfig

e.pingwww.baidu.com
如果能拼通表示可以連接外部網(wǎng)絡(luò)

4.修改yum源為Aliyun yum源
a.備份原有的源
mv/etc/yum.repos.d/CentOS-Base.repo/etc/yum.repos.d/CentOS-Base.repo.backup

b.下載新的CentOS-Base.repo到/etc/yum.repos.d/這個目錄下
CentOS5
wget-O/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-5.repo
或者
curl-o/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-5.repo
	
CentOS6
wget-O/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-6.repo
或者
curl-o/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-6.repo

CentOS7
wget-O/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-7.repo
或者
curl-o/etc/yum.repos.d/CentOS-Base.repohttp://mirrors.aliyun.com/repo/Centos-7.repo

c.運行yummakecache命令生成緩存

5.安裝編譯環(huán)境
yum-yinstallgccopenssl-develpcre-develzlib-devel

6.安裝Tengine
a.下載或上傳tengine-2.1.0.tar.gz到/opt下
ls/opt
cd/opt
b.解壓
tar-zxvftengine-2.1.1.tar.gz
ls
cdtengine-2.1.0
ls
c.檢查依賴
./configure\\
--prefix=/opt/sxt/soft/tengine-2.1.0/\\
--error-log-path=/var/log/nginx/error.log\\
--http-log-path=/var/log/nginx/access.log\\
--pid-path=/var/run/nginx/nginx.pid\\
--lock-path=/var/lock/nginx.lock\\
--with-http_ssl_module\\
--with-http_flv_module\\
--with-http_stub_status_module\\
--with-http_gzip_static_module\\
--http-client-body-temp-path=/var/tmp/nginx/client/\\
--http-proxy-temp-path=/var/tmp/nginx/proxy/\\
--http-fastcgi-temp-path=/var/tmp/nginx/fcgi/\\
--http-uwsgi-temp-path=/var/tmp/nginx/uwsgi\\
--http-scgi-temp-path=/var/tmp/nginx/scgi\\
--with-pcre
d.編譯并安裝
make&&makeinstall

7.安裝添加到啟動文件
a.在/etc/init.d下面建立nginx文件,內(nèi)容如下
		#!/bin/bash
		#
		#chkconfig:-8515
		#description:nginxisaWorldWideWebserver.Itisusedtoserve
		#Sourcefunctionlibrary.
		./etc/rc.d/init.d/functions
		
		#Sourcenetworkingconfiguration.
		./etc/sysconfig/network
		
		#Checkthatnetworkingisup.
		["$NETWORKING"="no"]&&exit0
		
		nginx="/usr/tengine-2.1/sbin/nginx"
		prog=$(basename$nginx)
		
		NGINX_CONF_FILE="/usr/tengine-2.1/conf/nginx.conf"
		
		#[-f/etc/sysconfig/nginx]&&./etc/sysconfig/nginx
		
		lockfile=/var/lock/subsys/nginx
		
		#make_dirs(){
		##makerequireddirectories
		#user=`nginx-V2>&1|grep"configurearguments:"|sed's/[^*]*--user=\\([^]*\\).*/\\1/g'-`
		#options=`$nginx-V2>&1|grep'configurearguments:'`
		#foroptin$options;do
		#if[`echo$opt|grep'.*-temp-path'`];then
		#value=`echo$opt|cut-d"="-f2`
		#if[!-d"$value"];then
		##echo"creating"$value
		#mkdir-p$value&&chown-R$user$value
		#fi
		#fi
		#done
		#}
		
		start(){
		[-x$nginx]||exit5
		[-f$NGINX_CONF_FILE]||exit6
		#make_dirs
		echo-n$"Starting$prog:"
		daemon$nginx-c$NGINX_CONF_FILE
		retval=$?
		echo
		[$retval-eq0]&&touch$lockfile
		return$retval
		}
		
		stop(){
		echo-n$"Stopping$prog:"
		killproc$prog-QUIT
		retval=$?
		echo
		[$retval-eq0]&&rm-f$lockfile
		return$retval
		}
		
		restart(){
		configtest||return$?
		stop
		sleep1
		start
		}
		
		reload(){
		configtest||return$?
		echo-n$"Reloading$prog:"
		#-HUP是nginx平滑重啟參數(shù)
		killproc$nginx-HUP
		RETVAL=$?
		echo
		}
		
		force_reload(){
		restart
		}
		
		configtest(){
		$nginx-t-c$NGINX_CONF_FILE
		}
		
		rh_status(){
		status$prog
		}
		
		rh_status_q(){
		rh_status>/dev/null2>&1
		}
		
		case"$1"in
		start)
		rh_status_q&&exit0
		$1
		;;
		stop)
		rh_status_q||exit0
		$1
		;;
		restart|configtest)
		$1
		;;
		reload)
		rh_status_q||exit7
		$1
		;;
		force-reload)
		force_reload
		;;
		status)
		rh_status
		;;
		condrestart|try-restart)
		rh_status_q||exit0
		;;
		*)
		echo$"Usage:$0{start|stop|status|restart|condrestart|try-restart|reload|force-reload|configtest}"
		exit2
		esac

b.修改nginx配置文件
	將nginx="/usr/tengine-2.1/sbin/nginx"修改為nginx="/opt/sxt/soft/tengine-2.1.0/sbin/nginx"
	將NGINX_CONF_FILE="/usr/tengine-2.1/conf/nginx.conf"修改為NGINX_CONF_FILE="/opt/sxt/soft/tengine-2.1.0/conf/nginx.conf"
	保存退出:wq
c.給nginx添加執(zhí)行權(quán)限
	chmod755nginx
d.啟動服務(wù)
	servicenginxstart
e.在d步時會報錯,需要手動創(chuàng)建/var/tmp/nginx/client/這個目錄
	mkdir-p/var/tmp/nginx/client/

	servicenginxstart
f.關(guān)閉防火墻
	serviceiptablesstop

8.在瀏覽器中訪問tengine
http://192.168.2.140/

文章名稱:安裝Tengine
新聞來源:http://chinadenli.net/article0/cjegio.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供網(wǎng)站營銷虛擬主機網(wǎng)站收錄品牌網(wǎng)站建設(shè)云服務(wù)器外貿(mào)建站

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

成都app開發(fā)公司