Slide 1

Slide 1 text

͸ͯͳͷ
 αʔόʗΠϯϑϥΛࢧ͑Δٕज़
 ʙ2016೥৽ଔฤʙ

Slide 2

Slide 2 text

͸ͯͳʹ͍ͭͯ • 2001೥૑ۀ • ࣾһ਺110໊ɿژ౎ͱ౦ژͷ2ڌ఺ମ੎ • αʔϏε • Mackerel • ͸ͯͳϒοΫϚʔΫ • ͸ͯͳϒϩά • Ոిձٞ • ਓྗݕࡧ͸ͯͳɺΩʔϫʔυɺΞϯςφɺͳͲͳͲ

Slide 3

Slide 3 text

mackerel.io Application Performance Management ϒʔεग़లͯ͠·͢ʂʂʂ

Slide 4

Slide 4 text

࣭໰ • ֶੜ or ࣾձਓ • Πϯϑϥ or ΞϓϦέʔγϣϯ • WebαʔϏε։ൃܦݧ༗Γ or ແ͠

Slide 5

Slide 5 text

͸ͯͳͷνʔϜମ੎ • ։ൃνʔϜ • ΠϯϑϥνʔϜ • αʔϏεӡ༻νʔϜʢલ൒ɿtaketo957ʣ • ओʹαʔϏεͷӡ༻ɺվળΛ୲౰ • ج൫։ൃνʔϜʢޙ൒ɿmasayoshiʣ • શαʔϏεΛࢧ͑Δج൫෦෼Λ୲౰

Slide 6

Slide 6 text

લ൒
 αʔϏεߏஙฤ

Slide 7

Slide 7 text

ࣗݾ঺հ • id:taketo957ʢࠤʑ໦݈ਓʣ • 2016৽ଔ • αʔϏεӡ༻νʔϜ • ޿ࠂ഑৴γεςϜͷ࡮৽Λ୲౰ • ֶੜ࣌୅͸ਪનͱ͔ͯ͠·ͨ͠ • झຯ͸ϘϧμϦϯάͰ͢

Slide 8

Slide 8 text

ࠓ೔ͷ͓࿩ • ͸ͯͳͷWebγεςϜͷཪଆ • ୲౰ͨ͠޿ࠂ഑৴γεςϜΛ୊ࡐʹγεςϜͷ
 Πϯϑϥ͕ͲͷΑ͏ʹͰ͖͍ͯ͘ͷ͔ • ϛυϧ΢ΣΞɺϦϦʔε·Ͱʹ΍Δ͜ͱΛத৺ʹ • Πϯϑϥͬͯ೉ͦ͠͏ • Կ΋஌Βͳ͔ͬͨࣗ෼͕޿ࠂ഑৴ͷΠϯϑϥΛ
 ࡞ΔதͰ஌ͬͨ͜ͱɺ΍ͬͨ͜ͱ

Slide 9

Slide 9 text

TOCʢલ൒ʣ • WebαʔϏεͷ࢓૊Έ • ͸ͯͳʹ͓͚ΔWebαʔϏεͷ
 ࡞Γํ • ҆ఆӡ༻ɺύϑΥʔϚϯε޲্ͷ
 ͨΊͷऔΓ૊Έ

Slide 10

Slide 10 text

1 WebαʔϏεͷ
 ࢓૊Έ

Slide 11

Slide 11 text

WebγεςϜͱ͸ • HTTPϦΫΤετΛड͚ͯϨεϙϯεΛฦ͢΋ͷ • ϨΠςϯγͱεϧʔϓοτΛಉ࣌ʹୡ੒͢Δඞཁ͕͋Δ • ϨΠςϯγ…ϦΫΤετΛൃ͔ͯ͠ΒɺϨεϙϯε͕ ฦͬͯ͘Δ·Ͱͷ࣌ؒ • εϧʔϓοτ…୯Ґ࣌ؒ͋ͨΓʹॲཧͰ͖Δ
 ϦΫΤετ਺ • ͲΜͳʹෳࡶͰ͋ͬͯ΋جຊ͸ಉ͡

Slide 12

Slide 12 text

