{"id":115,"date":"2006-08-15T06:16:00","date_gmt":"2006-08-15T06:16:00","guid":{"rendered":"http:\/\/blog.trungson.com\/?p=115"},"modified":"2006-08-15T06:16:00","modified_gmt":"2006-08-15T06:16:00","slug":"remote-kernel-upgrade","status":"publish","type":"post","link":"http:\/\/blog.trungson.com\/?p=115","title":{"rendered":"Remote kernel upgrade"},"content":{"rendered":"<p>If for some\/many reasons after a kernel upgrade, the system does not reboot. Some hosting control panels can reboot the server into rescue mode. In this mode, you can edit the lilo.conf to go back to the previous working kernel. Make sure you backup the file first. <\/p>\n<p><textarea name=\"code\" class=\"xml\"><br \/>\n# check for available partitions<br \/>\nfdisk -l<\/p>\n<p># mount partitions to fix lilo.cnf<br \/>\nmount -t ext3 \/dev\/sda3 \/mnt<br \/>\nmount -t ext3 \/dev\/sda1 \/mnt\/boot<br \/>\nchroot \/mnt<\/p>\n<p># edit the file to boot to the previous kernel<br \/>\n# and run lilo to activate the boot sector on harddrive<br \/>\n# should not see any fatal error<br \/>\nvi \/etc\/lilo.conf<br \/>\nlilo -v -v<br \/>\n<\/textarea><\/p>\n<p>Also, if you use &#8220;yum update&#8221; to upgrade the kernel, the default kernel might have too many extra\/redundant modules that might cause the system hang while booting up. If it is the case, use a modified kernel (compile your own) with some minimal modules enabled (can see the modules in \/lib\/modules\/2.6.17.5, change the version if needed).<\/p>\n<p><textarea name=\"code\" class=\"xml\"><br \/>\nlba32<br \/>\nboot=\/dev\/sda<br \/>\ndelay=30<br \/>\nvga=normal<br \/>\nmap=\/boot\/map<br \/>\ndefault=2.6.17.5<\/p>\n<p>image=\/boot\/vmlinuz-2.6.17.5<br \/>\n        label=2.6.17.5<br \/>\n        read-only<br \/>\n        root=\/dev\/sda3<br \/>\n<\/textarea><\/p>\n<p>The files in \/boot<br \/>\n<textarea name=\"code\" class=\"xml\"><br \/>\n[root@s77 boot]# ll<br \/>\ntotal 8444<br \/>\n-rw-r&#8211;r&#8211;  1 root root     512 Sep  8  2005 boot.0300<br \/>\n-rw-r&#8211;r&#8211;  1 root root     512 May 30 02:13 boot.0800<br \/>\n-rw-r&#8211;r&#8211;  1 root root    5824 Jun 15  2004 boot.b<br \/>\n-rw-r&#8211;r&#8211;  1 root root     612 Jun 15  2004 chain.b<br \/>\n-rw-r&#8211;r&#8211;  1 root root   65917 Jul 11 22:52 config-2.6.17-1.2142_FC4<br \/>\n-rw-r&#8211;r&#8211;  1 root root 1097128 Aug 14 21:27 initrd-2.6.17-1.2142_FC4.img<br \/>\ndrwx&#8212;&#8212;  2 root root   12288 Sep  8  2005 lost+found<br \/>\n-rw&#8212;&#8212;-  1 root root   23040 Aug 15 12:27 map<br \/>\n-rw-r&#8211;r&#8211;  1 root root     640 Jun 15  2004 os2_d.b<br \/>\n-rw-r&#8211;r&#8211;  1 root root  773898 Sep  8  2005 System.map-2.6.12.4<br \/>\n-rw-r&#8211;r&#8211;  1 root root  832577 Jul 11 22:52 System.map-2.6.17-1.2142_FC4<br \/>\n-rw-r&#8211;r&#8211;  1 root root  803128 Jul 15 14:18 System.map-2.6.17.5<br \/>\n-rw-r&#8211;r&#8211;  1 root root 1238936 Sep  8  2005 vmlinuz-2.6.12.4<br \/>\n-rw-r&#8211;r&#8211;  1 root root 1803676 Jul 11 22:52 vmlinuz-2.6.17-1.2142_FC4<br \/>\n-rw-r&#8211;r&#8211;  1 root root 1934981 Jul 15 14:17 vmlinuz-2.6.17.5<br \/>\n<\/textarea><\/p>\n","protected":false},"excerpt":{"rendered":"<p>If for some\/many reasons after a kernel upgrade, the system does not reboot. Some hosting control panels can reboot the server into rescue mode. In this mode, you can edit the lilo.conf to go back to the previous working kernel. Make sure you backup the file first. # check for available partitions fdisk -l # [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"_links":{"self":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts\/115"}],"collection":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=115"}],"version-history":[{"count":0,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=\/wp\/v2\/posts\/115\/revisions"}],"wp:attachment":[{"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=115"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.trungson.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}