Linux²Ù×÷ϵͳÖ÷»úÃû(hostname)¼ò˵£¨v0.1b£©
×÷Õߣº±±ÄÏÄϱ±
À´×Ô£ºLinuxSir.Org
ÕªÒª£º±¾ÎÄÊǹØÓÚLinux²Ù×÷ϵͳÖ÷»úÃû(hostname)µÄÎĵµ£¬¶ÔÖ÷ÒªÅäÖÃÎļþ/etc/hosts½øÐмòÒªµÄ˵Ã÷ £»ÁíÍâ¶Ô»ùÅä¾ß¹¤¾ßhostnameÒ²½øÐÐÁ˾ÙÀý˵Ã÷£» »¶Ó¸ßÊÖ¸«Õý£¬Ð»Ð»£»
Ŀ¼
2.1 Ö÷»úÃûÅäÖÃÎļþ /etc/hosts½â˵£»
2.2 Ö÷»úÃû(hostname)ºÍÓòÃû(Domain£©µÄÇø±ð£»
2.3 ¾ÖÓòÍøµÄ»úÆ÷£¬²»ÄÜͨ¹ýÖ÷»úÃû»¥·ÃµÄÔÒò£»
1¡¢ ʲôÊÇÖ÷»úÃû£»
2. Ö÷»úÃûÅäÖÃÎļþ£»
3¡¢Ö÷»úÃûÐ޸Ť¾ß hostname;
4¡¢±¾ÎÄδ¾¡ÊÂÒË£»
5¡¢¹ØÓÚ±¾ÎÄ£»
6¡¢¸üÐÂÈÕÖ¾£»
7¡¢²Î¿¼Îĵµ£»
8¡¢Ïà¹ØÎĵµ£»
++++++++++++++++++++++++++++++++++++++++
ÕýÎÄ
++++++++++++++++++++++++++++++++++++++++
1¡¢ ʲôÊÇÖ÷»úÃû£»
ÎÞÂÛÔÚ¾ÖÓòÍø»¹ÊÇINTERNETÉÏ£¬Ã¿Ì¨Ö÷»ú¶¼ÓÐÒ»¸öIPµØÖ·£¬ÊÇΪÁËÇø·Ö´Ę̈Ö÷»úºÍ±Ę̈Ö÷»ú£¬Ò²¾ÍÊÇ˵IPµØÖ·¾ÍÊÇÖ÷»úµÄÃÅÅƺš£µ«IPµØÖ·²»·½±ã¼ÇÒ䣬ËùÒÔÓÖÓÐÁËÓòÃû¡£ÓòÃûÖ»ÊÇÔÚ¹«Íø£¨INtERNET)ÖдæÔÚ(ÒÔʵÑéΪĿµÄµÄ¾ÖÓòÍøÓòÍøʵÑéÐÔ³ýÍ⣩£¬Ã¿¸öÓòÃû¶¼¶ÔÓ¦Ò»¸öIPµØÖ·£¬µ«Ò»¸öIPµØÖ·¿ÉÓжÔÓ¦¶à¸öÓòÃû¡£ÓòÃûÀàÐÍ linuxsir.org ÕâÑùµÄ£»
Ö÷»úÃûÊÇÓÃÓÚʲôµÄÄØ£¿ÔÚÒ»¸ö¾ÖÓòÍøÖУ¬Ã¿Ì¨»úÆ÷¶¼ÓÐÒ»¸öÖ÷»úÃû£¬ÓÃÓÚÖ÷»úÓëÖ÷»úÖ®¼äµÄ±ãÓÚÇø·Ö£¬¾Í¿ÉÒÔΪÿ̨»úÆ÷ÉèÖÃÖ÷»úÃû£¬ÒÔ±ãÓÚÒÔÈÝÒ×¼ÇÒäµÄ·½·¨À´Ï໥·ÃÎÊ¡£±ÈÈçÎÒÃÇÔÚ¾ÖÓòÍøÖпÉÒÔΪ¸ù¾Ýÿ̨»úÆ÷µÄ¹¦ÓÃÀ´ÎªÆäÃüÃû¡£
Ö÷»úÃûÏà¹ØµÄÅäÖÃÎļþ£º/etc/hosts;
2. Ö÷»úÃûÅäÖÃÎļþ£»
Ö÷»úÃûµÄÅäÖÃÎļþ´ó¶àÊÇ/etc/hosts £»
hosts - The static table lookup for host name£¨Ö÷»úÃû²éѯ¾²Ì¬±í£©£»
ÓÉÓÚ Linux ·¢Ðа汾Öڶ࣬ÓëÖ÷»úÃûÏà¹ØµÄÅäÖÃÎļþÓÐʱҲÓÐËù²»Í¬¡£ÏÖÔÚÎÒÃÇ˵˵³£¼û°æ±¾µÄÖ÷»úÃûÅäÖÃÎļþ£»
2.1 Ö÷»úÃûÅäÖÃÎļþ /etc/hosts½â˵£»
Fedora/Redhat »òÒÔFedora/RedhatΪ»ù´¡´ò°üµÄ·¢Ðа棬Ö÷»úÃûÅäÖÃÎļþÊÇ /etc/hosts
Debian»òÒÔDebianΪ»ù´¡´ò°üµÄ·¢Ðа棬Ö÷»úÃûÅäÖÃÎļþÊÇ /etc/hostname ºÍ/etc/hosts
SlackwareµÄÖ÷»úÃûÅäÖÃÎļþÊÇ /etc/hosts
ÄÇÎÒÃÇÀ´¶Á¶Á /etc/hostsµÄÄÚÈÝ£¬¿´Õâ¸öÎļþÊÇÓÃÀ´×öʲôµÄ¡£hosts ÅäÖÃÎļþÊÇÓÃÀ´°ÑÖ÷»úÃû×ÖÓ³Éäµ½IPµØÖ·µÄ·½·¨£¬ÕâÖÖ·½·¨±È½Ï¼òµ¥¡£µ«ÕâÖÖÓ³ÉäÖ»ÊDZ¾µØ»úµÄÓ³É䣬Ҳ¾ÍÊÇ˵ÿ̨»úÆ÷¶¼ÊǶÀÁ¢µÄ£¬ËùÓеļÆËã»ú¶¼²»ÄÜÏ໥ͨ¹ýhostnameÀ´·ÃÎÊ¡£
×¢£ºÔÚdebian Öл¹ÓÐÒ»¸ö/etc/hostnameµÄÎļþ£¬Õâ¸öÎļþ¾ÍÊÇÖ±½Ó°Ñ±¾µØÖ÷»úÃûд½øÈ¥¾ÍÐÐÁË£¬µ«ÒªºÍ /etc/hostsÖеı¾µØÖ÷»úÃû±£³ÖÒ»Ö¡£
/etc/hosts µÄÄÚÈÝÒ»
Ïà¹ØÎĵµ£º
ÓÉÓÚ Linux Á¼ºÃµÄÓû§È¨ÏÞ¹ÜÀíÌåϵ£¬²¡¶¾ÍùÍùÊÇ Linux ϵͳ¹ÜÀíÔ±×îºó²ÅÐèÒª¿¼ÂǵÄÎÊÌâ¡£ÒÔÍù£¬Linux ÉϵÄɱ¶¾Èí¼þÖ÷ÒªÊÇΪÆóÒµµÄÓʼþºÍÎļþ·þÎñÆ÷ËùÉè¼ÆµÄ¡£Èç½ñ£¬Ëæ×Å Linux ×ÀÃæÓû§ÊýÁ¿µÄÔö³¤£¬×ÀÃæÓû§ÔÚÊÜÒæÓÚ Linux ϵͳ¶Ô²¡¶¾½ÏÇ¿µÄÌìÈ»ÃâÒßÁ¦µÄͬʱ£¬Ò²ÐèҪɱ¶¾Èí¼þÇåÀí´ÓÍøÂç»òUÅÌ´øÀ´µÄWIndows²¡¶¾¡£¾¡¹ÜÄÇЩ ......
from:http://www.dzjs.net/html/qianrushixitong/2008/0509/3125.html
1 ÒýÑÔ
ELF(Executable and Linkable Format)¼´¿ÉÖ´ÐÐÁ¬½ÓÎļþ¸ñʽ£¬ÊÇLinux£¬SVR4ºÍSolaris2.0ĬÈϵÄÄ¿±êÎļþ¸ñʽ£¬Ä¿Ç°±ê×¼½Ó¿ÚίԱ»áTISÒѽ«ELF±ê×¼»¯ÎªÒ»ÖÖ¿ÉÒÆÖ²µÄÄ¿±êÎļþ¸ñʽ£¬ÔËÐÐÓÚ32-bit IntelÌåϵ΢»úÉÏ£¬¿ÉÓë¶àÖÖ²Ù×÷ ......
http://www.askwan.com/post/28/
haproxy+keepalived
LinuxÆóÒµ¼¯Èº
http://book.51cto.com/art/200806/76015.htm#
µÚÒ»²½:rsyncͬ²½webÊý¾Ý£¨²âÊÔͨ¹ý²¢ÇÒ×Ô¼º¼ÓÈëÁËsshµÄRSA keyÑéÖ¤£©
http://www.linuxsir.org/main/?q=node/256 rsync ·þÎñÆ÷¼ÜÉè·½·¨ v0.1b £¨ÕýÔÚÐÞ¶©ÖУ©
µÚ¶þ²½:°²×°heartbeat²¢ÇÒ¿ ......
µ¥Óû§Ä£Ê½½øÈ룺
½øÈëÆô¶¯»ÃæÖ®ºó£¬ÇÃÈë“e”£¬¹â±êÒƶ¯µ½kernel ...ÄÇÒ»ÐУ¬ÔÙÇÃÈë“e”£¬ÔÚkernel Ò»ÐеÄ×îºó¼ÓÉÏ¿Õ¸ñsingle£¬»Ø³µ
ÇÃÈë“b”£¬Æô¶¯ÏµÍ³£¬¼´½øÈëµ¥Óû§Ä£Ê½
²é¿´ÃüÁîÆô¶¯Â·¾¶£º
vi .bashrc
²é¿´»·¾³±äÁ¿£º
env
¸Ä±äĿ¼ȨÏÞ£º
chmod -R +777 Ŀ¼
²é¿´×Ô ......
ÔÚÍøÉÏ¿´µ½ÓÐÈË×ܽáµÃ²»´í
1£®¿ª»úÆô¶¯Ê±×Ô¶¯ÔËÐгÌÐò
Linux
¼ÓÔغó, Ëü½«³õʼ»¯Ó²¼þºÍÉ豸Çý¶¯, È»ºóÔËÐеÚÒ»¸ö½ø³Ìinit¡£init¸ù¾ÝÅäÖÃÎļþ¼ÌÐøÒýµ¼¹ý³Ì£¬Æô¶¯ÆäËü½ø³Ì¡£Í¨³£Çé¿öÏ£¬Ð޸ķÅÖÃ
ÔÚ /etc/rc»ò /etc/rc.d »ò /etc/rc?.d Ŀ¼ÏµĽű¾Îļþ£¬¿ÉÒÔʹinit×Ô¶¯Æô¶¯Æ ......