WebγεςϜͷ3૚ߏ଄ʢཁૉʣ 1SPYZ "QQMJDBUJPO %BUBCBTF 1SPYZαʔόʢϦόʔεϓϩΩγʣ  ֎͔ΒͷϦΫΤετΛ௚઀ड͚औΔ  ੩తϑΝΠϧฦ٫ɺΞΫηε੍ޚͳͲΛߦ͏ "QQMJDBUJPOαʔό  γεςϜͷத৺ͰΞϓϦέʔγϣϯϩδοΫΛ࣮ߦ  %#ͱͷ઀ଓɺϨεϙϯεͷߏஙͳͲΛߦ͏
 %BUBCBTFαʔό  αʔϏεͷఏڙʹඞཁͳσʔλΛอ࣋͢Δ  *0ॲཧʹΑͬͯҰൠతʹϘτϧωοΫʹͳΓ΍͍͢

Slide 13

Slide 13 text

WebγεςϜͷ3૚ߏ଄ʢ઀ଓʣ 1SPYZ "QQMJDBUJPO %BUBCBTF 8FCαʔόͷ઀ଓํࣜ  1SFGPSL  5ISFBE1PPM  &WFOU%SJWFO %#αʔόͱͷ઀ଓ  ౎౓઀ଓ
 ϦΫΤετͷॲཧதͷΈ઀ଓΛҡ࣋  ৗ࣌઀ଓ
 %#઀ଓΦϒδΣΫτΛΩϟογϡͯ͠͠·͏

Slide 14

Slide 14 text

ͦͷଞʹ΋… • Cache • KVS/NoSQL • Batch • Job Queue

Slide 15

Slide 15 text

2 WebαʔϏεͷ
 ࡞Γํ

Slide 16

Slide 16 text

޿ࠂ഑৴
 γεςϜͷ৔߹

Slide 17

Slide 17 text

޿ࠂ഑৴γεςϜͱ͸ • ΞϓϦέʔγϣϯ͔Βͷ޿ࠂදࣔϦΫΤετʹ ରͯ͠ɺ޿ࠂϨεϙϯεΛฦ٫͢Δ • ϦμΠϨΫτઌͷURLɺը૾URL౳ΛؚΉ΋ͷ "QQMJDBUJPO "E4FSWFS ޿ࠂ͍ͩ͘͞ ͸͍ͬ ೖߘ Ϣʔβ ޿ࠂೖߘऀ

Slide 18

Slide 18 text

޿ࠂ഑৴γεςϜͱ͸

Slide 19

Slide 19 text

޿ࠂ഑৴γεςϜͷੑ࣭ • ࢀরͷׂ߹͕ଟ͍ • WebαʔϏεͷPV਺ʹൺྫͨ͠ࢀরϦΫΤετʢΊͬͪΌଟ͍ʣ • ΞϓϦέʔγϣϯͷදࣔ଎౓ͳͲʹӨڹΛ༩͑Δ • ߋ৽ͷස౓͕গͳ͍ • جຊతʹೖߘऀʹΑͬͯೖߘ͞ΕΔ࣌ • ԿΛͲΕ͘Β͍഑৴͔ͨ͠ͷϩάΛอଘ͢Δඞཁ͕͋Δ • ޿ࠂओ΁޿ࠂޮՌΛใࠂ͠ͳ͍ͱ͍͚ͳ͍ "QQMJDBUJPO "E4FSWFS Ϣʔβ ޿ࠂೖߘऀ

Slide 20

Slide 20 text

։ൃͷྲྀΕ • ࢓༷ΛܾΊΔ • ੑ࣭΍ཁٻΛߟྀ • ઃܭ • ੑೳݟੵ΋ΓɺΞʔΩςΫνϟઃܭ • ߏங • ઃܭʹج͍࣮ͯࡍʹߏஙΛߦ͏ • ͸ͯͳͰ͸chefΛ࢖͏͜ͱ͕ଟ͍

Slide 21

Slide 21 text

ΞʔΩςΫνϟ %BUBCBTF 4UPSBHF "QQ $BDIF ޿ࠂೖߘ $BDIF 1SPYZ ޿ࠂ഑৴αʔό "QQ ޿ࠂ؅ཧαʔό %BUBCBTF ϦΫΤετ 4FBSDI
 &OHJOF -PH
 'PSXBSEFS ΤϯυϢʔβ ޿ࠂೖߘऀ όον
 ੈ୅؅ཧ͞Εͨ
 Ωϟογϡͷ࡞੒ ϨϓϦέʔγϣϯ ϩά഑ૹ

