<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<atom:link href="https://www.gentoo-zh.org/extern.php?action=feed&amp;tid=603&amp;type=rss" rel="self" type="application/rss+xml" />
		<title><![CDATA[Gentoo中文社区 / centos6 nginx]]></title>
		<link>https://www.gentoo-zh.org/viewtopic.php?id=603</link>
		<description><![CDATA[centos6 nginx 最近发表的帖子。]]></description>
		<lastBuildDate>Wed, 07 Dec 2022 06:06:01 +0000</lastBuildDate>
		<generator>FluxBB</generator>
		<item>
			<title><![CDATA[centos6 nginx]]></title>
			<link>https://www.gentoo-zh.org/viewtopic.php?pid=644#p644</link>
			<description><![CDATA[<p>#!/bin/bash<br /># nginx Startup script for the Nginx HTTP Server<br /># it is v.0.0.2 version.<br /># chkconfig: - 85 15<br /># description: Nginx is a high-performance web and proxy server.<br />#&#160; &#160; &#160; &#160; &#160; &#160; &#160; It has a lot of features, but it&#039;s not for everyone.<br /># processname: nginx<br /># pidfile: /var/run/nginx.pid<br /># config: /usr/local/nginx/conf/nginx.conf<br />nginxd=/usr/local/nginx/sbin/nginx<br />nginx_config=/usr/local/nginx/conf/nginx.conf<br />nginx_pid=/var/run/nginx.pid<br />RETVAL=0<br />prog=&quot;nginx&quot;<br /># Source function library.<br />. /etc/rc.d/init.d/functions<br /># Source networking configuration.<br />. /etc/sysconfig/network<br /># Check that networking is up.<br />[ ${NETWORKING} = &quot;no&quot; ] &amp;&amp; exit 0<br />[ -x $nginxd ] || exit 0<br /># Start nginx daemons functions.<br />start() {<br />if [ -e $nginx_pid ];then<br />&#160; &#160;echo &quot;nginx already running....&quot;<br />&#160; &#160;exit 1<br />fi<br />&#160; &#160;echo -n $&quot;Starting $prog: &quot;<br />&#160; &#160;daemon $nginxd -c ${nginx_config}<br />&#160; &#160;RETVAL=$?<br />&#160; &#160;echo<br />&#160; &#160;[ $RETVAL = 0 ] &amp;&amp; touch /var/lock/subsys/nginx<br />&#160; &#160;return $RETVAL<br />}<br /># Stop nginx daemons functions.<br />stop() {<br />&#160; &#160; &#160; &#160; echo -n $&quot;Stopping $prog: &quot;<br />&#160; &#160; &#160; &#160; killproc $nginxd<br />&#160; &#160; &#160; &#160; RETVAL=$?<br />&#160; &#160; &#160; &#160; echo<br />&#160; &#160; &#160; &#160; [ $RETVAL = 0 ] &amp;&amp; rm -f /var/lock/subsys/nginx /var/run/nginx.pid<br />}<br /># reload nginx service functions.<br />reload() {<br />&#160; &#160; echo -n $&quot;Reloading $prog: &quot;<br />&#160; &#160; #kill -HUP `cat ${nginx_pid}`<br />&#160; &#160; killproc $nginxd -HUP<br />&#160; &#160; RETVAL=$?<br />&#160; &#160; echo<br />}<br /># See how we were called.<br />case &quot;$1&quot; in<br />start)<br />&#160; &#160; &#160; &#160; start<br />&#160; &#160; &#160; &#160; ;;<br />stop)<br />&#160; &#160; &#160; &#160; stop<br />&#160; &#160; &#160; &#160; ;;<br />reload)<br />&#160; &#160; &#160; &#160; reload<br />&#160; &#160; &#160; &#160; ;;<br />restart)<br />&#160; &#160; &#160; &#160; stop<br />&#160; &#160; &#160; &#160; start<br />&#160; &#160; &#160; &#160; ;;<br />status)<br />&#160; &#160; &#160; &#160; status $prog<br />&#160; &#160; &#160; &#160; RETVAL=$?<br />&#160; &#160; &#160; &#160; ;;<br />*)<br />&#160; &#160; &#160; &#160; echo $&quot;Usage: $prog {start|stop|restart|reload|status|help}&quot;<br />&#160; &#160; &#160; &#160; exit 1<br />esac<br />exit $RETVAL</p>]]></description>
			<author><![CDATA[dummy@example.com (batsom)]]></author>
			<pubDate>Wed, 07 Dec 2022 06:06:01 +0000</pubDate>
			<guid>https://www.gentoo-zh.org/viewtopic.php?pid=644#p644</guid>
		</item>
	</channel>
</rss>
