NginxJa
Nginx銇劇鏂欍仹鍒╃敤銇с亶銈嬨偑銉笺儣銉炽偨銉笺偣銇儚銈ゃ儜銉曘偐銉笺優銉炽偣HTTP銈点兗銉愪笖銇ゃ儶銉愩兗銈广儣銉偔銈枫仹銆両MAP/POP3銇儣銉偔銈枫偟銉笺儛銇ㄣ仐銇︺倐鍕曚綔銇椼伨銇欍Igor Sysoev銇倛銇c仸2002骞淬伀闁嬬櫤銇屽銇俱倞銆2004骞淬伀鏈鍒濄伄銉愩兗銈搞儳銉炽亴鍏枊銇曘倢銇俱仐銇熴備粖銇с伅涓栫晫涓伄銉夈儭銈ゃ兂銇亰銈堛仢12.18% (22.2M)銇甒eb銈点偆銉堛倰Nginx銇岀鍍嶃仌銇涖仸銇勩伨銇欍
Nginx銇仢銇珮銇勩儜銉曘偐銉笺優銉炽偣銇ㄥ畨瀹氭с佽眾瀵屻仾姗熻兘銆佽ō瀹氥伄瀹规槗銇曘佹秷璨汇儶銈姐兗銈广伄浣庛仌銇х煡銈夈倢銇︺亜銇俱仚銆
Nginx銇C10K鍟忛銇彇銈婄祫銈銇广亸闁嬬櫤銇曘倢銇熶竴鎻°倞銇偟銉笺儛銇亞銇°伄涓銇ゃ仹銇欍傚緭鏉ャ伄銈点兗銉愩仺銇暟銇倞銆丯ginx銇儶銈偍銈广儓銇嚘鐞嗐倰銈广儸銉冦儔銇緷瀛樸仐銇︺亜銇俱仜銈撱傘仢銇唬銈忋倞銇倐銇c仺銈广偙銉笺儵銉栥儷銇紙闈炲悓鏈熴伄锛夈偆銉欍兂銉堥鍕曘偄銉笺偔銉嗐偗銉併儯銈掍娇鐢ㄣ仐銇︺亜銇俱仚銆傘亾銇偄銉笺偔銉嗐偗銉併儯銇儭銉€儶浣跨敤閲忋亴灏戙仾銇勩仩銇戙仹銇亸銆佹渶銈傞噸瑕併仾浜嬨仺銇椼仸銆佺鍍嶆檪銇儭銉€儶浣跨敤閲忋亴浜堟脯鍙兘銇с亗銈嬨仺銇勩亞銇撱仺銇с仚銆
鍚屾檪銉偗銈ㄣ偣銉堟暟銇1涓囥儶銈偍銈广儓銈傘仾銇嬨仯銇熴仺銇椼仸銈傘丯ginx銇儚銈ゃ儜銉曘偐銉笺優銉炽偣銈勩儭銉€儶娑堣不閲忋伄灏戙仾銇曘伄鎭╂伒銈掑彈銇戙倠浜嬨伅銇с亶銈嬨仹銇椼倗銇嗐侼ginx 銇皬瑕忔ā銇 VPS 銇嬨倝澶ц妯°仾銈点兗銉愩亱銈夈仾銈嬨偗銉┿偣銈裤伨銇у蹇溿仚銈嬫嫛寮垫с倰鍌欍亪銇︺亜銇俱仚銆
Nginx銇WordPress銈Hulu銆Github銆Ohloh銆SourceForge銆WhitePages銆TorrentReactor 銇ㄣ亜銇c仧鐭ュ悕搴︺伄楂樸亜銈点偆銉堛倰绋煎儘銇曘仜銇︺亜銇俱仚銆
Contents |
Nginx 1.2.0 銇屻儶銉兗銈广仌銈屻伨銇椼仧
1.2.x 瀹夊畾鐗堛伄鏈鍒濄伄銉愩兗銈搞儳銉炽亴銉儶銉笺偣銇曘倢銇俱仐銇熴
1.2.0 銇伅涓嬭銇倛銇嗐仾 1.1.x 銉栥儵銉炽儊銇ч枊鐧恒仌銈屻仧妲樸呫仾鏂般仐銇勬鑳姐亴鍙栥倞杈笺伨銈屻仸銇勩伨銇:
- 涓婃祦銈点兗銉愩伕銇 keepalive 鎺ョ稓銈掋偟銉濄兗銉堛仐銇俱仚 (HTTP 1.1)
- 銈儯銉冦偡銉炽偘銇屾湁鍔广仾鍫村悎銇佷笂娴併偟銉笺儛銇搞伄瑜囨暟銇悓鏅傘儶銈偍銈广儓銈掔当鍚堛仐銇俱仚
- 瑜囨暟銇儶銈偍銈广儓銇娿倛銇虫帴缍氬埗闄愩伄鍚屾檪浣跨敤銈掋偟銉濄兗銉堛仐銇俱仚
- 闀锋檪闁撴帴缍氥仌銈屻仸銇勩倠銉偗銈ㄣ偣銉堛伄銉忋兂銉夈儶銉炽偘銇仼妲樸呫仾鐗规畩銈便兗銈广伀銇娿亜銇︺併儭銉€儶娑堣不銈掍綆娓涖仐銇俱仚
瑭炽仐銇忋伅瀹屽叏銇 澶夋洿灞ユ 銈掑弬鐓с仐銇︺亸銇犮仌銇勩
Nginx 銇 300涓囥儔銉伄璩囬噾瑾块仈銇垚鍔熴仐銆併偟銉炽儠銉┿兂銈枫偣銈炽伀鏈儴銈掗枊瑷簣瀹
銈兗銉椼兂銈姐兗銈广伄Web銈点兗銉愰枊鐧虹ぞ NGINX 銇屻偡銉兗銈篈銆嶆姇璩囥儵銈︺兂銉夈仹300涓囥儔銉伄璩囬噾瑾块仈銇垚鍔熴仐銇俱仐銇熴 鐝惧湪銆丯GINX 銇偆銉炽偪銉笺儘銉冦儓涓娿仹4000涓囦互涓娿倐銇儔銉°偆銉炽佷笘鐣屼腑銇ф渶銈傚繖銇椼亜1000銇偊銈с儢銈点偆銉堛伄銇嗐仭20%浠ヤ笂銈掔鍍嶃仌銇涖仸銇勩伨銇欍 銇撱伄涓伀銇丗acebook, Zappos, Groupon, LivingSocial, Hulu, TechCrunch, Dropbox, WordPress 銇ㄣ亜銇c仧钁楀悕銈点偆銉堛倐鍚伨銈屻伨銇欍
BV銈儯銉斻偪銉伄 Thomas Gieselmann 銇銇倛銇嗐伀瑾炪仯銇︺亜銇俱仚: 銆屾垜銆呫亴鎶曡硣銇椼仧浼佹キ銇亜銇忋仱銇嬨伅銆乄eb 銉椼儵銉冦儓銉曘偐銉笺儬銈 NGINX 銇Щ琛屻仚銈嬨亾銇ㄣ仹閲嶈銇偣銈便兗銉兂銈板晱椤屻倰瑙f焙銇欍倠銇撱仺銇屻仹銇嶃仧銆傘 銆孨GINX銇偆銉炽偪銉笺儘銉冦儓涓娿伄鏈澶с伄銈点偆銉堛倰閫忛亷鐨勩亱銇ゆ湁鍔广伀鎴愰暦銇曘仜銈嬨仩銈嶃亞銆傘
Nginx 銇浉绫嶃亴鍑虹増銇曘倢銇俱仐銇!
Clement Nedelcu 銇嫳瑾炪仹鏇搞亱銈屻仧鏈鍒濄伄 Nginx 鏈倰鍩风瓎銇椼伨銇椼仧銆侼ginx 銇儉銈︺兂銉兗銉夈仺銈ゃ兂銈广儓銉笺儷銇嬨倝銆 銉€偢銉ャ兗銉倰浣裤仯銇熻ō瀹氭柟娉曘仾銇┿仌銇俱仏銇俱仾銉堛償銉冦偗銇仱銇勩仸瑙︺倢銈夈倢銇︺亜銇俱仚銆傘伨銇熴併仚銇с伀鍒╃敤銇椼仸銇勩倠Web銈点兗銉愩倰 Nginx 銇疆銇嶆彌銇堛倠銇熴倎銇偣銉嗐儍銉椼儛銈ゃ偣銉嗐儍銉椼伄銉併儱銉笺儓銉偄銉倐鎻愪緵銇曘倢銇︺亜銇俱仚銆傘偝銉°兂銉堛倰娣汇亪銇熻ō瀹氫緥銈勩 銉€偢銉ャ兗銉倰娣便亸鎺樸倞涓嬨亽銇熻鏄庛仾銇┿倰浜ゃ亪銇︺丯ginx 銇屽倷銇堛倠銉戙儠銈┿兗銉炪兂銈广倰寮曘亶鍑恒仚銇熴倎銇銇岃В瑾仌銈屻仸銇勩伨銇欍
Nginx鏈伄鏃ユ湰瑾炵増銇屽嚭鐗堛仌銈屻伨銇椼仧!
銈€偣銈兗銉汇儭銉囥偅銈€儻銉笺偗銈广倛銈婃棩鏈獮缈昏ǔ鐗 銆銉忋偆銉戙儠銈┿兗銉炪兂銈笻TTP銈点兗銉 Nginx鍏ラ杸銆嶃亴鐧哄2銇曘倢銇︺亜銇俱仚銆
A while back, we changed our frontend IMAP/POP proxy from perdition to nginx... [and] we鈥檝e now switched over to using nginx for our frontend web proxy as well... The net result of all this is that each frontend proxy server currently maintains over 10,000 simultaneous IMAP, POP, Web & SMTP connections (including many SSL ones) using only about 10% of the available CPU.
銇撱伄wiki銇с伅銈ゃ兂銈广儓銉笺儷銇ㄨō瀹氥併偄銉夈偑銉炽伀闁€仚銈嬫儏鍫便仺Tips銈掋伨銇ㄣ倎銇︺亜銇俱仚銆傛皸杌姐伀鍙傚姞銇椼仸銇忋仩銇曘亜锛