Slide 22

Slide 22 text

3 ޿ࠂ഑৴γεςϜͷཁٻͱ
 ҆ఆӡ༻ɺύϑΥʔϚϯε޲্ ͷͨΊͷऔΓ૊Έ

Slide 23

Slide 23 text

޿ࠂ഑৴γεςϜͷཁٻ • ϨΠςϯγཁٻ • 50 msec or dieʢۀքج४ʣ • ߴ͍Մ༻ੑ • ഑৴͸Կ͕͋ͬͯ΋ʮઈରʹʯࢭΊͯ͸͍͚ͳ͍ • ϩά഑ૹͷ৴པੑ • ϩάͷॏෳɺܽଛ͸جຊతʹڐ͞ΕΔ΋ͷͰ͸ͳ͍ "QQMJDBUJPO "E4FSWFS Ϣʔβ ޿ࠂೖߘऀ NTFD

Slide 24

Slide 24 text

ֶੜ࣌୅͔ΒͷISUCON ͷܦݧ͕׆͖Δ

Slide 25

Slide 25 text

ෛՙࢼݧ • ϨΠςϯγཁٻͷ࣮ݱͷͨΊʹࣄલʹෛՙࢼݧ • ෛՙࢼݧπʔϧΛউखʹಋೖ • ຊ൪ϦϦʔεલʹνʔϜͰISUCON • ຊ൪૬౰ͷstaging؀ڥͱ
 ෛՙࢼݧπʔϧ༻ͷαʔόΛ४උ • ϨΠςϯγΛ֬ೝ͠ͳ͕ΒϘτϧωοΫΛվળ • ܧଓతʹվળΛߦ͑ΔΑ͏ʹCIʹ΋૊ΈࠐΉ

Slide 26

Slide 26 text

ෛՙࢼݧπʔϧ ͜ͷลΛݟͳ͕Βνϡʔχϯάʢ਺஋͸ҰྫͰ͢ʣ

Slide 27

Slide 27 text

ʮΦϖϨʔγϣϯͰ఺ΛकΓɺ 
 ϓϩάϥϛϯάͰ఺ΛͱΔʯ IUUQCMPHZVVLJPFOUSZXFCPQFSBUJPOTJTVDPO

Slide 28

Slide 28 text

ϘτϧωοΫͷಛఆ • γεςϜΛ؍࡯͠ཧղ͢Δͷ͕࠷ॳ • ΞϓϦέʔγϣϯΤϯδχΞʹద੾ͳվળཁٻΛग़͢ • ϘτϧωοΫͷղੳ • ಛఆʹ༻͍Δπʔϧ • ίϚϯυ…top, dstat, strace, perfͳͲ • MySQLͷεϩʔΫΤϦ…pt-query-digestͳͲ • ϓϩϑΝΠϥ…NYTProfͳͲͰ࣮ߦ࣌ؒ

Slide 29

Slide 29 text

ΞϓϦέʔγϣϯϩδοΫͷ
 ϘτϧωοΫͷಛఆ • NYTProfͷΑ͏ͳϓϩϑΝΠϥ • ࣌ࠁͷൺֱ΍จࣈྻͷ࣌ࠁ΁ͷม׵͕஗͍ • ϋογϡ஋ͷੜ੒ΞϧΰϦζϜ͕஗͍

Slide 30

Slide 30 text

DBͳͲ઀ଓํࣜͷΦʔόʔϔου • ౰ॳ͸࣮૷ίετͳͲͷཧ༝͔Β౎౓઀ଓํࣜ • ෛՙࢼݧΛਐΊ͍ͯ͘͏ͪʹΦʔόʔϔου͕
 അࣛʹͳΒͳ͍͜ͱ͕൑໌ • straceͰৄࡉͳॲཧΛ௥͏ • ৗ࣌઀ଓํࣜʹมߋ • DB઀ଓपΓͷΦʔόʔϔου͸࡟ݮ • ΞϓϦέʔγϣϯͰ͔ͬ͠ΓΤϥʔϋϯυϦϯά͢Δඞཁ

Slide 31

Slide 31 text

