ÄÚºËÖرàÒë¶ÔºÜ¶àLinux°®ºÃÕßÀ´ËµÊÇÒ»¸ö²»Ð¡µÄÌôÕ½¡£±ÊÕßÈÏΪ£¬ºÜ¶àLinuxÓû§¶ÔÄÚºËͨ³£ÓÐÒ»ÖÖÎó½â£¬ËûÃÇÈÏΪÆÕͨÓû§ÊDz»Äܵ÷ÕûÄں˵ġ£Æäʵ£¬¾Íʵ¼ÊÇé¿ö¶øÑÔ£¬ÕâÖÖÈÏʶÊDz»È«ÃæµÄ¡£Ó¦¸Ã˵£¬ÄÚºËÖرàÒëÊǾßÓÐÒ»¶¨Éî¶ÈºÍ¸´ÔÓÐԵģ¬Í¬Ê±Ò²ÊÇÒ×ʧ°ÜµÄÅäÖù¤×÷¡£
Èç¹û´ó¼ÒÁôÒâÄÇЩ±È½ÏȨÍþµÄLinux²Î¿¼¹¤¾ßÊéµÄ»°£¬¾Í»á·¢ÏֺܶàÔ°æÊé¼®¶¼°ÑÄÚºËÖرàÒë×÷Ϊһ¸öºÜÖØÒªµÄÕ½ڽøÐнéÉÜ¡£±¾ÎĽ«ÒªÏò¶ÁÕß½éÉܵIJ¢²»ÊÇÈçºÎÈ¥Ò»²½²½µÄ¶ÔLinuxÄں˽øÐÐÖرàÒ룬¶øÊÇÊÕ¼¯ÕûÀíÁ˼¸¸öÔÚLinuxÄÚºËÖرàÒëÖÐ×î³£¼ûµÄ¹ÊÕϼ°Æä½â¾ö·½·¨£¬Èç¹ûÄúÔÚ±àÒëÄں˹ý³ÌÖÐÓöµ½ÁËÀàËƵĹÊÕÏ£¬ÄÇô±¾ÎĽ«»á¶ÔÄúÓÐËù°ïÖú¡£
LinuxÄÚºËÖرàÒë³£¼û¹ÊÕϽéÉÜ
ÔÚ½éÉÜLinuxÄÚºËÖرàÒë³£¼û¹ÊÕÏÇ°£¬¼ÙÉèÎÒÃÇÒѾ°´Õղο¼¹¤¾ßÊéÉϵIJ½Öè¶ÔLinuxÄں˽øÐÐÁËÏàÓ¦µÄÅäÖá£
LinuxÄÚºËÖرàÒëͨ³£°üÀ¨ÁËÐí¶à²½Öè¡£Èç¹û¡°ÐÒÔË¡±µÄ»°£¬LinuxÄÚºËÖرàÒëÊÇ¿ÉÒÔÒ»´ÎÐÔ±àÒë³É¹¦µÄ¡£Èç¹ûÔÚ±àÒëÍê³Éºó£¬Æô¶¯¼ÆËã»ú»òÕßÄں˵ÄʱºòϵͳÓдíÎóÐÅÏ¢µÄÌáʾ£¬ÄÇô×îÓпÉÄܳöÏÖµÄÊÇÒÔÏÂ5¸ö£º1.Äں˲»ÄÜÆô¶¯£»2.Òì³£I/O´íÎó£»3.Äں˷´Ó³»ºÂý£»4.Äں˲»ÄÜÕýÈ·±àÒ룻5.ϵͳÖظ´Æô¶¯¡£
¹ÊÕÏ·ÖÎö¼°Æä½â¾ö·½·¨
Äں˲»ÄÜÆô¶¯
µ±ÎÒÃÇÖØд´½¨LinuxÄÚºËʱ£¬Ö÷ÒªÊÇÑ¡ÔñÓû§ÐèÒª»ò²»ÐèÒªÔÚϵͳÖÐʹÓõÄÉ豸¼°·þÎñ¡£´Ó2.0°æÄں˿ªÊ¼£¬LinuxÒýÈëÁËÒ»¸öȫеÄÉè¼ÆÌØÕ÷µ½ÄÚºËÖв¢ÌṩÁËÕÛÖз½°¸£º×é¼þ¿ÉÒÔ¶¯Ì¬µÄ¡¢ËæʱµÄµ÷ÈëºÍµ÷³öÄںˡ£ÀýÈçÎÒÃÇÔÚÐÞ¸Ä/etc/lilo.confÖ®ºó¶¼ÒªÖØÐÂÆô¶¯ÏµÍ³£¬Èç¹ûÄãµÄÄں˲»ÄÜÆô¶¯£¬²¢ÇÒÔÚÆÁÄ»ÉÏ¿´µ½ÁËÏÂÃæµÄÐÅÏ¢£º
Warning: unable to open an initial console Kernel panic: no init found. Try passing init= option to kernel
Õâ¸ö´íÎó×î´óµÄ¿ÉÄܾÍÊÇÎÒÃÇûÓÐÕýÈ·µÄ¸ø/etc/lilo.conf Öеġ°root=¡±Ìṩ²ÎÊý¡£ÀýÈ磬ÔÚÒ»¸öLinuxϵͳÖÐÓÐroot=dev/hdc5ÕâÑùµÄÅäÖ÷½Ê½£¬ÄÇôÕâÊÇ´íÎóµÄ£¬ÕýÈ·µÄÓ¦¸ÃÊÇroot=/dev/hdc5£¬²»ÒªÐ¡¿´Ö»ÊǶàÁËÒ»¸ö ¡°/¡±£¬ÕâÊǸørootÌṩµÄÖØÒª²ÎÊý¡£Ã»ÓС°/¡±ÔòLinuxÄÚºËÎÞ·¨È·ÈÏrootµ½µ×¸Ã´ÓÄÄÀïÆô¶¯¡£ºÜ¶àÅóÓÑÍùÍùºöÂÔÁËÕâ¸öСϸ½Ú¶øÔì³ÉÄÚºËÒýµ¼Ê§°Ü¡£ÏÂÃæ¸ø³ö/etc/lilo.confµÄÒ»¸öÕýÈ·µÄÅäÖÃÇåµ¥£¬½ö¹©²Î¿¼¡£
/etc/lilo.confʾÀý
¡ª¡ª¡ª¡ª¡ª¡ª¡ª¡ª¡ª¡ª¡ª
boot=/dev/hdc5
map=/boot/map
prompt
timeout=50
image=/boot/vmlinuz-2.2.2-1
label=Linux
root=/dev/hdc5
inirtd=/boot/initrd-2.2.2-1.img
read-only
other=/dev/hda1
label=dos
table=/dev/hda
Òì³£I/O´íÎó
Èç¹ûÄúÖØд´½¨ÁËÒ»¸öLinuxÄںˣ¬²¢ÇÒÄÜÕýÈ·Æô¶¯£¬µ«ÔÚʹÓÃÐÂÄں˹ý³ÌÖУ¬ÏµÍ³¾³£³öÏÖ±ÀÀ£¡¢ËÀ»úµÈÒì³£ÏÖÏó¡£ÄÇôºÜ¿ÉÄÜÊÇI/O³öÏÖÁËÎÊÌâ¡£I/OÒì³£³ýÁËʹµÃϵͳƵ·±³öÏÖĪÃûÆäÃîµÄ¹ÊÕÏÖ®Í⣬¸üÖØÒªµÄÊÇ»áʹLinuxÄں˽µ¼¶£¬µ¼ÖÂÕû¸öϵͳϵÄÜÑÏÖØϽµ¡£
¾¿ÆäÒì³£I/O´íÎóµÄÔÒò£¬ÊÇÓû§ÔÚ±àÒëLinuxÄں˽áÊøµÄʱºòûÓÐÖ´ÐС°make dep clean¡±ÕâÒ»²½Öè¡£Ò»°ãÀ´Ëµ£¬ÎÒÃÇÔÚ±£´æKernel configurationÑ¡ÏîÖеġ°menuconfig¡±»ò¡°xconfig¡±Ê±²¢²»°üº¬¡°make dep clean¡±Õâ¸ö²½Öè¡£Òò´Ë£¬ÕâÀィÒéÓû§ÔÚ±£´æÅäÖúóµÄKernel configurationÑ¡ÏîʱעÒâÈ·ÈÏÊÇ·ñÒѾ½øÐÐÁË¡°make dep clean¡±ÕâÒ»²½¡£
Äں˷´Ó³»ºÂý
Ä¿Ç°ºÜ¶à¼ÆËã»ú¶¼²ÉÓÃÁ˸ßËÙµÄCPUºÍ´óÈÝÁ¿ÄÚ´æ¡£¿ÉÓÐʱºòÔÚ´´½¨ÐÂÄں˺óϵͳÏԵñÈûÓÐÅäÖÃÄÚºË֮ǰµÄ·´Ó³ËÙ¶ÈÂýµÃ¶à¡£³öÏÖÕâ¸öÇé¿ö£¬ºÜ¿ÉÄÜÊÇÓû§ÔÚÐÞ¸ÄKernel configuration optionsµÄʱºò£¬ÔÚ¡°menuconfig¡±»òÕß¡°xconfig¡±Ñ¡ÔñÁ˹ý¶àµÄÑ¡Ïî¡£ÕâÑù²»½öʹµÃ¼ÆËã»úÔÚ±àÒëÐÂÄں˵ÄʱºòÒª»¨·Ñ¸ü¶àµÄʱ¼ä£¬Ò²Ê¹µÃϵͳÔÚ¹¤×÷µÄʱºòÕ¼ÓÃÁËÌ«¶àµÄÄÚ´æ¡£ÓÉÓںܶàÄڴ涼ÊDZ»ÎÞÓõÄÑ¡ÏîËùÕ¼Óã¬Õâ¾Íµ¼ÖÂÁËϵͳÔËÐеĻºÂý¡£½â¾ö·½·¨ºÜ¼òµ¥£¬¾¡Á¿Ñ¡ÔñÎÒÃÇÐèÒªµÄÑ¡ÏÄÇЩÎÞÓõģ¬Ì«¹ýÓÚ¸´ÔÓµÄÑ¡Ïî¾ÍÎÞÐèÈ¥ÐÞ¸ÄÁË£¬ÓÐʱºòʹÓÃĬÈϵIJÎÊýЧ¹û»áÏԵøüºÃ¡£
Äں˲»ÄܱàÒë
µ±Óû§ÊäÈë¡°make bzImage modules¡±²¢°´ÏÂÊäÈë¼üµÄʱºò£¬³öÏÖÁËÄں˲»ÄܱàÒë»òÕßÆäËûµÄÆæ¹ÖÏÖÏó¡£´Ëʱ×îºÃµÄ·½·¨¾ÍÊÇÖØÐÂÆô¶¯ÏµÍ³£¬È»ºóʹÓá°rpm -e¡±ÃüÁîÒƳýKernel configuration toolsÕâ¸öÄÚºËÅäÖù¤¾ß¡£½Ó×ÅÔÙÖØа²×°Õâ¸ö¹¤¾ß£¨ÇëʹÓá°rpm -I¡±»ò¡°rpm -Uvh¡±ÃüÁîÀ´°²×°£©£¬Èç¹ûÄÜÕýÈ·°²×°£¬ÄÇôÎÊÌâ¾Í¼òµ¥¶àÁË£¬´ËʱÔÙÖØÐÂÅäÖÃÄں˺ÍÔÙ±àÒëÓ¦¸Ã¾ÍÄܳɹ¦¡£Èç¹û»¹ÊDz»ÄܱàÒëÄںˣ¬Çë¼ì²éÓ²¼þÉ豸ÊDz»ÊÇÓÐÎÊÌâ¡£
ϵͳÖظ´Æô¶¯
³öÏÖÕâÖÖÇé¿ö£¬Ê®Óа˾ÅÊÇÒòΪÔÚ¶ÔÄÚºË×öÍêÐÞ¸ÄÖ®ºóÍü¼ÇʹÓÃLILOÀ´×¢²áеÄÓ³Ïóµ½Æô¶¯¼ÓÔسÌÐò¡£LILOÐèÒªÄں˵ÄÉÈÇøλÖã¬Òò´Ë¼´Ê¹ÊÇ¿½±´Ó³ÏóÒ²»á½«ÆäǨÒƵ½ÐµÄÉÈÇøÖУ¬Õ⽫ʹµÃLILO´æ´¢µÄÀÏÖ¸Õë¹ÒÔÚÒ»¸öÉîÔ¨ÉÏ¡£
ΪÁ˽â¾öÕâ¸öÎÊÌ⣬Çë´ÓÈíÇýÆô¶¯²¢ÔËÐÐLILOÃüÁ»òʹÓÃÍì¾È´ÅÅÌÆô¶¯²¢°²×°Æô¶¯·ÖÇøµ½¡°/mnt¡±£¬Í¬Ê±Ê¹ÓÃÈçÏÂÃüÁlilo -r /mnt¡£