<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>http://jackxiang.com/index.php</link> 
<description><![CDATA[赢在IT，Playin' with IT,Focus on Killer Application,Marketing Meets Technology.]]></description> 
<language>zh-cn</language> 
<copyright><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></copyright>
<item>
<link>http://jackxiang.com/post//</link>
<title><![CDATA[[实践OK]Linux下将脚本添加到 /etc/rc.d/rc.local 中开机启动，相当地windows下的启动项。]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[Unix/LinuxC技术]]></category>
<pubDate>Fri, 29 Aug 2014 07:30:02 +0000</pubDate> 
<guid>http://jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	这个相当于windows里的启动项<br/>vi&nbsp;&nbsp;/etc/rc.d/rc.local<br/>按i<br/>然后把你的命令贴进去 ，一行一条命令<br/>/bin/bash /usr/local/scripts/autoStartNginxEnterSSLKey.sh<br/>然后按 esc<br/>再 :wq 保存&nbsp;&nbsp;注意前面有两点的冒号<br/>下次重启的时候这个就会自动执行你添加的命令。<br/><textarea name="code" class="php" rows="15" cols="100">
cat&nbsp;&nbsp;/etc/rc.local

[root@localhost config]# cat&nbsp;&nbsp;/etc/rc.local
#!/bin/sh
#
# This script will be executed *after* all the other init scripts.
# You can put your own initialization stuff in here if you don&#039;t
# want to do the full Sys V style init stuff.

touch /var/lock/subsys/local

route add -net 192.168.0.0 netmask 255.255.0.0 gw 10.70.39.254
route add -net 10.0.0.0 netmask 255.0.0.0 gw 10.70.39.254

ulimit -SHn 51200

/bin/sh /usr/local/mysql/bin/mysqld_safe --defaults-file=/etc/my.cnf &amp;

/sbin/service php-fpm restart

/usr/local/nginx/sbin/nginx
</textarea><br/><br/><br/>vi /usr/local/scripts/autoStartNginxEnterSSLKey.sh<br/><textarea name="code" class="php" rows="15" cols="100">
#!/bin/bash 
pkill -9 nginx
expect&lt;&lt;- END
spawn /usr/local/scripts/startNginx.sh
expect &quot;*Enter PEM pass phrase:&quot;
send &quot;jackxiang*&#92;r&quot;
send &quot;jackxiang*&#92;r&quot;
expect eof 
exit 
END&nbsp;&nbsp;
</textarea><br/><br/>./startNginx.sh<br/>cat ./startNginx.sh<br/>/usr/local/nginx/sbin/nginx<br/><br/>来自：http://zhidao.baidu.com/link?url=D7tZLZFqg7LODR60qIkvAeoSk-ocjBWgLppmxkHh_gSxH3AvOkZ_S9SxTj-C50espCswUiYZRK9F4JYi2nVC8K
]]>
</description>
</item><item>
<link>http://jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [实践OK]Linux下将脚本添加到 /etc/rc.d/rc.local 中开机启动，相当地windows下的启动项。]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>http://jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>