ϩάͷॻ͖ࠐΈपΓ • ޿ࠂ഑৴ͷಛ৭ • ࢀর͕ଟ͍ͷʹॻ͖ࠐΈ͕ൃੜ͢Δ • ͦ΋ͦ΋ѻ͏σʔλΛݮΒ͢ʢσʔλߏ଄ͷ޻෉ʣ • ϩάॻ͖ࠐΈͷΦϒδΣΫτ΋Ωϟογϡ • ݱঢ়Ͱ΋͜͜Ͱ౰ͨͬͯΔ • ϑΝΠϧ΁ͷॻ͖ࠐΈ෦෼ͰϩοΫ

Slide 32

Slide 32 text

ͦͷଞ • PlackʢAppαʔόʣͷύϥϝʔλௐ੔ͳͲ • ϓϩηεΛ௕ੜ͖ͤ͞Δ • worker਺͸ίΞ਺ఔ౓ʹ • ࠷ऴతʹ͸Gazelleʹ • MySQL indexվળ • Χʔωϧύϥϝʔλνϡʔχϯά • reuse, recycle port΍tcp_fin_timeoutͳͲ • Մ༻ੑɺϩά഑ૹͷ৴པੑΛߴΊΔ޻෉

Slide 33

Slide 33 text

લ൒·ͱΊ • ·ͱΊ • WebγεςϜͷجຊతͳ࢓૊Έ • ޿ࠂ഑৴γεςϜͷੑ࣭ͱઃܭ • ߴ଎ԽͷͨΊʹ΍ͬͨ͜ͱ • αʔϏεӡ༻ͷָ͠͞ • αʔϏεͷੑ࣭Λߟྀͯ͠࠷దղΛ୳Δͷָ͕͍͠ • ֶΜٕͩज़ͳͲ͕ͦͷ··݁Ռͱͯ͠ݱΕΔ

Slide 34

Slide 34 text

ج൫ฤ

Slide 35

Slide 35 text

ΞδΣϯμ • ࣗݾ঺հ • طଘͷ͸ͯͳͷαʔό,ωοτϫʔΫج൫ • ϩʔυόϥϯγϯά෦෼Λ঺հ • ج൫Λ΍Δָ͠͞(͕࣌ؒ͋Ε͹)

Slide 36

Slide 36 text

ࣗݾ঺հ

Slide 37

Slide 37 text

ࣗݾ঺հ • id:masayoshi • 2016೥4݄ೖࣾ • େֶ࣌୅ͷݚڀςʔϚ͸SDNͳͲωοτϫʔΫ • ֶੜ࣌୅͸MSPͰαʔό؂ࢹͷΞϧόΠτ • ݱࡏ͸WebΦϖϨʔγϣϯΤϯδχΞͷج൫νʔϜ

Slide 38

Slide 38 text

͸ͯͳͷΠϯϑϥࣄ৘

Slide 39

Slide 39 text

͸ͯͳͷΠϯϑϥࣄ৘ • αʔϏε͕ଟ͍ • 10αʔϏεҎ্ • ଉͷ௕͍αʔϏε • 10೥Ҏ্ͷαʔϏε • ςΩετϕʔεͷWebαʔϏε͕جຊ

Slide 40

Slide 40 text

αʔϏε͕ଟ͍ • 1αʔϏεʹෳ਺ϩʔϧ • Proxy, APP, DB,… • αʔϏε ✕ ϩʔϧʹΑΔαʔό୆਺ͷ૿Ճ • Ծ૝αʔό͚ͩͰ΋1000୆Ҏ্ (ਓ͸8ਓ) • αʔϏεͷଟ༷ੑ • ϒοΫϚʔΫ, ϒϩά, ޿ࠂ഑৴, Mackerel … • αʔϏε͝ͱʹϩʔϧ͸มԽ͢Δ

Slide 41

Slide 41 text

ଉͷ௕͍αʔϏε • 10೥Ҏ্ͷαʔϏε • ͸ͯͳϒοΫϚʔΫ, ͸ͯͳਓྗݕࡧͳͲ • 10೥͸ج൫ʹͱͬͯ΋͔ͳΓͷมԽ͕͋Δ • Ծ૝ԽɺΫϥ΢υɺίϯςφ • ϛυϧ΢ΣΞͷଟ༷Խ

Slide 42

Slide 42 text

