注册 登录  
 加关注
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

Perfect-World

以無法為有法,以無限為有限!

 
 
 

日志

 
 

Nginx基本模块—Memcached  

2015-08-14 17:39:02|  分类: Web Server |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |

Memcached

你可以利用本模块来进行简单的缓存以提高系统效率。本模块计划在未来进行扩展。

__配置示例__

 

server {

: location / {

: set $memcached_key $uri;

: memcached_pass name:11211;

: default_type text/html;

: error_page 404 = /fallback;

: }

 

: location = /fallback {

: proxy_pass backend;

: }

}

指令

  • [#memcached_pass memcached_pass]
  • [#memcached_connect_timeout memcached_connect_timeout]
  • [#memcached_send_timeout memcached_send_timeout]
  • [#memcached_read_timeout memcached_read_timeout]
  • [#memcached_buffer_size memcached_buffer_size]
  • [#memcached_next_upstream memcached_next_upstream]

变量

  • $memcached_key

memcached_pass

语法: memcached_pass [ name:port ]

默认值: none

作用域: http, server, location

The backend should set the data in memcached. The memcached key is "/uri?args".

Since 0.5.9 the memcached key is now in$memcached_key.

memcached_connect_timeout

语法: memcached_connect_timeout [ time ]

默认值: 60000

作用域: http, server, location

The timeout for connecting to memcached, in milliseconds.

memcached_read_timeout

语法: memcached_read_timeout [ time ]

默认值: 60000

作用域: http, server, location

The timeout for reading from memcached, in milliseconds.

memcached_send_timeout

语法: memcached_send_timeout [ time ]

默认值: 60000

作用域: http, server, location

The timeout for sending to memcached, in milliseconds.

memcached_buffer_size

语法: memcached_buffer_size [ size ]

默认值: see getpagesize(2)

作用域: http, server, location

The recv/send buffer size, in bytes.

memcached_next_upstream

语法: memcached_next_upstream [ error | timeout | invalid_response | not_found | off ]

默认值: error timeout

作用域: http, server, location

Which failure conditions should cause the request to be forwarded to another upstream server? Applies only when the value in memcached_pass is an upstream with two or more servers.

 

可能您还对以下事情兴趣: 

Nginx在Windows和Linux环境下安装 

i>默color:>

Np" >d: #文件详细说明font-family:宋体;=1&cfont-family:38405="fonng>

i>默color:>

Npn>

ps">

用微信451651953227style="font-family:微软雅黑;" Np:

ps">

用微信451611184964style="font-family:微软雅黑;" Np调优 :

ily:Verbsp;标 V7 性能font-family:宋体;=1&cfont-family:38405="fonng>

ps">

用微信455962636style="font-family:微软雅黑;" Npwebsp moe7.0中d: #ora 数据源及部署font-family:宋体;=1&cfont-family:38405="fonng>

ps">

用微信45sp;41613 style="font-family:微软雅黑;" Np:

ps">

用微信44 <15l3390style="font-family:微软雅黑;" NpTop ct>

i>默color:>Npd: #:

ps">

用微信4119102641&astyle="font-family:微软雅黑;" Np:

i>默color:>

Np:

ps">

用微信352062541864style="font-family:微软雅黑;" Np黑;ux(fedora、redhat)下d: #web+ftp服务器全教程m=e>

ps">

用微信2101832 >NpJ2SDK1.4.23.cole="及/褂媒坛蘭=e>

ize:/tdng-right: 7px;" >

i>默color:>

Np解决启动:http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Np绿色版TOMCAT 7.0le="d: #手us="e> http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

NpTop ct7.0 内存d: #font-family:宋体;=1&cfont-family:38405http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Npweb/spicd: #JDBC数据源详解="e> http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Np: http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Npn <做web/spic的前端负载均衡器font-family:宋体;=1&cfont-family:38405http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Np图文解>+top ctd: #集群负载均衡="e> http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Np:i>默color:>

NpLINUX FTPle="与d: #font-family:宋体;=1&cfont-family:38405http, setylep stylep stgin-l文m=e:yellow;" =1" htyle="color:#951a1a; font-size:9pt;" t;" >i>默color:>

Npn>详细图解教程m=e> i>默color:>

NpUbuntu/Deb63.上le="" >+phpan s="e>

i>默color:>

用微信210182496987style="font-family:微软雅黑;" Np/褂肵AMPP搭建本地JSP+PHPan s="e>

i>默color:>

Np基于n <的黑;ux web服务器d: #font-family:宋体;=1&cfont-family:

ize:/tdng/ding/ />. &手机二维码访问p>

style="" >p class="tdep clear - dc0 bds2 - Perfy:V-Worldtyle201571453923/a>1.ph.126.

="fonnenont-fammily:宋体;" >-bkicons">

201571453923b.bst.126. .png?1"ing">

i>默colortext-decoratione="分享到

201571453923b.bst.126. .png?1"ing">

阅读(ffont-g">right fc">

评论(ffont-g">

right fc">

        < id="$_shareBtntn_weixin2" title="分享到微信" class="shareitm weixin f-bkicons">

id="$_shareBtn://blog.163.com/bitMaxImageGen.do?url=http://yut-i.blog.163.com/blog/static/2425778220157145392391&w=100&h=100&act=qbbkfxtj_20150420_06">

用易信  “扫一扫”

将文章1 id">

 

<"sharToL蚮t标Fremy="etho pos"bl t;" >i>默colo "m-1y268&>LOFTER精选pos"blan31023_04id">

···

p class="tdep clear"ing">

loft<font-tyle=""c38405;读"csssloftn st<te:yeloft<font-tyle=""c38405;෿"color:#"csssloftă<te:yeloft<"e> loft<te:yeloft</ploft<ulloft<liloft<font-tyle=""c htt"color:#tylep style3&non"csssloftana; font-size:10pt;" >[#memcac<te:yeloft<"liloft<liloft<font-tyle=""c htt"color:#tylep style3&non"csssloftana; font-si:Verdanana; font-size:10pt:Verdanana; fon]a<te:yeloft</liloft<liloft<font-tyle=""c htt"color:#tylep style3&non"csssloftana; font-si;" >

loft<font-tyle=""c38405;读"csssloftn st<te:yeloft<font-tyle=""c38405;෿"color:#"csssloftă<te:yeloft<"e> loft<te:yeloft</ploft<ulloft<liloft<font-tyle=""c htt"color:#tylep style3&non"csssloft/p>

loftkground-c;-fami<te> loft<te:yeloft</ploft<ploft<font-tyle=""com/?ac> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&n loft/span> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&n loftn <te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&nhtt"color:#"csssloft<font-tyle=""c38405="fonn&non"csssloftnt-size:9pt; background-color:#f9f9f9;"<teontloft<font-tyle=""c

loftkground-c;:Verdanana; fona<te> loft<teontloft</ploft<ploft<font-tyle=""c htt5;"csssloft<f> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&n"csssloft&n loftn <te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&nmemc<teontloft</ploft<ploft<font-tyle=""c

htt"color:#tylep style3 fon"csssloft<f> loftkground-c;;" > loft<teontloft</ploft<ploft<font-tyle=""c htt5;"csssloft<f> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&nhtt"color:#"csssloft&n loftn <te> loft<te:ytloft<font-tyle=""c38405;෿"color:#"csssloft&nmemc<teontloft</ploft<ploft<font-tyle=""c

htt"color:#tylep style3 fon"csssloft<f> loftkground-c;;" > loft<teontloft</ploft<ploft<font-tyle=""c htt5;"csssloft<f> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&nhtt"color:#"csssloft&n loftn <te> loft<teontloft<font-tyle=""c38405;෿"color:#"csssloft&nmemc<teontloft</ploft<ploft<font-tyle=""c

htt"color:#tylep style3 fon"csssloft<f> loftkground-c;" > loft<teontloft</ploft<ploft<font-tyle=""c htt5;"csssloft<f> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&nmemc<teontloft</ploft<ploft<font-tyle=""c

htt"color:#tylep style3 fon"csssloft<f> loftkground-c;

loft<teontloft</ploft<ploft<font-tyle=""c htt5;"csssloft<f> loftort ]<<te> loft<te:yeloft<font-tyle=""c38405;෿"color:#"csssloft&n

 

htt stylep stylep style1="font-family:Arial; font-siz"csssloft<f> loftnbsp;

<te> loft<teontloft<font-tyle=""c38405;෿se;" border="0" ><"csssloft&n
"cssstyle=""c > loft" > 

httse;" "csssloft&n

用微信;" > loft" >d: #文件详细说明<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信; t515lor4s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftn>

httse;" "csssloft&n

用微信;51651953227s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft: loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;51611184964s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft调优 :

ily:Verbsp;标 V7 性能<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;55962636s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftwebsp moe7.0中d: #ora 数据源及部署<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;5sp;41613 s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft: loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;4 <15l3390s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftTop ct> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;119105644n s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftd: #: loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;119102641&as"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft: loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信;11910192520s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft:

httse;" "csssloft&n

用微信352062541864s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft黑;ux(fedora、redhat)下d: #web+ftp服务器全教程<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信2101832 >htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftJ2SDK1.4.23.cole="及/褂媒坛<te> loft<teontloft</aloft<font-tyle=""c

httse;" tylep stylep st"csssloft&n"cssstyle=""c >

用微信s21881 htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft解决启动: loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s2188<15760s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft绿色版TOMCAT 7.0le="d: #手us<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s21875222667s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftTop ct7.0 内存d: #<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s21603934263s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftwebs">icd: #JDBC数据源详解<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s21603617n s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft: loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s022102556658s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftn <做web/spic的前端负载均衡器<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s02210blo716s"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft图文解>+top ctd: #集群负载均衡<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信s02292ux239/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft: loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信;" 1904727883/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftLINUX FTPle="与d: #<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<ploft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信;" 4540<08/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftLinux下le="" >详细图解教程<te> loft<teontloft</aloft<font-tyle=""c38405;读tylep stylep st"csssloft文<teontloft</ploft<pltyle=""cen"csssloft<:縮tyle="c0amp;olor:#95amp;1a1a; foamp;1t-size:amp;1tt;" "cs t;" "c a:/"cs;clas"cerda://stylan style="colorps">

用微信21018340<38/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loftUbn nu/Debian上le="" >+phpan s<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信210182496987/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft使用XAMPP搭建本地JSP+PHPan s<te> loft<teontloft</aloft<font-tyle=""c38405="fonp st"csssloft<font-tyle=""c

httse;" "csssloft&n

用微信2101801127503/"csssloft<fontltyle=""c htt stylep stylep stylep stylep stylep sty7o软雅黑;" "csssloft<f> loft基于n <的黑;ux web服务器d: #<te> loft<teontloft</aloft<font-tyle=""c

httse;" tylep stylep st"csssloft&n loft手机二维码访问:<te> loft<teontloft<font-tyle=""c

httse;" tylep style12 st"csssloft&np class="tdep clear - 悠悠思恋 - Perfect-World"cssssrc="cerda://img1.ph.126.net/8F3y8qfqv9k8gXdsxsNBBA==/6630242032467658972.jpg"csssalt="c"cssslign="t"c0"csss/loft</aloft<te:yeloft<font-tyle=""c

="fonn2 st"csssloftmily<te:yeloft<te:yeloft</ploft"ing">

用微信571sp;92391"ing">

<$_fontLike">喜欢 ssssssssssssffont-e="colof-myLikeI:Ves foomm" btn pnt prighl" g"><$_fontRfoomm" ">推荐 ssssssssssffont-tyle="mtarget="_blablg"><$_fontShowRfoomm" "le="colop="bl rdct p;tee">"> ssssssssssssffont-e="colop="bl ul 阅<3">ffont-g"><$_fontRfoomm" Cd nt">0&n&nfte:ye=|&n ssssssssssfte:ye=">

btn pnt prighl" g"><$_fontCite">转载fte:ye=">

<$_styRfoomm" Cdettert>ftsty=">

&n

<$_newOldBs">n>"> sssssftsty="> ssssfont-size:18relatebs"> p;tee">">sssssssss 历史上的今天

ftsty=">

ssssfont-tyle="mtarget="_bla;visibility:;teden;" st0;heighl:0;overflow:;teden;tyclass="author">"> ssssss最近读者 ssssssfont-size:18cer ztagyclearfix">ftsty="> ssssftsty="> ssssfont-tyle="mtarget="_bla;visibility:;teden;" st0;heighl:0;overflow:;teden;tyg">"> ssssss热度 ssssssfont-g">ftsty="> ssssftsty="> ssssfont-class="p;teetyg">ftsty="> ssss"> ssssfont-size:18m-l;" >adtytyle="mtarget="_bla">"> ssssss falclass="ad黑;k" ;clas"#bl t;" >i>默colo;teefocus="true"><="bl;" >adimg"ing"> ssssssssfont-g">ftsty="> ssssssssfiframe en"> ssssftsty="> ssss"> ssssfont>"> ssss 在LOFTER的更多文章 ssss font-tyle="m" st100%;overflow:;teden;t>"> ssss