#isucon 4 ã«ååå ãã¦ã©ããã¼ãã³ãã§å¤±æ ¼ã«ãªã£ã¦ãã¾ãã
ãªãã§åè² ï¼ï¼ï¼ã£ã¦çãä¸ãã£ã¡ãããã§ããããã
ã¯ããä¹ã«ã¬ã¼æ§ã§ããããã®ã§ãã
ISUCON4ã«ååæ¦ãã¦ãã¾ããï¼
ISUCONæ¯åã¿ã¦ã¦é¢ç½ããã ãªã¼ã¨æã£ã¦ãããã§ãããªãã¨ãªãæ°ãå¼ãããäºå®ãåããªãã£ããã§åºãã¦ãªãã£ãã®ã§ãããä¼ç¤¾ã§TOTECã«åå ãã¦6ä½ã«ãªã£ãããã¦ã¡ãã£ã¨æããã£ããé¢ç½ãã£ãããã¦ããã®ã§ä»åååå ãã¦ãã¾ããã
大åè¨æ¶ãèããªã£ã¦ãã¾ã£ãã®ã§æãåºãã¤ã¤æ¸ãã¦ããã¾ãã
@namikawa, @kei2100ã®3人ã¡ã³ãã¼ã§ã§ã¦ãã¾ããã
è¨èªã¯Node.jsã§ãã
ãã¼ã ã§ãã£ããã¨ï¼è¦ãã¦ãéãï¼
ã¨ãããããµã¼ãç°å¢ãè¦ãããããã©ã«ãç¶æ
ã®Rubyã®ãã³ãçµæãããã©ã«ãã®Node.jsã®çµæã¾ã§ã¿ã¦ãNginxã®ãã°ã¨ãgeneral_logåºããããã¦ã¯ã¨ãªç¢ºèªãã¦ã¿ããDBã¯usersã¨login_logãããã¼ãã«ç¡ãã
ã¤ã³ããã¯ã¹
login_logã«ã
- ip, succeededã®è¤åã¤ã³ããã¯ã¹
- user_id, succeeded, idã®è¤åã¤ã³ããã¯ã¹
ãå
¥ãã¦ã¿ãã¿ã¤ãã³ã°ã§ã ãããMySQLã¯ã¾ãããããããã£ã¦æãã«ãªã£ãã
ã®ã§ããã¨ã¯æ§åè¦ã¤ã¤ã¢ããªã®ç¢ºèªãªã©ãã¤ã¤my.cnfããµã¼ãã®ãªã½ã¼ã¹ç¢ºèªãã¦ããã
MySQLãã¼ã¸ã§ã³ã¢ãã
DBã大ãããã¨ãªãã£ãã®ã§5.7ã«ããã¦ã¿ããã©ã»ã¼æå³ãªãã£ãã
éçãã¡ã¤ã«åãåºã
Nginxå´ã§éçãã¡ã¤ã«ã®åãåºãããã¦ãNginxã§è¿ãããã«å¤æ´ã
tmpfså
MySQLã®ãã¼ã¿é åã®tmpfså
OSãã©ã¡ã¼ã¿ç³»
- my.cnf
- nginx.conf
- kernelãã©ã¡ã¼ã¿
ã®å¤æ´
ããã·ã¥è¨ç®ã®ã¹ããã
DBã«ããã·ã¥å¤ãå
¥ãã
ã»ãã·ã§ã³ã®ãã£ãã·ã¥å
memcachedå°å
¥
ãã®æ®µéã®ç¹æ°
30000è¶
ãã¦ãä½ã ã£ãã¨æãã
ã©ããã¼ãã³ã
17æåããããã
memcachedã«ã»ãã·ã§ã³ãã£ãã·ã¥å
¥ããããã¤ã¤å¹³è¡ãã¦@namikawaãããbenchmakerã®æé©å¤ãè¦ãããã¦ãã®ã§ããããã®ä¸ã§æãããã¦これã«å¼ã£ããã£ã¦ä¸å½ã«é«ãç¹ã«ãªã£ã¦ããã¨ããã®ãããã¾ããã
ãã®æã¯ãªããå®è¡ãé·ããªã¨ã¯æã£ã¦ãã®ã§ãããå
ã
1åã§çµããåæã£ã¦ããä»æ§ããããªãã£ãã®ããã£ã¦ããããã¼ãªããããã¼ãã©ã¨ããããæéãç¡ããããã¯ããã§ãã£ã¦ããã£ã¦ãªãã¾ãã¦ããã®çµæ5ä½ã«å
¥ã£ã¦ãã¾ãã¾ããã確ã62000ãããã ã£ãã¨æãã¾ãã
ããã®å¤±æ ¼
ããã§ãã¸ã£ãã¸çã«æ¬æ¦åºããæãã ã£ããã§ãããここãã¿ã¦ããã ããã¨ãããããã«
ããããå士ï¼RXæ〼ï¼ãã®7ãã¼ã ã¯ããµã¼ãåèµ·åå¾ã«ãåèµ·åå㨠/report ã®åºåå 容ãå¤ãã£ã¦ãã¾ã£ã¦ãããã /report èªä½ãåä½ããªãã£ãããããã¨ã確èªãããå¤±æ ¼ã¨ãããã¾ããã
ããããå士ï¼RXæ〼ï¼ãã®7ãã¼ã ã¯ããµã¼ãåèµ·åå¾ã«ãåèµ·åå㨠/report ã®åºåå 容ãå¤ãã£ã¦ãã¾ã£ã¦ãããã /report èªä½ãåä½ããªãã£ãããããã¨ã確èªãããå¤±æ ¼ã¨ãããã¾ããã
ããããå士ï¼RXæ〼ï¼ãã®7ãã¼ã ã¯ããµã¼ãåèµ·åå¾ã«ãåèµ·åå㨠/report ã®åºåå 容ãå¤ãã£ã¦ãã¾ã£ã¦ãããã /report èªä½ãåä½ããªãã£ãããããã¨ã確èªãããå¤±æ ¼ã¨ãããã¾ããã
çããããã£ã¦ã¾ããããtmpfså
¥ãã¦ã¡ããã¨ãã¼ã¿ã®ä¿åãã§ããããã«ãªã£ã¦ãªãã£ãã®ã§ããããããªããã
ããã¦ã©ããã¼ãã³ãã§ãããããã
benchmaker2ã§ã®è¿½è©¦
32000ã§ãããããã§ã¯æ¬æ¦åºããªãã§ãã®ã§ã¾ãè¯ãã£ãããªã¼ã£ã¦æ¸
ã
ããæ°åã§ãããããåã§ããã¡ãã£ã¨ã ãããããã
æè¨
é害対å¿ãããªããã ãããã£ã¨æ»ããã¹ãã ã£ããªã¼ã¨ããã®ã¯åçãã¦ãã¾ãã
è¨ã訳ããã¨åãã¦ã®åå ã ã£ãã®ã§èªç±åº¦ãææ¡ã§ãã¦ãªãã£ãé¨åã¯ãããããããªããããï¼è¨ã訳ãããªï¼
- å¤æã¯æ©ãããã¤ç«¶æã®é¢ãããã®ã§å¤§èãã大äº
- å½¹å²ãããã®ãããã ãã©å ¨å¡ã³ã¼ããæåã«èªã¿è¾¼ãã§ããäº
- ã¬ã®ã¥ã¬ã¼ã·ã§ã³ã¯èªã¿è¾¼ãã§ãã¼ã ã¡ã³ãã¼ã§å ±æãã¦ãã <- ã¤ãã³ã³
çµãã£ã¦ã¿ã¦
éä¸ãã¦ç²ãããã©æ¥½ãããããããããããããããããããããããããããããï¼ã£ã¦æãã ã£ãã
å®éåå ãã¦ã¿ã¦ããçããã®ããã°ãèªã¾ãã¦ããã ããããã¦å¤§å¤åºæ¿ã«ãªãã¾ããã
ä»åã¯æ®å¿µãªã©ããã¼ãã³ãã ã£ãã®ã§æ¬¡åã¯ã«ãããªæ¬æ¦è¡ã£ãããã³ã
ãç²ãæ§ã§ãã
ãè¿·æããããã @mirakuiããã¯ããéå¶ã®æ¹ã
æ¬å½ã«ãç²ãæ§ã§ããï¼
楽ããISUCONãããã¨ããããã¾ãï¼
æ¬é¸åºå ´è
ã®æ¹ã
ãé å¼µã£ã¦ãã ããï¼
ã«ãã¦ã
ã°ã°ããã«ãè¨ããããã©ããã¯ãã¿çã«ãã¯ã³ãã£ã³MongoDBã ã£ãããªã¼ãã£ã¦æããªãããªãã§ãï½
ã§ã¯ã§ã¯ã¼ä¸(å ãÏã))å
å±±å(YAMAZEN) æãããã¿ãã§ã¢ ã·ã«ãã¼/ãã©ãã¯YZX-08SB
- åºç社/ã¡ã¼ã«ã¼: å±±å(YAMAZEN)
- ã¡ãã£ã¢: ãã¼ã &ãããã³
- ãã®ååãå«ãããã°ãè¦ã