ςΩετϕʔεͷWebαʔϏε • 1ճͷΞΫηεͷίωΫγϣϯ਺͕ଟ͍ • ProxyͷίωΫγϣϯॲཧ͸ॏཁ • HTTP2ͳͲͰվળͭͭ͠͸͋Δ • 1ΞΫηεͷ௨৴ྔ͸ଟ͘ͳ͍ • ετϦʔϛϯάͳͲͱ͸ҧ͏ • ϦΫΤεταΠζ << ϨεϙϯεαΠζ • େମͷWebαʔϏε͸Ϩεϙϯεͷ΄͏͕େ͖͍

Slide 43

Slide 43 text

͸ͯͳͷج൫͍Ζ͍Ζ • ϋ΢δϯά + Ϋϥ΢υ • Debian + Xen ͰͷαʔόԾ૝Խ • Chef, CapistranoͰͷϓϩϏδϣχϯά • MackerelͰͷ؂ࢹɺαʔό؅ཧ • Linux LVSͷෛՙ෼ࢄ

Slide 44

Slide 44 text

͸ͯͳͷωοτϫʔΫج൫

Slide 45

Slide 45 text

ཁ݅ • ωοτϫʔΫ,αʔόͷ৔ॴΛറΒΕͨ͘ͳ͍ • αʔϏεɺϩʔϧͱ’৔ॴ’͕ґଘͨ͘͠ͳ͍ • ֤ϩʔϧ͸ෛՙ෼ࢄɺ৑௕Խग़དྷΔΑ͏ʹ͍ͨ͠ • Proxy͸େྔͷίωΫγϣϯΛࡹ͖͍ͨ • ͔͠͠ෳࡶ͗͢Δ࢓૊Έ͸ݏͩ

Slide 46

Slide 46 text

/FUXPSL /FUXPSL /FUXPSL 3BDLPS%$ MPDBUJPO 3BDLPS%$ MPDBUJPO 4FSWFS 7. 7. 7. 7. 7. 7. 7. 7. 7. 7. 4FSWFS 4FSWFS 4FSWFS 4FSWFS 4FSWJDF" 1SPYZ "QQ %# 4FSWJDF# 1SPYZ "QQ %# $BDIF

Slide 47

Slide 47 text

/FUXPSL /FUXPSL /FUXPSL 3BDLPS%$ MPDBUJPO 3BDLPS%$ MPDBUJPO 4FSWFS 7. 7. 7. 7. 7. 7. 7. 7. 7. 7. 4FSWFS 4FSWFS 4FSWFS 4FSWFS αʔϏε" 1SPYZ "QQ %# 4FSWJDF# 1SPYZ "QQ %# $BDIF ෺ཧతͳ഑ஔΛҙࣝ ωοτϫʔΫΛҙࣝ ෺ཧαʔόΛҙࣝ

Slide 48

Slide 48 text

/FUXPSL /FUXPSL /FUXPSL 3BDLPS%$ MPDBUJPO 3BDLPS%$ MPDBUJPO 4FSWFS 7. 7. 7. 7. 7. 7. 7. 7. 7. 7. 4FSWFS 4FSWFS 4FSWFS 4FSWFS αʔϏε" 1SPYZ "QQ %# αʔϏε# 1SPYZ "QQ %# $BDIF Ϧιʔε͕ڞ༗Ͱ͖ͳ͍

Slide 49

Slide 49 text

4FSWJDF" 1SPYZ "QQ %# 4FSWJDF# 1SPYZ "QQ %# $BDIF /FUXPSL /FUXPSL /FUXPSL 3BDLPS%$ MPDBUJPO 3BDLPS%$ MPDBUJPO 4FSWFS 7. 7. 7. 7. 7. 7. 7. 7. 7. 7. 4FSWFS 4FSWFS 4FSWFS 4FSWFS

Slide 50

Slide 50 text

ϩʔϧͱLBͱωοτϫʔΫ

Slide 51

Slide 51 text

