<?xml version="1.0" encoding="UTF-8" ?>
<rss version="2.0">
<channel>
<title><![CDATA[向东博客 专注WEB应用 构架之美 --- 构架之美，在于尽态极妍 | 应用之美，在于药到病除]]></title> 
<link>https://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>https://jackxiang.com/post//</link>
<title><![CDATA[[实践OK]清理VPS上eaccelerator_cache的缓存内容及设置]]></title> 
<author>jack &lt;xdy108@126.com&gt;</author>
<category><![CDATA[Php/Js/Shell/Go]]></category>
<pubDate>Tue, 11 Feb 2014 06:42:06 +0000</pubDate> 
<guid>https://jackxiang.com/post//</guid> 
<description>
<![CDATA[ 
	清理VPS上eaccelerator_cache的缓存内容及设置背景：<br/>有时测试机也好线上也好，代码变了，smarty缓存、memcache缓存都删除了，运行代码也是最新的，但就是不变，这时有可能会考虑到删除eaccelerator_cache。<br/><br/>eaccelerator本身有自动清除的功能，具体设置选项如下：eaccelerator.shm_ttl=&quot;600&quot;<br/>当 eAccelerator 获取新脚本的共享内存大小失败时，它将从共享内存中删除所有在最后 &quot;shm_ttl&quot; 秒内无法存取的脚本缓存。默认值为 &quot;0&quot;，即：不从共享内春中删除任何缓存文件。<br/> <br/> 所以，如果上不是设置为0的话，就会自动清除，如果设置了为0，就要手工清除了<br/>手工清除，可以直接目录缓存目录下的子目录，重起下web服务就可以，或是在eaccelerator的面板里清除也可以：<br/>下载 http://code.google.com/p/lcmp/downloads/detail?name=eaccelerator-0.9.6.1.tar.bz2&amp;can=2&amp;q= 解压后，把里面的control.php<br/>复制到网站目录下面<br/>修改php.ini在ea最下面加上<br/>eaccelerator.allowed_admin_path=&quot;/home/wwwroot/&quot;&nbsp;&nbsp;路径要换成你自己的control.php所在目录<br/>reload一下php，就可以直接访问了，默认用户名admin&nbsp;&nbsp;密码：eAccelerator<br/>可以通过control.php修改用户名密码<br/><br/>里面就有清除功能，相当于eAccelerator的一个控制面板。<br/><br/>来自：<br/>http://www.2cto.com/os/201309/243232.html<br/>http://www.002pc.com/master/College/Server/Linux/18809.html<br/><br/>再啰嗦记录下：<br/>eaccelerator本身有自动清除的功能，具体设置选项如下：eaccelerator.shm_ttl=&quot;600&quot;<br/>当 eAccelerator 获取新脚本的共享内存大小失败时，它将从共享内存中删除所有在最后 &quot;shm_ttl&quot; 秒内无法存取的脚本缓存。默认值为 &quot;0&quot;，即：不从共享内春中删除任何缓存文件。<br/><br/>eaccelerator.shm_prune_period=&quot;600&quot;<br/>当 eAccelerator 获取新脚本的共享内存大小失败时，他将试图从共享内存中删除早于&quot;shm_prune_period&quot; 秒的缓存脚本。默认值为 &quot;0&quot;，即：不从共享内春中删除任何缓存文件。<br/><br/>所以，如果上不是设置为0的话，就会自动清除，如果设置了为0，就要手工清除了<br/>手工清除，可以直接目录缓存目录下的子目录，重起下web服务就可以<br/><br/>或是在eaccelerator的面板里清除也可以。<br/><br/>实践如下：<br/>Removed all scripts and data from shared memory and / or disk:<br/>curl -d&quot;clear=Clear cache&quot; http://t43.jackxiang.com/control.php?sec=0 <br/>Removed all expired scripts and data from shared memory and / or disk:<br/>curl -d&quot;clean=Delete expired&quot; http://t43.jackxiang.com/control.php?sec=0 <br/>Delete all &#039;removed&#039; scripts from shared memory:<br/>curl -d&quot;purge=Purge cache&quot; http://t43.jackxiang.com/control.php?sec=0 <br/><br/>if (isset($_POST[&#039;clear&#039;])) eaccelerator_clear();<br/>if (isset($_POST[&#039;clean&#039;])) eaccelerator_clean();<br/>if (isset($_POST[&#039;purge&#039;])) eaccelerator_purge();<br/><br/>在/usr/htdocs/tools.jackxiang.com/index.php<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//第三步：清PHP的ea缓存。<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;eaccelerator_clear();<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;eaccelerator_clean();<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;eaccelerator_purge();<br/>php.ini里加上：<br/>eaccelerator.allowed_admin_path=&quot;/usr/htdocs/tools.jackxiang.com/index.php&quot;
]]>
</description>
</item><item>
<link>https://jackxiang.com/post//#blogcomment</link>
<title><![CDATA[[评论] [实践OK]清理VPS上eaccelerator_cache的缓存内容及设置]]></title> 
<author> &lt;user@domain.com&gt;</author>
<category><![CDATA[评论]]></category>
<pubDate>Thu, 01 Jan 1970 00:00:00 +0000</pubDate> 
<guid>https://jackxiang.com/post//#blogcomment</guid> 
<description>
<![CDATA[ 
	
]]>
</description>
</item>
</channel>
</rss>