GNU Wgetã®å帰çãªãã¦ã³ãã¼ãæã®ä¸å ·åã«ãããä»»æã®ãã¼ã«ã«ãã¡ã¤ã«ãæä½ãããèå¼±æ§(CVE-2014-4877)ã«é¢ããæ¤è¨¼ã¬ãã¼ã ãæ¦è¦ã ãªã¢ã¼ãã®ãã¡ã¤ã«åå¾ãè¡ããã¼ã«GNU Wgetï¼ä»¥ä¸ãWgetï¼ã«ãä»»æã®ãã¡ã¤ã«ã®ä½æãä¸æ¸ããªã©ã®æä½ãå®è¡ãããèå¼±æ§(CVE-2014-4877)ãçºè¦ããã¾ãããããã¯ãWgetãå帰çã«ãã¡ã¤ã«ããã¦ã³ãã¼ãããéã®ãã·ã³ããªãã¯ãªã³ã¯ãã¡ã¤ã«ã®å¦çã«ä¸å ·åãåå¨ããããã§ãã ããã«ãããæ»æè ã¯ç´°å·¥ããã·ã³ããªãã¯ãªã³ã¯ãã¡ã¤ã«ãã¿ã¼ã²ããPCã«ãã¦ã³ãã¼ãããããã¨ã«ãããä»»æã®ãã¡ã¤ã«ã®ä½æãä¸æ¸ããå®è¡å¯è½ã¨ãªãã¾ãã ä»åãWgetã®å帰çã«ãã¦ã³ãã¼ãããæ©è½ã®ä¸å ·åã«ãããä»»æã®ãã¡ã¤ã«ã®ä½æãä¸æ¸ããå®è¡ãããèå¼±æ§(CVE-2014-4877)ã®åç¾æ§ã«ã¤ãã¦æ¤è¨¼ãè¡ãã¾ããã ãå½±é¿ãåããå¯è½æ§
TIME_WAIT ç¶æ ã® TCP ã³ãã¯ã·ã§ã³ãå¤æ°æ®ã netstat ã³ãã³ã㧠TCP ã³ãã¯ã·ã§ã³ã®ç¶æ ã確èªãã¦ããã¨ã"TIME_WAIT" ã¨ããç¶æ ã®ã³ãã¯ã·ã§ã³ããããã確èªãããå ´åãããã¾ãã "TIME_WAIT" ç¶æ ã¨ããã®ã¯ TCP ã³ãã¯ã·ã§ã³ã«ããã¦ããã¡ãå´ããéä¿¡ãããå ´åã« "FIN_WAIT_1" (FIN ACK åä¿¡) ããã"FIN_WAIT_2" (ACK åä¿¡) ã¾ã㯠"CLOSING" (FIN åä¿¡, ACK éä¿¡)ãçµã¦ãã³ãã¯ã·ã§ã³ãéããããç¶æ ã¨ãªã£ããã¨ã示ããã®ã®ããã§ãã ããã¦ãã® "TIME_WAIT" ãããå®éã«ãã®ã³ãã¯ã·ã§ã³ãéããã㦠"CLOSED" ã¨ãªãã¾ã§ã®éã«å¾ ã¡æéããããããã«ãã£ã¦ãçæéã«éä¿¡ãéä¸ããã¨ããã®åã ãéä¿¡çµäºééã® "TIME_WAIT" ç¶æ ã®ã³ãã¯ã·ã§ã³ãå¤æ°ãne
yesã³ãã³ãã¨ã¯ï¼ 'YES' - å¦ç²¾ãã¿ãã¦ãã¾ãã¸ã§ã³ã¢ã³ãã¼ã½ã³ã®ããã°ã¬ãã·ããã³ãã®ãã¨ã§ã¯ããã¾ãããUNIX/Linux ã® yes ã³ãã³ããå°ãã ãèªã£ã¦ã¿ããã¨æãã¾ãã yesã³ãã³ãã£ã¦ãªãã§ããï¼ã¨ãã人ã¯ã¾ãUNIX/Linuxã®ã¿ã¼ããã«ã§'yes'ã¨å ¥åãã¦ã¿ã¾ãããã $ yes y y y^Cy ãã²ãããç¶ãã¾ããå¼æ°ã«æååã渡ãã°ãã®æååãã²ãããåãåºãã¾ãã $ yes "Cirque du Soleil" Cirque du Soleil Cirque du Soleil Cirque du Soleil Cirque du Soleil^Cããæå³ããã®ï¼ã¨æããããªãã¾ããã§ã¯ä½ã«ä½¿ããã®ã§ãããï¼ ããã¿ã¼ããã«ã§å¯¾è©±çã«è¡ãã¨ãã« ãªã㨠ãã® y ãå ¥åãã¦ãããã®ã§ãã yesã®ä¾ ã¾ããã¹ããã¡ã¤ã«ä½æ $ for i i
LXC ã®è§£èª¬ã«å¿ è¦ãªã®ã§ãã¡ãã㨠cgroups ã«ã¤ãã¦ã¾ã¨ãã¦ããã¾ããRHEL6.0 åæã§ãã åèè³æ: RHEL6 ãªã½ã¼ã¹ç®¡çã¬ã¤ã Control Groups(cgroups) ã®æ¦è¦ cgroups ã¨ã¯ æè¿ã® Linux ã¯ãããããã»ã¹ã®å®è¡ã許å¯ãã CPU ã³ã¢ã®æå®ãªã©ãããã»ã¹ãã¨ã«ãã¾ãã¾ãªãªã½ã¼ã¹å¶å¾¡ãã§ããããã«ãªã£ã¦ãã¾ãããã®ãããªå¶å¾¡ãè¤æ°ã®ããã»ã¹ãã°ã«ã¼ãåããã°ã«ã¼ãåä½ã§ã§ããã¨ä¾¿å©ãªå ´åãããã¾ããcgroups ã¯ãã°ã«ã¼ãåä½ã§ãªã½ã¼ã¹å¶å¾¡ãè¡ãããã®ã¦ã¼ã¶ã»ã¤ã³ã¿ã¼ãã§ã¼ã¹ãç¹æ®ãã¡ã¤ã«ã·ã¹ãã ã®å½¢å¼ã§æä¾ãã¾ãã cgroups èªä½ããªã½ã¼ã¹å¶å¾¡ã®æ©è½ãæä¾ããããã§ã¯ããã¾ãããæ¢åã®ãªã½ã¼ã¹å¶å¾¡æ©è½ï¼cgroups ã®ç¨èªã§ãã³ã³ããã¼ã©ããããã¯ããµãã·ã¹ãã ãã¨è¨ãã¾ãï¼ã cgroups ã®ã¤ã³ã¿ã¼ãã§ã¼ã¹ãå©
Linux Network Namespace ã使ã㨠1 ã¤ã® Linux ãã¹ãã®ä¸ã«ä»®æ³çãªãããã¯ã¼ã¯ç°å¢ãè¤æ°ä½ãããä»åã¯ãµã¼ããã²ã¼ãã¦ã§ã¤ãã¯ã©ã¤ã¢ã³ãã® 3 ã¤ã®ãã¼ã ã¹ãã¼ã¹ãä½ã£ã¦éä¿¡ããã¦ã¿ãããã®æ©è½ã使ãã«ã¯æ°ããã® Linux ã«ã¼ãã«ã¨ãã¼ã«ç¾¤ãå¿ è¦ã¿ãããªã®ã§ãã£ã¹ããªãã¥ã¼ã·ã§ã³ã«ã¯ Ubuntu 13.04 ã使ã£ãã
CentOS release 6.4 (Final) rbenv, ruby-buildã®ã¤ã³ã¹ãã¼ã« sudoå°çãªã®ã§rootã§ä½æ¥ãè¡ã. su # 以ä¸root cd /usr/local git clone git://github.com/sstephenson/rbenv.git rbenv mkdir rbenv/shims rbenv/versions groupadd rbenv chgrp -R rbenv rbenv chmod -R g+rwxXs rbenv git clone git://github.com/sstephenson/ruby-build.git ruby-build cd ruby-build ./install.sh ã¨ãã¦, /etc/profile.d/rbenv.shã« export RBENV_ROOT="/usr/local/rb
| local | 10080/tcp  ssh -L 10080:localhost:20080 username@step1ã»ã»ã»â
ãç¹å®CPUã³ã¢ã§ã®ããã«ããã¯ãã¨ããªã½ã¼ã¹ã®å¥ªãåããã2大ããã«ãã㯠第2åã第3åã§ã¯ãã£ã¹ã¯I/Oããã«ããã¯ã«ã¤ãã¦èª¬æãã¾ãããã¬ã¹ãã³ã¹ã¨ã¹ã«ã¼ãããã®é¢ä¿ãæ£ããç解ããI/Oã¹ã«ã¼ããããæ大åãããããã¥ã¼ãã³ã°ããã°ãã»ã¨ãã©ã®å¤§è¦æ¨¡å¦çã¯éããªãã¾ããã¦ã¼ã¶ããããã¼ãçããããããã¼ããã¦å®¶ã«å¸°ãã¾ãããã â¦â¦ãããã次ã¯ã ããããããèããããã¨ã§ãããã ãCPUã®ä½¿ç¨çãç°æ§ã«ä½ãã¾ã¾ãªãã ãã©â¦â¦ï¼ã ãCPUã®ä½¿ç¨çããã£ã¨100ï¼ ã§å¼µãä»ãã¦ãããã ãã©â¦â¦ï¼ã ã©ã£ã¡ãããï¼ã¨æãã§ãããããã©ã¡ãã大è¦æ¨¡ãã¼ã¿ãå¦çããã¨ãã«ç¹ã«èµ·ããããåé¡ã§ãã ããã«ããã¯ã¯ã1ã¤ã解æ¶ããã¨ãæ°ããªãã¤ã³ããæããã«ãªããã®ã§ããããã¦å¤ãã®ã±ã¼ã¹ã«ããã¦ããã£ã¹ã¯I/Oããã«ããã¯ã解æ¶ããå ´åã次ã«è©°ã¾ãã®ã¯CPUãªã®ã§ãã CPUããã«ããã¯ã¯
èªåã®æ¸ãã¦ããããã°ã©ã ããNICã®è¨å®ãç´æ¥å¼ããããªã£ãäºã¯ãªãã ãããï¼ ããã°ã©ã å ããifconfigã³ãã³ãã«å¼æ°ãã¤ãã¦å®è¡ããã°ç°¡åã«å®ç¾ã§ããããããã¯ããã¾ãæ ¼å¥½è¯ããªãããæ å ±ãåãåºããã¨ããã¨ifconfigã³ãã³ãã®åºåæååããã¼ã¹ãããããªããã°ãªããªããªã£ã¦æ ¼å¥½æªãã ããããã°ã©ã ã®æ¸ãæ¹ã¨ãã¦æ£ããã®ã¯ãifconfigã³ãã³ããå©ãã¦ããAPIãèªåã§å©ãã¦ã¿ãäºã ããã ã¨ããããã§ãããã§ã¯ifconfigã³ãã³ããNICãæä½ããããã«å©ãã¦ããAPIãèªåã§å©ãã¦NICã®è¨å®ãå¤æ´ãã¦ã¿ããã¨æãã ã¾ãã¯æãåç´ãªããã°ã©ã ã¨ãã¦ãNICã®ãªã³ã¯ã¹ãã¼ã¿ã¹ãUP/DOWNããã¨ããã®ã試ãã¦ã¿ããã ã½ã±ããã¸ã®ioctlã«ããNICãªã³ã¯ã¹ãã¼ã¿ã¹å¤æ´ ifconfigã³ãã³ãã§è¡ããã¦ããNICãªã³ã¯ã¹ãã¼ã¿ã¹ã®å¤æ´å¦çãæå°éã®ã³ã¼
screenã¯ï¼ã¤ã®ã¿ã¼ããã«ã§è¤æ°ã®ã¦ã£ã³ãã¦ãéãã¦åãæ¿ããªããä½æ¥ãããã¨ãã§ããã½ããã¦ã§ã¢ã§ãã ã¾ãä¼¼ããããªãã®ã¨ãã¦byobuãtmuxã¨ãããã®ãããã¾ãã ããããã®é¢ä¿æ§ãããããããªãã®ã§èª¿ã¹ã¦ã¿ã¾ããã çµè« tmuxã¯screenã¨ã¯ä¸åé¢ä¿ã®ãªãã½ããã¦ã§ã¢ãscreenã¨æ¯è¼ãã¦ç»é¢åå²ã§ããã®ãã¡ãªãã byobuã¯screenã®è¨å®ãç°¡åã«è¡ãããã®ã½ããã¦ã§ã¢ãæ¨æºã§ããç¨åº¦ä¾¿å©ãªè¨å®ããã¦ããã å®ã¯byobuã«ã¯tmuxã®è¨å®ãç¨æããã¦ããã(byobu-tmuxã§èµ·å) æ¢ã«screenãtmuxã®è¨å®ãèªå好ã¿ã«è¨å®ãã¦ãã人ã¯byobuã使ãå¿ è¦ã¯ãªãã ã¨ãããã¨ã¿ããã§ãã 以éããããã使ãã¾ã§ã®è¨å®ããç´¹ä»ãã¾ãã ã¤ã³ã¹ãã¼ã«ãè¨å®æ¹æ³ CentOSã®å ´å screen ã¤ã³ã¹ãã¼ã« yum -y install screen
æ´æ°æ å ± 2017å¹´6æç¾å¨ãWalB ã®ããã¸ã§ã¯ããã¼ã¸ã¯https://walb-linux.github.io/ã§ãã ããã«ã¡ã¯ï¼ãµã¤ãã¦ãºã»ã©ãã®æéã§ãï¼ ä»æ¥ã¯ï¼å¹ççãªããã¯ã¢ããã¨éåæã¬ããªã±ã¼ã·ã§ã³ãç®çã¨ãã Linux ã«ã¼ãã«ãã©ã¤ã WalB ã«ã¤ãã¦ã®ç°¡åãªç´¹ä»ã¨ï¼ãã®ãã¼ã¸ã§ã³ 1.0 ã®ãªãªã¼ã¹åç¥ãããã¦é ãã¾ãï¼ WalB ã£ã¦ä½ï¼ WalB ã¯ãã¯ã«ãã¼ãã¨çºé³ãã¾ãï¼ååã®ç±æ¥ã¯ Block-level WAL ã§ãï¼WAL 㯠Write-Ahead Logging (ãã°å è¡æ¸ãè¾¼ã¿) ã®ãã¨ã§ï¼ãã¼ã¿ãã¼ã¹ã®ä¸è²«æ§å¶å¾¡çã«ç¨ãããã¾ãï¼ WalB ã使ãã¨ï¼ãªã³ã©ã¤ã³ç¶æ ã®ãããã¯ããã¤ã¹ã«ããã¦ï¼ã¢ããªã±ã¼ã·ã§ã³ããã¡ã¤ã«ã·ã¹ãã ã«ãããã¼ã¿æ¸ãè¾¼ã¿ã«ãã£ã¦çããå·®åãã¼ã¿ãï¼ãããã¯ããã¤ã¹ããã«ã¹ãã£ã³ãããã¨ãªãå¹ççã«åå¾åºæ¥ã
GNU/Linuxã«æ £ãã¦ãã¨ãããæã¤top/ps/netstatãOS X使ã£ã¦ãã¨ãã«Linuxã®ããã¨å ¨ç¶ã¡ããæåã§ä½¿ãã«ãããåãæåã«ããã®manè¦ã¦ãç¡çãããªãã§ããªãã¨ãåãããã«ä½¿ããã®ãªãã調ã¹ã¦ã¿ãã top htopãªãLinuxã¨OS Xã§åãããã«ä½¿ããã®ã§htopã使ãã¨ããããã brew install htop-osx ps psã®ãã代æ¿ã¯è¦ã¤ãããªãã£ããã©ãps auxfã®ããã«ããªã¼è¡¨ç¤ºãããã¨ãã®ä»£æ¿ã¯pstreeã使ãã¨ããããã brew install pstree netstat netstatã¯netstat -tnpaã¨ãnetstat -tnplããã使ããã©ãåè ã¯lsof -nP -iTCPãå¾è ã¯lsof -nP -iTCP -sTCP:LISTENã§ä»£æ¿ã§ãããã $ sudo lsof -nP -i4TCP -sTC
ä¸è¬çã«ãç¾å¨å®è¡ããã¦ããããã»ã¹ãç¥ãããã«ã¯ãpsãã³ãã³ããå©ç¨ãããããã§ã¯ãps auxãã§è¡¨ç¤ºãããåé ç®ã®æå³ã解説ãã¦ãããã USER PID %CPU %MEM SIZE RSS TTY STAT START TIME COMMAND xxxx 4542 0.0 1.3 1296 672 p0 S 10:19 0:00 -bash nobody 453 0.0 1.4 1664 630 ? S 11:37 0:00 httpd
ãµã¼ãã®ã¡ã¢ãªãæã£ã以ä¸ã«æ¶è²»ãã¦ããã®ã§ãµãã¯ãªèª¿ã¹ã¦ãã®ã§ãã åããã»ã¹ã®ã¡ã¢ãªä½¿ç¨ç¶æ³ã®èª¿ã¹æ¹ã¨ãã¦ã¯ ps aux --sort=-rss | head -40ã¨ããã¨RSSã®ãµã¤ãºã§ã½ã¼ããã¦ãããã®ã§headã¨ãã§ã¿ã¦ããã°ã¡ã¢ãªä½¿ç¨éãå¤ãé ã«åç §å¯è½ã ãã ããã«ps auxããã ãã ã¨è¦ãã®ãããã©ãã topã§ãshift+Mã§åãæãã§ã¿ããã®ã§ããã§ãè¯ãã ï¼cãå ¥åãã¦ããã»ã¹ã®è©³ç´°ã表示ããã¨ãªãããï¼ ãã¨ã¯CoWã«ä¹ã£ã¦ããã調ã¹ããã http://d.hatena.ne.jp/naoya/20080212/1202830671 naoyaãããç´¹ä»ããã¦ããæ¹æ³ãã®ã¾ãã¾ã§ããã§ãããã sudoãã¦å®è¡ãããã¨ã Cowã¯ã¢ããªã®è³ªã«ããããåºæ¬çã«ã¯ã©ã¤ãã©ãªãå ±æã¡ã¢ãªã«ä¹ã£ã¦ãã°ãããã ã¢ããªã®è³ªãã¿ã¤ã¤sharedãªãã¼ã»ã³ãã調æ´åº
åºå®IPã¢ãã¬ã¹ã®è¨å®æ¹æ³ â ãããã¯ã¼ã¯ããã¤ã¹ã®è¨å®ãã¡ã¤ã«ãç·¨é # vi /etc/sysconfig/network-scripts/ifcfg-eth0 DEVICE=eth0ãããâããã¤ã¹å ONBOOT=yesãããâã·ã¹ãã èµ·åæã«æå¹ã«ããã BOOTPROTO=noneãããâåºå®IP:none,static DHCPã¯dhcp HWADDR=XX:XX:XX:XX:XX:XXãããâMACã¢ãã¬ã¹ TYPE=Ethernet ãããâã¤ã³ã¿ãã§ã¼ã¹ã®ããã¤ã¹ã¿ã¤ããä»ã«xDSLãªã© #DHCP_HOSTNAME=example.comãããâDHCPãµã¼ãã«éç¥ãããã¹ãå IPADDR=192.168.xx.xxããããâIPã¢ãã¬ã¹ã®æå®ï¼å¥½ããªããã«ï¼ NETMASK=255.255.255.0ãããâIPã¢ãã¬ã¹ã«å¯¾ããããããã¹ã¯ã®æå®
30é±ã«æ¸¡ãå¤å½©ãª Linux ã«ã¼ãã«éçºè ãç´¹ä»ãã¦ããã·ãªã¼ãºã®ç¬¬5å¼¾ã¯ãLinux ã¹ãã¼ãã« (å®å®ç) ã«ã¼ãã«ã®ã¡ã³ããã¼ã§ãLinux Foundation ãã§ãã¼ã§ããã Greg Kroah-Hartman ã§ãã ããã¾ã§ã«ç´¹ä»ããéçºè ã®ãããã£ã¼ã«ã¯ããã¡ãã«æ²è¼ããã¦ãã¾ãã ãååããé¡ããã¾ãã Greg Kroah-Hartman ã§ãããã£ã±ã Greg K-H ã¨ãã¦ç¥ããã¦ãã¾ããçºé³ã§ããªãããã§ããããã Linuxã³ãã¥ããã£ã§ã®ããªãã®å½¹å²ããæ å½ã®ãµãã·ã¹ãã ã«ã¤ãã¦æãã¦ãã ããã ç§ã¯ Linux ã«ã¼ãã«ã® ã¹ãã¼ãã« ã«ã¼ãã« ãªãªã¼ã¹ã管çãã¦ãã¾ããã¾ããUSBããã©ã¤ãã¼ ã³ã¢ãã¹ãã¼ã¸ã³ã° ãã©ã¤ãã¼ãã·ãªã¢ã«ãttyãcharããã®ä»ãã¤ãã¼ãªãã©ã¤ãã¼ã®ãµãã·ã¹ãã ã¡ã³ããã¼ã§ãããã¾ãã å ±é ¬ã¯ã©ãããå¾ã¦ãã¾ãã
ã¯ããã« SSH æ¥ç¶ã§æéã®æããã·ã§ã«ã¹ã¯ãªãããããã¯ã°ã©ã¦ã³ãã§èµ°ããã¦å¸°ãããã®ã«ãSSH æ¥ç¶ãåãã¨ã¸ã§ããæ»ãã§ãã¾ãã¾ããSSH æ¥ç¶ã«éããç®ã®åã® OS ãããã°ã¢ã¦ããããã¿ã¼ããã« ã¨ãã¥ã¬ã¼ã¿ãçµäºãã¦ãåãç¾è±¡ãèµ·ããã¾ãã ãã®çç¶ã¯æ£å¸¸ã§ãããªããªããããã¯ã°ã©ã¦ã³ã ã¸ã§ããèµ·åããããã»ã¹(ãã°ã¤ã³ ã·ã§ã«)ãåããã»ã¹ã§ãã該å½ã®ããã¯ã°ã©ã¦ã³ãã¸ã§ãããã³ã°ã¢ãã ã·ã°ãã«( HUP )ã«ãã£ã¦çµäºãããããã§ãã ã·ã§ã«ã¹ã¯ãªãããèµ·åãã親ããã»ã¹ã¯åããã»ã¹ã®çµäºç¶æ ãç£è¦ãã¦ãã¾ããã§ããããã°ã¢ã¦ããã¦è¦ªããã»ã¹ã§ããã·ã§ã«ãçµäºããã¨åããã»ã¹ã¯ã¾ã³ã ããã»ã¹ã¨ãªã£ã¦ãã¾ãã®ã§è¦ªããã»ã¹ã¨ãªãã·ã§ã«(ãã°ã¤ã³ã·ã§ã«)ã¯åããã»ã¹ã§ããããã¯ã°ã©ã¦ã³ã ã¸ã§ãã kill ( kill -HUP ) ããã®ã§ãã nohup ã³ãã³ã
ãªãªã¼ã¹ãé害æ å ±ãªã©ã®ãµã¼ãã¹ã®ãç¥ãã
ææ°ã®äººæ°ã¨ã³ããªã¼ã®é ä¿¡
å¦çãå®è¡ä¸ã§ã
j次ã®ããã¯ãã¼ã¯
kåã®ããã¯ãã¼ã¯
lãã¨ã§èªã
eã³ã¡ã³ãä¸è¦§ãéã
oãã¼ã¸ãéã
{{#tags}}- {{label}}
{{/tags}}