ϩʔϧͱϩʔυόϥϯα • ϩʔϧؒͷ௨৴͸جຊతʹLBΛ௨͢ • ෛՙ෼ࢄɺ৑௕Խ͕ඞཁͳͨΊ • Linux LVS + KeepalivedΛ࢖༻ (3ํࣜ͋Δ) • LB͕ෳ਺ωοτϫʔΫʹ෼ࢄͰ͖Ε͹Α͍ • LBͷԼ͸جຊతʹಉҰωοτϫʔΫ • L4ɺL7ͷLB͸ऴ୺͢Δ͜ͱͰผωοτϫʔΫՄ • ͨͩ͠ऴ୺͢ΔͷͰ஗͘ͳΓ͕ͪ

Slide 52

Slide 52 text

LVSΛ࢖ͬͨϩʔυόϥϯα(NAT)   • ໭Γύέοτ͕ूத͢Δ • ࡹ͚ΔίωΫγϣϯ਺͕গͳ͍ • IPϔομΛॻ͖׵͑ΔͷͰ஗͍ => ͸ͯͳͷ༻్ʹ͸߹Θͳ͍     ୯Ұ*1 7*1 ෳ਺*1 3*1 

Slide 53

Slide 53 text

LVSΛ࢖ͬͨϩʔυόϥϯα(DR) • ໭Γύέοτ͕ूத͠ͳ͍ • ࡹ͚ΔίωΫγϣϯ਺͕ଟ͍ • IPϔομΛॻ͖׵͑ͳ͍ͷͰߴ଎ => Proxy޲͖      "31Ͱղܾͯ͠.BDΞυϨεͷॻ͖׵͑ͷΈ  

Slide 54

Slide 54 text

LVSΛ࢖ͬͨϩʔυόϥϯα(TUN) • Ϩεϙϯεύέοτ͕ूத͠ͳ͍ͷ͸DRͱಉ͡ • IPϔομΛΧϓηϧԽ͢ΔͷͰผωοτϫʔΫʹసૹՄೳ • ϦΫΤετύέοτͷMSS͕Լ͕Δ => ProxyҎ֎޲͖  c c   ୯Ұ*1 7*1 *1JO*1  

Slide 55

Slide 55 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ

Slide 56

Slide 56 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ -PBE#BMBODFSɹ /FUXPSL /FUXPSL /FUXPSL /FUXPSL /FUXPSL /FUXPSL

Slide 57

Slide 57 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ1SPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ"QQ -PBE#BMBODFSɹ%#

Slide 58

Slide 58 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ1SPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹ"QQ -PBE#BMBODFSɹ%# /FUXPSL /FUXPSL /FUXPSL

Slide 59

Slide 59 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPSQSPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPS"QQ %# ʜ $BDIF $BDIF $BDIF

Slide 60

Slide 60 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPSQSPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPS"QQ %# ʜ $BDIF $BDIF $BDIF /FUXPSL /FUXPSL

Slide 61

Slide 61 text

4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPSQSPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPS"QQ %# ʜ $BDIF $BDIF $BDIF /FUXPSL /FUXPSL /FUXPSL

Slide 62

Slide 62 text

4FSWFS 4FSWFS 4FSWFS 4FSWJDF" 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPSQSPYZ 4FSWJDF# 1SPYZ "QQ %# 1SPYZ 1SPYZ "QQ "QQ %# %# -PBE#BMBODFSɹGPS"QQ %# ʜ $BDIF $BDIF $BDIF

Slide 63

Slide 63 text

͸ͯͳͷϩʔυόϥϯαํࣜͷબ୒ • جຊ͸LVS/TUNΛ࢖༻͢Δ • ෺ཧαʔόɺωοτϫʔΫʹґଘͤͣ഑ஔ • Proxyͷલஈʹ͸LVS/DRΛ࢖༻͢Δ • ࡹ͘ίωΫγϣϯ਺͕ଟ͍ • άϩʔόϧIPΞυϨεΛѻ͏ • ϦΫΤεταΠζ << ϨεϙϯεαΠζ ͕جຊ

Slide 64

Slide 64 text

ج൫ٕज़ͷબ୒ • ͸ͯͳͷϋ΢δϯά؀ڥͷෛՙ෼ࢄͷҰ෦Λ঺հ • ৽ٕज़Ͱ͸ͳ͍͕͔ͬ͠Γࢧ͍͑ͯΔ • ౰વෆຬ΋͋ΔͷͰ׬੒ܗͰ͸ͳ͍ • ඞཁͳཁ݅,Πϯϑϥࣄ৘͸֤ࣾҟͳΔ • पΓ΍ྲྀߦΓʹৼΓճ͞Ε͗͢ͳ͍ • దࡐదॴɺແཧ͗͢͠ͳ͍બ୒Λ৺͕͚Δ

