<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Memcached &#8211; 就爱分享</title>
	<atom:link href="https://www.9host.org/tag/memcached/feed" rel="self" type="application/rss+xml" />
	<link>https://www.9host.org</link>
	<description>最爱分享各种资源的中文独立博客</description>
	<lastBuildDate>Sun, 19 Apr 2026 09:31:01 +0000</lastBuildDate>
	<language>zh-Hans</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>宝塔Memcached双剑合璧，WordPress秒速加载不是梦！</title>
		<link>https://www.9host.org/1543.html</link>
					<comments>https://www.9host.org/1543.html#respond</comments>
		
		<dc:creator><![CDATA[河马大叔]]></dc:creator>
		<pubDate>Fri, 20 Dec 2024 15:02:42 +0000</pubDate>
				<category><![CDATA[WordPress]]></category>
		<category><![CDATA[新手教程]]></category>
		<category><![CDATA[Memcached]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[wordpress加速]]></category>
		<category><![CDATA[宝塔]]></category>
		<guid isPermaLink="false">https://www.9host.org/?p=1543</guid>

					<description><![CDATA[如果不用内存缓存技术来给河马大叔的博客进行加速，你&#8230;]]></description>
										<content:encoded><![CDATA[<p><img fetchpriority="high" decoding="async" width="1280" height="720" src="https://www.9host.org/wp-content/uploads/2024/12/Memcached-wordpress.jpg" class="alignnone size-medium wp-image-1816" srcset="https://www.9host.org/wp-content/uploads/2024/12/Memcached-wordpress.jpg 1280w, https://www.9host.org/wp-content/uploads/2024/12/Memcached-wordpress-800x450.jpg 800w, https://www.9host.org/wp-content/uploads/2024/12/Memcached-wordpress-1160x653.jpg 1160w, https://www.9host.org/wp-content/uploads/2024/12/Memcached-wordpress-220x124.jpg 220w" sizes="(max-width: 1280px) 100vw, 1280px" /><br />
如果不用内存缓存技术来给河马大叔的博客进行加速，你会觉得非常非常卡。而在宝塔下运行 Memcached 加速河马大叔的博客（WordPress），大叔初步估计速度上至少提升了5-10倍以上。</p>
<h2>宝塔Linux安装Memcached</h2>
<p>这里你首先得把基础环境安装好，由于本篇文章将的是内存缓存，不再多说。<br />
首先在左侧菜单栏进入软件管理，找到 Memcached 1.6.X 并安装它，为了稳定运行，大叔所有环境均使用编译安装。<br />
<img decoding="async" class="alignnone size-medium wp-image-1812" src="https://www.9host.org/wp-content/uploads/2024/12/Memcached-800x50.png" alt="" width="800" height="50" srcset="https://www.9host.org/wp-content/uploads/2024/12/Memcached-800x50.png 800w, https://www.9host.org/wp-content/uploads/2024/12/Memcached-1160x73.png 1160w, https://www.9host.org/wp-content/uploads/2024/12/Memcached-220x14.png 220w, https://www.9host.org/wp-content/uploads/2024/12/Memcached.png 1316w" sizes="(max-width: 800px) 100vw, 800px" /><br />
然后，在 PHP 相对应的版本中，安装拓展<br />
<img decoding="async" class="alignnone size-medium wp-image-1813" src="https://www.9host.org/wp-content/uploads/2024/12/php-Memcached-800x686.png" alt="" width="800" height="686" srcset="https://www.9host.org/wp-content/uploads/2024/12/php-Memcached-800x686.png 800w, https://www.9host.org/wp-content/uploads/2024/12/php-Memcached-175x150.png 175w, https://www.9host.org/wp-content/uploads/2024/12/php-Memcached.png 994w" sizes="(max-width: 800px) 100vw, 800px" /></p>
<h2>WordPress安装启用Memcached</h2>
<p>需要你的服务器支持，就是你的 PHP 需要安装上 Memcached 相关的扩展，注意 PHP 有两个扩展：PHP Memcache 扩展 和 PHP Memcached 扩展，两者仅仅相差一个字母 D，你可以通过 phpinfo() 这个 PHP 函数来检测，你安装的是哪个扩展。如果你已经做好了上一步操作，这里可以不用管！</p>
<p>下载 WordPress 中的 memcached-is-your-friend 插件.</p>
<p>从这下载插件并解压，把里面的 memcached-class-object-cache.php 重命名为 object-cache.php 上传至 /wp-content/ 目录，注意不是 wp-content/plugins/ 目录.</p>
<p>根据不同的 PHP 扩展下载不同的 WordPress Memcached 插件（这个很重要）：<br />
PHP Memcached 扩展：<a href="https://wordpress.org/plugins/memcached-is-your-friend/" target="_blank">https://wordpress.org/plugins/memcached-is-your-friend/</a></p>
<p>WordPress 会自动检查在 wp-content 目录下是否有 object-cache.php 文件，如果有，直接调用它作为 WordPress 对象缓存机制。</p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.9host.org/1543.html/feed</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
