ã¯ã©ãŠããã€ãã£ãåéã®ãã€ã¯ããµãŒãã¹ã Kubernetesãªã©ã«ã€ããŠæžãããšã奜ããšããäºå®ã«ãããããããç§ãã¡ã¯å¥ã®äžçãããç¥ã£ãŠããŸããããšãã°ããªã³ã©ã€ã³ã¹ãã¢ïŒéåžžã«æåãããã®ã§ãïŒãããŸãšããŠãèŠãã°ãããçŸå®çã§ãã èªåããããžã§ãã³ã°ãšã¹ã±ãŒãªã³ã°ãè€éãªè² è·åæ£ããã®ä»ã®çŸããæè¡ãœãªã¥ãŒã·ã§ã³ã¯ãããŸããã ãããããã§ã«ææ¥ã§ããããã©ãã¯ãã©ã€ããŒãããããŸããã€ãŸããæºåã®æéã¯ã»ãšãã©ãããŸããã ãã¡ãããå質ã®æºåã®ããã®ç§ãã¡ã®ã¬ã·ãNo. 1ïŒãããŠåæã«å€ãã®è¿œå ã®å©ç¹ãåŸãããïŒã¯ããã€ã¯ããµãŒãã¹ã¢ãŒããã¯ãã£ãšKubernetesãžã®ç§»è¡ã§ãããäœããã®çç±ã§ãã®ãªãã·ã§ã³ãæ©èœããªããšä»®å®ããŸãïŒææ¥ãŸã§ã¯ãŸã å®è£ ãããŸããïŒ ïŒ
ãã®èšäºã¯ãé«è² è·ã«åããŠãªã³ã©ã€ã³ã¹ãã¢ã®å žåçãªã€ã³ãã©ã¹ãã©ã¯ãã£ïŒnginxãApacheãPHPãMySQLã®äŸãæ€èšïŒãæé©åããããã®å€ããå°ãªããè¿ éãªæé ã®ãªã¹ãã§ãã ãããã¯çµéšè±å¯ãªã·ã¹ãã 管çè ã«ã¯éåžžã«æçœã§ããããããã®åé¡ã«ãŸã æ·±ãçªå ¥ããŠããªã人ã«ãšã£ãŠã¯ç¢ºãã«æçšã§ããããã®é¢é£æ§ã¯æ¥éã«é«ãŸã£ãŠããŸãã ãã®ãããã€ã³ãã©ã¹ãã©ã¯ãã£ã«ãããã®ãæ倧éã«æŽ»çšããããå°ãªããšã次ã®è² è·ãéäžããåã«å¯ŸåŠããå¿ èŠãããäž»èŠãªåé¡ã«æ³šæããŠãã ããã
1.ã€ã³ãã©ã¹ãã©ã¯ãã£ãç Žå£ããç£èŠãèšå®ãã
åºæ¬çãªè² è·ã€ã³ãžã±ãŒã¿ ïŒCPUãã¡ã¢ãªããã£ã¹ã¯I / Oãã€ã³ã¿ãŒããããã£ãã«å æçãªã©ïŒã远跡ããæ段ããªããã°ãæé©åã¢ã¯ã·ã§ã³ã¯ã»ãšãã©ãç²ç®çã«ãå®è¡ãããŸãã
äž»èŠãªãµãŒãã¹ïŒWebãµãŒããŒãDBMSãè£å©ãµãŒãã¹ïŒãåå¥ã®ãµãŒããŒ/ä»®æ³ãã·ã³ã«åå²ãããŠããªãå Žåãã€ã³ãã©ã¹ãã©ã¯ãã£å šäœã1ã€ã®èãé£ãã¢ããªã¹ã§ãããšæãããå Žåã察å¿ããåç·šæããéå§ããå¿ èŠããããŸãã ããã«ãããåéãããçµ±èšãããèŠèŠçãã€æçšã«ãªããŸããç°ãªãä»®æ³ãã·ã³ã®ã¡ã€ã³ã°ã©ããåãæ¿ãããšãã©ã®ã€ã³ãã©ã¹ãã©ã¯ãã£ã³ã³ããŒãã³ãã«ããã»ããµãŸãã¯ã¡ã¢ãªãäžè¶³ããŠããããæããã«ãªããŸãã
泚 ïŒãã®ãããªåºå¥ã®è¿œå ã®å©ç¹ã®äŸã¯ãDBMSã®ãªãœãŒã¹ã䜿ãæãããããšããµã€ãã«å®å šã«ã¢ã¯ã»ã¹ã§ããªããªãããš ïŒWebãµãŒããŒããŸã£ããå¿çããªãå ŽåïŒã§ã¯ãªããæ å ±ãšã©ãŒïŒãŸãã¯æå°éã®æ©èœã¹ã¿ã-詳现ã«ã€ããŠã¯ä»¥äžãåç §ïŒã«ã€ãªããããšã§ãã ãã ãããããè¡ãã«ã¯ãã¢ããªã±ãŒã·ã§ã³/ WebãµãŒããŒãšDBMSãšã®çžäºäœçšãæ£ããæ§æããå¿ èŠããããŸããDBMSãžã®æ¥ç¶ãšããŒã¿ã®åä¿¡ãé·ãããŠã¯ãããŸããã ããããªããšãWebãµãŒããŒã®ïŒäºæ³ãããïŒå€ãã®ããã³ã°ãããã»ã¹ãçºçãïŒå Žåã«ãã£ãŠã¯ããã®ããã»ã¹ã®æ倧æ°ãè¶ ããŠïŒã察å¿ãããµãŒããŒ/ VMã®ãªãœãŒã¹ãè©°ãŸããŸãã
ããã¯ã©ã®ããã«è§£æ±ºãããŸããïŒ
æãåçŽãªã±ãŒã¹ã§ã¯ãApacheãPHPãMySQLã®å Žåã
劥åœãªå€ãéžæããå¿ èŠããããŸããããã¯ãåæWebãµãŒããŒããã»ã¹+åŒã³åºãã®ä»ã®ãœãŒã¹ïŒcronã¹ã¯ãªããïŒã®æ倧å¯èœæ°ã«è¿ãå€ã§ãã ãã®å€ãå°ãããããšãDBMSãžã®èŠæ±ã®ãªããªãœãŒã¹èŠæ±ãå®è¡ãããªããªããå€ããããšRAMãäžæçã«çµäºããå¯èœæ§ããããŸãã äžéšã§ã¯ãäŒèª¬çãªmysqltuner.plã¹ã¯ãªããã䜿çšãããšåœ¹ç«ã¡ãŸã ã
ããã«ãããã³ã°ãããã»ã¹ã«å¯ŸåŠããã«ã¯ãPHPã®
ãã£ã¬ã¯ãã£ãïŒ
ïŒããã³MySQLã®
ã·ã¹ãã å€æ°ã«æ³šæããå¿ èŠããããŸãã ãã¡ããããµãŒãã¹ã§ã¿ã€ã ã¢ãŠããèšå®ããããšã«å ããŠãããããããªã¬ãŒãããå Žåã«æ£ããã¹ã¿ãã衚瀺ãããããä»ã®ã¢ã¯ã·ã§ã³ãå®è¡ãããããã«ãã¢ããªã±ãŒã·ã§ã³ã«ããæ£ããåŠçãæäŸããå¿ èŠããããŸãã
max_connections
劥åœãªå€ãéžæããå¿ èŠããããŸããããã¯ãåæWebãµãŒããŒããã»ã¹+åŒã³åºãã®ä»ã®ãœãŒã¹ïŒcronã¹ã¯ãªããïŒã®æ倧å¯èœæ°ã«è¿ãå€ã§ãã ãã®å€ãå°ãããããšãDBMSãžã®èŠæ±ã®ãªããªãœãŒã¹èŠæ±ãå®è¡ãããªããªããå€ããããšRAMãäžæçã«çµäºããå¯èœæ§ããããŸãã äžéšã§ã¯ãäŒèª¬çãªmysqltuner.plã¹ã¯ãªããã䜿çšãããšåœ¹ç«ã¡ãŸã ã
ããã«ãããã³ã°ãããã»ã¹ã«å¯ŸåŠããã«ã¯ãPHPã®
mysql.connect_timeout
ãã£ã¬ã¯ãã£ãïŒ
/etc/php5/apache2/php.ini
ïŒããã³MySQLã®
wait_timeout
ã·ã¹ãã å€æ°ã«æ³šæããå¿ èŠããããŸãã ãã¡ããããµãŒãã¹ã§ã¿ã€ã ã¢ãŠããèšå®ããããšã«å ããŠãããããããªã¬ãŒãããå Žåã«æ£ããã¹ã¿ãã衚瀺ãããããä»ã®ã¢ã¯ã·ã§ã³ãå®è¡ãããããã«ãã¢ããªã±ãŒã·ã§ã³ã«ããæ£ããåŠçãæäŸããå¿ èŠããããŸãã
äž»èŠãªã·ã¹ãã ã€ã³ãžã±ãŒã¿ã®çµ±èšããã³ç£èŠã®ããã®æçœã§æºåã®æŽã£ãïŒå±éãè¿ éã§ãååã«ææžåãããïŒãªãŒãã³ãœãŒã¹ãœãªã¥ãŒã·ã§ã³ïŒå°ãªããšããªãœãŒã¹ã®äžè¶³ã«ã€ããŠè¿ éã«èª¿ã¹ãå¿ èŠãããïŒ -Zabbix ä»ã®ãã¹ãŠã®è£œåãšåæ§ã«ãããã¯çæ³çã§ã¯ãªããå€ãã®éžæè¢ïŒããšãã°ãïŒããããŸããã解決ãããã¿ã¹ã¯ã«å®å šã«é©åããŸãïŒãããŠããããããäºå®äžæšæºãšããŠåŒ·åããããšèšããã§ãããïŒ ã
ãã¡ãããäžè¬çãªã·ã¹ãã ã€ã³ãžã±ãŒã¿ãŒã®ã°ã©ãã«å ããŠãè¯ãæ¹æ³ã§ãããžãã¹ã«ãšã£ãŠããæçãªå€ãæ§æãããšäŸ¿å©ã§ãïŒåŠçãããèŠæ±ã®æ°ããåçã³ã³ãã³ãã泚ææ°ãŸã§ïŒã
å¥ã®æ¹æ³ãšããŠãæ¢è£œã®ãµãŒãã¹ããããŸããããã¯ã€ã³ã¹ããŒã«ãšäœ¿çšãããç°¡åã§äŸ¿å©ã§ãããæéãæ¯æãå¿ èŠããããŸãïŒäŸã¯ãã·ã¢ã§éçºäžã®okmeterã§ãïŒ ã
éžæããã·ã¹ãã ã«ãã£ãŠåéãããäž»èŠãªå€ãç£èŠããã«ã¯ãããŒã¹ãã¢ã®ã¢ã¯ã»ã¹å¯èœæ§ ïŒWebãµãŒããŒã®æ£ããå¿çãšåŠ¥åœãªå¿çæéïŒã®è¿œè·¡ãè¿œå ããŠã販売ãäœäžãããŸã§ãªã³ã©ã€ã³ã¹ãã¢ã®æ©èœã®åé¡ãèŠã€ããããšã圹ç«ã¡ãŸãã åè¿°ã®Zabbixã§ã¯ããã®ãããªæ©èœã¯ãã¡ããæäŸãããŠããŸãã
2.è² è·ã確èªãã
ç£èŠããã³çµ±èšã·ã¹ãã ã®å®è£ ã®è«ççãªçµæã¯ããã®ãæŠéãã§ãã¯ããã€ãŸã ã¹ãã¬ã¹ãã¹ãã ãããã®ç®çã®ããã«ãå€ãã®ãªãŒãã³ãœãŒã¹ããŒã«ããããŸãïŒå€å žçã§æãåçŽãªabããApache JMeterã®ãããªããè€éãªãœãªã¥ãŒã·ã§ã³ãŸã§ïŒãããã®ããã€ãã®ç°¡åãªæŠèŠã§ã ïŒ ã æãç°¡åã§è¿ éãªãã¹ãã®ããã«ãåè¿°ã®abãŠãŒãã£ãªãã£ã«é Œãããšãã§ããŸããããæ®éçã§å æ¬çãªããŒã«ãšããŠããã·ã¢ã®éçº-Yandex.Tankããå§ãããŸãïŒäœæè ã®äœ¿çšäŸãåç §ïŒ ã
çæ³çã«ã¯ããªã³ã©ã€ã³ã¹ãã¢ããžãã¹ã«ãšã£ãŠæ¬åœã«éèŠãªãã¹ãŠã®ãã®ããã¹ãããå¿ èŠããããŸããã¡ã€ã³ããŒãžãã«ã¿ãã°ã»ã¯ã·ã§ã³ã補åã®è¡šç€ºã泚æïŒãŠãŒã¶ãŒç»é²ããïŒãªã©ã§ãã åäžã®ããŒãžïŒããšãã°ãã¡ã€ã³ããŒãžïŒããã¹ããããšãã°ããŒãã«ãªåé¡ïŒäžè¬çã«äœ¿çšãããSQLã¯ãšãªããŸãã¯åçãªããŒãžã¬ã³ããªã³ã°ãååçã«æ©èœããªããªãã»ã©è² è·ãé«ããšããäºå®ïŒãç¹å®ããã®ã«åœ¹ç«ã¡ãŸãããSQLã¯ãšãªã«é¢é£ããããé »ç¹ãªåé¡ãé衚瀺ã«ããŸãç¹å®ã®ããŒãã«ïŒãŸãã¯ç¹å®ã®èŠæ±ã®ã¿ïŒãã³ãŒãã§è¿œå ã®ã¡ã«ããºã ãšãµãŒãã¹ã䜿çšããïŒããšãã°ããŠãŒã¶ãŒãžã®é»åã¡ãŒã«ã®éä¿¡ããµãŒãããŒãã£ã®ãµãŒãã¹/ãã£ãã·ã¥ããã®ããŒã¿ã®åä¿¡ãªã©ïŒ
åã®æ®µéã§æ§æãããçµ±èš/ç£èŠã·ã¹ãã ã¯ãè² è·ãã¹ãã®å®è¡ã«ã圹ç«ã¡ãŸãã ãªãœãŒã¹æ¶è²»ã®ã°ã©ããèŠãŠïŒãããŠãããã®ããŒã¿ã«åºã¥ããŠãæ倧ãã©ãã£ãã¯ã®ã€ã³ãã©ã¹ãã©ã¯ãã£ã®å¯èœæ§ãè©äŸ¡ããïŒãç¶æ³ãé倧ã«ãªã£ããšãã«ç£èŠãããªã¬ãŒãããããšã確èªã§ããŸãã
次ã®æé ã®é¢é£æ§ã¯ãã¹ãã¬ã¹ãã¹ãã®çµæã«å€§ããäŸåããŸãã
3.éååŠã«å¯ŸåŠãã
çªç¶ãã¹ãŠã®ãªã¯ãšã¹ããæ¡ä»¶ä»ãApacheã«ãã£ãŠåŠçãããå ŽåïŒå®éã«ã¯ãããå®éã«çºçããããšã瀺ããŠããŸãïŒã軜éã®WebãµãŒããŒãïŒããã³ããšã³ããšããŠïŒè¿œå ããŸã-ããšãã°ããã¡ããnginx-éçã³ã³ãã³ãïŒç»åãJSã CSSããã©ã³ããã¡ã€ã«ãåç»ãªã©ïŒã
ãã¹ãŠããã§ã«èšå®ãããŠãããšæãããå Žåã§ããã¢ããªã±ãŒã·ã§ã³WebãµãŒããŒïŒApacheïŒã®ã¢ã¯ã»ã¹ãã°ã衚瀺ããŠç¢ºèªããŠãã ããã ååãšããŠãæåããã¹ããŒã¿ã¹ïŒ404ã§ã¯ãªãïŒã®GETãªã¯ãšã¹ããéžæããåçã³ã³ãã³ãïŒããšãã°ã
/
ãŸãã¯
.html
ã§çµããããŸãã¯æåŸã§ãªãïŒã§åä¿¡ããURLãé®æãã
grep
ãŸãã¯
egrep
ã䜿çšããç°¡åãªæ§æãååã«ãããŸã-
\.[^.]{2,4}
ãããªãã®ïŒã å€ãã®å Žåã ãã¹ãŠã®nginxããã¹ãŠã®staticã解æŸããããã§ã¯ãããŸãããããããã¯Apacheã®çµ¶ããå®è¡ãããŠããããã»ã¹ïŒ
MaxClients
å¶éã«è¿ã¥ããŠããïŒãšæ¶è²»ãããè¿œå ãªãœãŒã¹ã§ãã
çµ±èšã®ãã1ã€ã®ãã¥ã¢ã³ã¹ã¯ããµã€ãã®ã€ã³ã¿ãŒããããã£ãã«ã®èŠæš¡ã§ã®ããªã¥ãŒã ã§ãã ãã®ææšã¯ãçµ±èšïŒãããã¯ãŒã¯ãã©ãã£ãã¯ã®ã°ã©ãïŒã®ããŒã¿ã䜿çšããŠç¢ºèªãããŸãã æ¢åã®ãã£ãã«ã®äºæ³ãããïŒé«ãïŒè² è·ã§ãã¹ãŠã®çµ±èšãè¿ãã®ã«ååã§ããå Žåã§ããå°ãªããšããªã³ã©ã€ã³ã¹ãã¢ã®ããŒããŒãžã§ç»åãã¡ã€ã«ãæé©åããJS / CSSãã¡ã€ã«ãæå°åããããšããå§ãããŸã ã Google PageSpeed Insightsã¯ããããã®åé¡ããã®ä»ã®ãã¯ã©ã€ã¢ã³ããåé¡ã®æ€åº/確èªã«åœ¹ç«ã¡ãŸãã
倧éã®ãã©ãã£ãã¯ãçºçãããã£ãã«ãæ¡åŒµã§ããªãå ŽåïŒãŸãã¯é¢åã§é«äŸ¡ãªå ŽåïŒãCDNãå°å ¥ãããªãã·ã§ã³ãæ€èšãã䟡å€ããããŸãã
4.ããã«ããã¯ãèŠã€ãã
Webã¢ããªã±ãŒã·ã§ã³èªäœã®æäœã«ãããåé¡é åã«å¯ŸåŠããæéã ããã§ã®ç°¡åãªæ¹æ³ã¯ã New Relicã«ãã©ã€ã¢ã«ã¢ã«ãŠã³ããç»é²ãïŒ2é±éç¡æã§çºè¡ïŒãWebãµãŒããŒåŽã«ãšãŒãžã§ã³ãéšåãã€ã³ã¹ããŒã«ããè² è·ããŒã¿ã®åæåéïŒãã®ããã»ã¹ã¯è² è·ãã¹ããå®è¡ããããšã§å éã§ããŸãã ïŒããã³ãã®åæã
æãé ããã©ã³ã¶ã¯ã·ã§ã³ïŒç¹ã«æãäžè¬çãªãã©ã³ã¶ã¯ã·ã§ã³ïŒã«æ³šæããŠãã ããã
ãããã®äžã§å ·äœçã«é ããªããã®ã¯äœã§ããïŒä»ã®éšåãããã¯ããã«æéãããããŸãïŒïŒ ããããç¹å®ã®ã³ãŒãã§ããå Žåãã©ã®ããã«æé©åã§ããŸããïŒ SQLã¯ãšãªã®å ŽåãDBMSã䜿çšããŸãïŒæ®µèœ6ãåç §ïŒ ã å€éšãµãŒãã¹ã®å Žå-䜿çšãæå°éã«æããå¯èœãªå Žåã¯çµæããã£ãã·ã¥ããŸãïŒã¢ããªã±ãŒã·ã§ã³ã³ãŒãã§ãŠãŒã¶ãŒãªã¯ãšã¹ããçŽæ¥äœ¿çšãããããµãŒãã¹ããå¿ èŠãªããŒã¿ãå®æçã«åä¿¡ããŠããŒã«ã«ã«ä¿åããè¿œå ã¹ã¯ãªããã䜿çšããŠcronãåŒã³åºããŸãïŒã
5. WebãµãŒããŒãæé©åãã
PHPã®ã¢ã¯ã»ã©ã¬ãŒã¿ãªã©ã®è£å©ããŒã«ã¯ãã³ãŒãã®å šäœçãªããã©ãŒãã³ã¹ãåäžãããããšãã§ããŸãããã®ååã¯ãã¢ããªã±ãŒã·ã§ã³ã®å®è¡å¯èœãã¡ã€ã«ã®ã³ã³ãã€ã«æžã¿ã³ãŒãïŒãªãã³ãŒã/ãã€ãã³ãŒãïŒããã£ãã·ã¥ããããšã§ãã å€ãPHPïŒ5.xïŒã®å Žåã APCã¯ãŸã é¢ä¿ãããïŒå ¬åŒã«ã¯ããããããšèªèãããŠããŸããïŒãããæ°ããããŒãžã§ã³ïŒ7.xïŒã®å Žåã¯çµã¿èŸŒã¿ã®Zend OPcacheãèšå®ããå¿ èŠããããŸãã
PHPã®å Žåã®ã°ããŒãã«æé©åã®ãã1ã€ã®é åã¯ã ã»ãã·ã§ã³ã§ãã ããã§ããå€ãã¯æšæºèšå®
session.save_handler = files
䜿çšããŸããã€ãŸããã»ãã·ã§ã³ããã¡ã€ã«ã«ä¿åããŸãã å€æ°ã®ãµã€ã蚪åè ïŒã»ãã·ã§ã³ãšãã¡ã€ã«ã®äž¡æ¹ãæå³ããŸãïŒã䜿çšãããšããã£ã¹ã¯ã«äžåçãªè² è·ãããããŸããããã¯ãmemcachedãªã©ã®NoSQLã¹ãã¬ãŒãžã«åãæ¿ããããšã§å¥è·¡çã«åé€ããããã¹ãŠã®ã»ãã·ã§ã³ãRAMã«é 眮ãããŸãã
WebãµãŒããŒã®åäœãæé©åããæãæ ¹æ¬çãªæ¹æ³ã¯ãããã°ã©ãã³ã°èšèªã®ã€ã³ã¿ãŒããªã¿ãŒã«ãã£ãŠçæãããããŒãžãnåã«1åãã£ãã·ã¥ããããšã§ãã ãã®æ©èœã¯ã次ã®ãããªããŒãžã«é¢é£ããŸãã1ïŒå°ãªããšããã°ããã¯å€æŽã§ããŸããïŒããšãã°ããã©ã³ãã ãªååãã®ãããã¯ã¯ããã¹ãŠã®ãŠãŒã¶ãŒã«å¯ŸããŠ1ã2åéã«1åãšã³ãžã³ã«ãã£ãŠçæãããŸãïŒã2ïŒãã¹ãŠã«å¯ŸããŠåãã§ããŠãŒã¶ãŒã 2çªç®ã®æ¡ä»¶ã¯ãèªèšŒããããŠãŒã¶ãŒãåã«é€å€ããããã«ãã£ãã·ã¥ãæ§æã§ãããšããæå³ã§ããã»ã©éèŠã§ã¯ãããŸããã ãã®å Žåãå®æããïŒãã£ãã·ã¥ãããïŒããŒãžããã¹ãŠã®èšªåè ã«è¡šç€ºãããŸã-ãã²ã¹ããïŒããã«ãã»ãšãã©ã®å Žåãéåžžã¯å§åçã§ãïŒãèªèšŒãããããŒãžã®å ŽåããåçãããŒãžãçæãããŸãã ãã£ãã·ã¥ã¯nginxã§èšå®ã§ããŸããããããã®ããŒãºã«ããç¹åãããªãŒãã³ãœãŒã¹ãœãªã¥ãŒã·ã§ã³ã§ããVarnish HTTP CacheããããŸãã
Webãµã€ãäžã®ããŒãžã®ã¡ã€ã³ã°ã«ãŒãã®ãã£ãã·ã¥ãé©åã«æ§æãããšããªã¯ãšã¹ãã®äž»èŠãªéšåã«å¯ŸããçããéçïŒWebãµãŒããŒïŒããã°ã©ãã³ã°èšèªã®ã€ã³ã¿ãŒããªã¿ãŒã䜿çšïŒããã³DBMSïŒã䜿çšããã«RAMããããŒã¿ãçºè¡ããããšã«ãªããããçŽ æŽãããçµæãåŸãããããšããããããŸãã ãã£ãã·ã³ã°ãµãŒããŒãã»ããã¢ããããåŸãè² è·ãã¹ãã®å©ããåããŠããã確èªããŸããããªã³ã©ã€ã³ã¹ãã¢ã®éèŠãªæ©èœïŒãã¹ã±ãããžã®è£œåã®è¿œå ããã®åŸã®æ³šæããŠãŒã¶ãŒç»é²ãªã©ïŒãäžæããªãããã«ããã£ãã·ã³ã°æ¡ä»¶ã®æºåã«ç¹ã«æ³šæããŠãã ããã
6. DBMSãæé©åãã
DBMSã®ããã©ãŒãã³ã¹ã®æé©åã¯ã2ã€ã®éšåã«åããããšãã§ããŸãã1ïŒDBMSèªäœã®äžè¬çãªæ§æã2ïŒç¬èªã®ã¹ããŒããšã¯ãšãªã§ã®äœæ¥ã
æåã®é ç®ã«ã¯ãDBMSã§ã®ãããã¡ããã³ãã®ä»ã®ã°ããŒãã«ãã©ã¡ãŒã¿ã®èšå®ãå«ãŸããŸã ã MySQLã«ãšã£ãŠæãéèŠãªãã®ã¯ãPeter Zaitsev ïŒCEO PerconaïŒã®ãã¬ãŒã³ããŒã·ã§ã³ããã®ãã®çŽ æŽãããã¹ã©ã€ãã§èŠãããšãã§ããŸãã
ãããã®ã·ã¹ãã å€æ°ããã³ãã®ä»ã®ããã€ãã®è©³çŽ°ãªåæïŒMySQL / MariaDBã®ããã©ãŒãã³ã¹ã®åé¡ã«ãšã£ãŠéèŠïŒã¯ãããšãã°MariaDBã®ãã®ããŒãã«èšèŒãããŠããŸãã
2çªç®ã®é åã§ããããŒã¿ããŒã¹ã¹ããŒããšäœ¿çšãããSQLã¯ãšãªã¯ãéåžžãã¹ããŒã¯ãšãª ïŒMySQLã®ã¹ããŒã¯ãšãªãã° ïŒãŸãã¯åè¿°ã®New Relicãªã©ã®ããã©ãŒãã³ã¹ã®åé¡ãæ€åºããããã®å°çšããŒã«ã®åæããå§ãŸããŸã ã åé¡ã®å€§éšåã¯ãååãšããŠãSQLã¯ãšãªã®æ£ããã€ã³ããã¯ã¹ãšææ ®æ·±ãåæïŒãã®åŸã®æé©åãŸãã¯ã¹ããŒãã®å€æŽãå«ãïŒãè¿œå ããããšã§è§£æ±ºãããŸãã
DBMSããæãåºãã®ã«ãŸã æéããããããŒã¿ããã°ããååŸããããã®è¿œå ã®ãœãªã¥ãŒã·ã§ã³ã¯ãNoSQLã¹ãã¬ãŒãžãªã©ã®é »ç¹ãª/è€éãªæäœã®çµæããã£ãã·ã¥ããããšã§ã ã ä»ã®å Žåãšåæ§ã«ããã£ãã·ã¥å ã®ããŒã¿ã®é¢é£æ§ãç£èŠããããšãå¿ããŠã¯ãªããŸããã
7.ãšã³ãžã³ãæé©åãã
ãªã³ã©ã€ã³ã¹ãã¢ãäžè¬çãªãã¬ãŒã ã¯ãŒã¯ãŸãã¯ãšã³ãžã³ã䜿çšããŠããå Žåãããã¯ã補é å ãŸãã¯ãŠãŒã¶ãŒ/ããã¢ã®ã³ãã¥ããã£ãšããã¥ã¡ã³ããæã£ãŠããããšãæå³ããããšã«æ³šæããŠãã ããã ãœãªã¥ãŒã·ã§ã³ãæé©åããããã®ãªã³ã©ã€ã³ãã¹ããã©ã¯ãã£ã¹ãèŠã€ããŠãå¯èœãªéãå®è£ ããŸãã ãã®ãããªãã©ã¯ãã£ã¹ã§ææ¡ããããã³ãã¯ãéåžžããšã³ãžã³/ã¢ããªã±ãŒã·ã§ã³ã®èª¿æŽãæ¢æã®ããŒã«ïŒããã©ãŒãã³ã¹ããã«ããã©ã°ã€ã³ã®æé©åãªã©ïŒã®äœ¿çšããã€ã³ãã©ã¹ãã©ã¯ãã£ã®å€æŽãŸã§ãããŸããŸãªåéãã«ããŒããŠããŸãã
ãšã³ãžã³ããµãŒããŒãŸãã¯DBMSã«é¡èãªè² è·ãããã2次æ©èœã䜿çšããŠããå Žåã¯ãããŒã¯æã«ãªãã«ããŸãããŠãŒã¶ãŒãäœãååŸããªãã§ãããã€ãã®æ©èœãååŸã§ããããã«ããŸãã
8.ã¢ã€ãã³ãæŽæ°ãã
çµ±èšã·ã¹ãã ã®ããŒã¿ãè² è·ãã¹ãã®çµæãç¶ç¶çãªæé©åïŒããšãã°ãDBMSã®åé¡ãåæããåŸã巚倧ãªãããã¡ãŒãå¿ èŠã§ããããšãå€æããŸããïŒ-ãªãœãŒã¹ã®è¿œå ïŒCPUã³ã¢ã®æ°ãšRAMã®éãå¢ããããã£ã¹ã¯éäžåããŒãã£ã·ã§ã³ïŒDBMSïŒãå€æããŸãïŒSSDã§ãåã ã®ã³ã³ããŒãã³ããåå¥ã®ãµãŒããŒ/ä»®æ³ãã·ã³ã«ç§»åãããã£ãã«ãæ¡åŒµããŸãïŒåé¡ã¯éçãªãã®ã ãã§ã¯ãªããããCDNãé«äŸ¡ãªå Žåã圹ã«ç«ããªãå ŽåïŒã
9.æèœãªã¹ã¿ããäœæãã
ä»ã®ãã¹ãŠã倱æããå ŽåïŒãã¹ãŠã®æé©åãå®äºããªãã£ãããŸãã¯ååã§ã¯ãªãã£ããååãªããŒããŠã§ã¢ã¢ããã°ã¬ãŒããªãã·ã§ã³ããªãããã©ãã£ãã¯ã®éã劥åœãªäºæ³ãè¶ ããïŒ-åºæ¬çãªè£œåãé£çµ¡å ã®è©³çŽ°ãå«ãæçãªãã©ã°ã€ã³ããŠãŒã¶ãŒã«è¡šç€ºããããŒã¿ãªã© WebãµãŒããŒã®èšå®ã«æžã蟌ã¿ãå Žåã«ãã£ãŠã¯ãã¢ããªã±ãŒã·ã§ã³ã§ã®åŸ©åž°ãæäŸããŸãïŒã¿ã€ã ã¢ãŠãããã®ä»ã®åé¡ã®å ŽåïŒã
ãã¡ãããããã¯ãéçãšããŠè¡šç€ºãããå¯èœæ§ã®ããèªèšŒãããŠããªããŠãŒã¶ãŒã®ãã£ãã·ã¥ããŒãžãããã¯ããã«æªãã§ãããæ¥ç¶ã§ããªãããšãå€ãã®äººãžã®æ²ããããªãã¿ã®ãšã©ãŒã«é¢ãããã©ãŠã¶ã¡ãã»ãŒãžãããã¯ããã«åªããŠããŸãïŒ
10.å°é家ã«é»è©±ãã
ããããã¹ãŠãäœããã®çç±ã§å®æ§çã«å®è£ ã§ããªãå ŽåïŒãŸãã¯åžæã©ããã«åœ¹ã«ç«ããªãå ŽåïŒãåé¡ã®æè¡çãªåŽé¢ãè¶ ããæ©äŒãå¿ããªãã§ãã ãã-å¿ èŠãªäºé ã«ã€ããŠããæèœãªäººïŒå人/ç¥äººãŸãã¯é¢é£åéã«ç¹åããäŒæ¥ã ããã¯ãããå¹æçãªããžãã¹ãœãªã¥ãŒã·ã§ã³ã«ãªãå ŽåããããŸãã
ãŸãšã
ããã€ãã®ç¹å®ã®æè¡çæ瀺ããããŸããããã®èšäºã¯æŠèŠã§ããããã©ãã¯ãã©ã€ããŒãšåæ§ã®ã€ãã³ãã ã¡ãªã¿ã«ãç¹å®ãããåé¡ã®ããã€ãã«ã€ããŠã¯ã RIT ++ 2017ã®äžéšãšããŠéå¬ãããHighload Junior 2017äŒè°ã§è©³çŽ°ã«è©±ããŸããïŒAndrei PolovovãšAndrei Kolashtovã«ããã ã€ã³ãã©ã¹ãã©ã¯ãã£ã®é«è² è·ã劚ããããããšã©ãŒ ããå ±åïŒã
ãããã®ãã³ãã®å°ãªããšãäžéšããä»åŸã®ãã¹ãã«åæ Œããã®ã«åœ¹ç«ã€ããšãé¡ã£ãŠããŸãã 人æ°ã®ããç¥æµãèšãããã«ããåãã£ãŠèŠåãããŠãããã ãŸããå¥ã®ç¥æµã§ã¯ããå€ã«ãããæºåãããããšãæšå¥šããŠããŸããä»é±ã®éææ¥ã§ãªããã°ãæ£æãšã¯ãªã¹ãã¹ã»ãŒã«ã®æéäžãééããªãé©åã«æºåããæéããšãããšãã§ããŸãã
ããªãã¯ææ¥ãåŸ ã¡ãŸãïŒ ãã¹ãŠã®ããªãã«æé«ãè¯ã販売ïŒ
PS
ããã°ãã芧ãã ããã
- ã 2018幎ã¯ãŒã«ãã«ããã®é«è² è· ãã