Slide 65

Slide 65 text

ج൫Λ΍Δָ͠͞

Slide 66

Slide 66 text

ج൫Λ΍Δָ͠͞ • େن໛ͳγεςϜΛߟ͑Δָ͠͞ • جૅతͳٕज़͕ษڧͰ͖Δ • OS,ωοτϫʔΫ,෼ࢄγεςϜ,... • Ϋϥ΢υͷத਎΍࣮૷͕૝૾ग़དྷͨΓ͢Δ • టष͞΋͋Δ • ݕূ΍όά౿ΜͩΓͱ͔…

Slide 67

Slide 67 text

ྫ͑͹…

Slide 68

Slide 68 text

Linuxϧʔλ • ͸ͯͳͰ͸ήʔτ΢ΣΠͳͲʹVyOSΛ࢖͍ͬͯΔ • సૹ͚ͩͳΒ200Kpps 10Gbps ग़Δ • ςΩετϕʔεͷWebαʔϏεͳΒे෼ • OSSͳͲ͕ͦͷ··࢖͑Δ • Chef, GitͳͲͷߏ੒؅ཧπʔϧ • MackerelͰ؂ࢹ͢Ε͹SNMP͍Βͣ

Slide 69

Slide 69 text

LinuxωοτϫʔΫ %PN /*$ 1IZTJDBM -JOVY #SJEHF 9FO)ZQFSWJTPS 7. FUI WJG FUI /*$ 1IZTJDBM -JOVY #SJEHF 7. WJG FUI

Slide 70

Slide 70 text

LinuxωοτϫʔΫͷߴ଎Խ • ݱঢ়͸VMؒͩͱ3~4Gpbsఔ౓ • ΦϑϩʔσΟϯά (VMؒͰ10GbpsՄೳ) • TSO (TCP Segmentation Offload), • LRO (Large Receive Offload) • SR-IOV • AWSͰ΋࢖༻Ͱ͖Δ

Slide 71

Slide 71 text

XenϋΠύʔόΠβʔͱNUMA %PN 1IZTJDBM %PN6 9FO)ZQFSWJTPS .FN$POUSPMMFS .FN$POUSPMMFS σʔλ $16 $16 %PN6 %PN6 σʔλ σʔλ

Slide 72

Slide 72 text

Placing the guest automatically xen 4.5 %PN 1IZTJDBM %PN6 9FO)ZQFSWJTPS .FN$POUSPMMFS .FN$POUSPMMFS σʔλ $16 $16 %PN6 %PN6 σʔλ σʔλ

Slide 73

Slide 73 text

ͦͷଞͷ͸ͯͳͷج൫ͷ͓࿩ • ͸ͯͳͷϩάӡ༻ ͜Ε·Ͱͱ͜Ε͔Β • https://speakerdeck.com/tatsuru/hatena-engineer-seminar-number-6 • ͸ͯͳʹ͓͚ΔLinuxωοτϫʔΫελοΫύϑΥʔϚϯεվળ • https://speakerdeck.com/yuukit/linux-network-performance-improvement- at-hatena • Ծ૝Խج൫ͷϦιʔε࠷దԽ • https://speakerdeck.com/taketo957/resource-optimization-on-virtualization-platform • ෛՙ෼ࢄٕज़ΛબͿͱ͖ʹߟ͑Δ͜ͱ • https://speakerdeck.com/masayoshi/fu-he-fen-san-ji-shu-woxuan-butokinikao-erukoto-1

Slide 74

Slide 74 text

΋ͬͱฉ͖͍ͨʂͱ͍͏ਓ͸… • Mackerelϒʔε΁ Εͬͭ͝ʔ

Slide 75

Slide 75 text

΋ͬͱ΋ͬͱ஌Γ͍ͨʂͱ͍͏ਓ͸…

Slide 76

Slide 76 text

Πϯϑϥ͕޷͖ͳਓ ج൫͕޷͖ͳਓ΁ ઈࢍ࠾༻ڧԽதʂ IUUQIBUFOBDPSQKQSFDSVJUGSFTIPQFSBUJPOFOHJOFFS