{"id":1306,"date":"2009-11-05T19:29:04","date_gmt":"2009-11-05T11:29:04","guid":{"rendered":"http:\/\/akuadi.org\/life\/?p=1306"},"modified":"2009-11-22T13:53:27","modified_gmt":"2009-11-22T05:53:27","slug":"compiled-kernel-2-6-31-5-on-centos-5-4","status":"publish","type":"post","link":"https:\/\/akuadi.org\/life\/blog\/2009\/11\/05\/compiled-kernel-2-6-31-5-on-centos-5-4\/","title":{"rendered":"Compile Linux Kernel 2.6.31.5 on Centos 5.4"},"content":{"rendered":"<blockquote><p>[root@server1 ~]# uname -a;date;uptime<br \/>\nLinux server1 2.6.18-164.el5 #1 SMP Thu Sep 3 03:33:56 EDT 2009 i686 athlon i386 GNU\/Linux<br \/>\nSat Oct 24 20:51:19 MYT 2009<br \/>\n20:51:19 up 4 min,\u00a0 2 users,\u00a0 load average: 0.24, 0.36, 0.16<br \/>\n[root@server1 ~]# cat \/etc\/redhat-release<br \/>\nCentOS release 5.4 (Final)<\/p><\/blockquote>\n<blockquote><p><strong>Download Kernel file from kernel.org, but it depends on your internet connection.<\/strong><\/p>\n<p>[root@server1 ~]# cd \/usr\/src<br \/>\n[root@server1 src]# wget <a href=\"http:\/\/www.kernel.org\/pub\/linux\/kernel\/v2.6\/linux-2.6.31.5.tar.bz2\" target=\"_blank\" rel=\"noopener\">http:\/\/www.kernel.org\/pub\/linux\/kernel\/v2.6\/linux-2.6.31.5.tar.bz2<\/a><br \/>\n&#8211;2009-10-24 20:56:56&#8211;\u00a0 <a href=\"http:\/\/www.kernel.org\/pub\/linux\/kernel\/v2.6\/linux-2.6.31.5.tar.bz2\" target=\"_blank\" rel=\"noopener\">http:\/\/www.kernel.org\/pub\/linux\/kernel\/v2.6\/linux-2.6.31.5.tar.bz2<\/a><br \/>\nResolving www.kernel.org&#8230; 199.6.1.164, 204.152.191.37, 130.239.17.4, &#8230;<br \/>\nConnecting to www.kernel.org|199.6.1.164|:80&#8230; connected.<br \/>\nHTTP request sent, awaiting response&#8230; 200 OK<br \/>\nLength: 61448996 (59M) [application\/x-bzip2]<br \/>\nSaving to: `linux-2.6.31.5.tar.bz2&#8242;<\/p>\n<p>2% [&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 ] 1,554,891\u00a0\u00a0\u00a0 212K\/s\u00a0 eta 7m 18s<\/p>\n<p><!--more--><\/p><\/blockquote>\n<blockquote><p>make sure that your system already have gcc.<\/p>\n<p>[root@server1 src]# yum install gcc<br \/>\nLoaded plugins: fastestmirror<br \/>\nDetermining fastest mirrors<br \/>\n* addons: centos.maulvi.net<br \/>\n* base: centos.maulvi.net<br \/>\n* extras: centos.maulvi.net<br \/>\n* updates: centos.maulvi.net<br \/>\naddons\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 |\u00a0 951 B\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\naddons\/primary\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 |\u00a0 201 B\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nbase\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 | 2.1 kB\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nbase\/primary_db\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 | 1.6 MB\u00a0\u00a0\u00a0\u00a0 00:12<br \/>\nextras\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 | 1.1 kB\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nextras\/primary\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 | 107 kB\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nextras\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 324\/324<br \/>\nupdates\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 |\u00a0 951 B\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nupdates\/primary\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 |\u00a0 202 B\u00a0\u00a0\u00a0\u00a0 00:00<br \/>\nSetting up Install Process<br \/>\nPackage gcc-4.1.2-46.el5.i386 already installed and latest version<br \/>\nNothing to do<\/p><\/blockquote>\n<blockquote><p>Tar the file<\/p>\n<p>[root@server1 src]# tar -xjvf linux-2.6.31.5.tar.bz2<\/p>\n<p>[root@server1 linux-2.6.31.5]#make menuconfig<\/p><\/blockquote>\n<p align=\"center\"><a href=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132337.png\"><img decoding=\"async\" style=\"border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px\" title=\"Red Hat Enterprise Linux 5-2009-10-24-13-23-37\" src=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132337_thumb.png\" border=\"0\" alt=\"Red Hat Enterprise Linux 5-2009-10-24-13-23-37\" width=\"244\" height=\"137\" \/><\/a><\/p>\n<p align=\"center\"><a href=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132355.png\"><img decoding=\"async\" style=\"border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px\" title=\"Red Hat Enterprise Linux 5-2009-10-24-13-23-55\" src=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132355_thumb.png\" border=\"0\" alt=\"Red Hat Enterprise Linux 5-2009-10-24-13-23-55\" width=\"244\" height=\"137\" \/><\/a><\/p>\n<p align=\"center\"><a href=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132444.png\"><img decoding=\"async\" style=\"border-bottom: 0px; border-left: 0px; display: inline; border-top: 0px; border-right: 0px\" title=\"Red Hat Enterprise Linux 5-2009-10-24-13-24-44\" src=\"http:\/\/akuadi.org\/life\/wp-content\/uploads\/2009\/11\/RedHatEnterpriseLinux520091024132444_thumb.png\" border=\"0\" alt=\"Red Hat Enterprise Linux 5-2009-10-24-13-24-44\" width=\"244\" height=\"137\" \/><\/a><\/p>\n<blockquote><p>[root@server1 linux-2.6.31.5]# make<\/p>\n<p>[root@server1 linux-2.6.31.5]# make modules<br \/>\nCHK\u00a0\u00a0\u00a0\u00a0 include\/linux\/version.h<br \/>\nCHK\u00a0\u00a0\u00a0\u00a0 include\/linux\/utsrelease.h<br \/>\nSYMLINK include\/asm -&gt; include\/asm-x86<br \/>\nCALL\u00a0\u00a0\u00a0 scripts\/checksyscalls.sh<br \/>\nBuilding modules, stage 2.<br \/>\nMODPOST 1019 modules<\/p>\n<p>[root@server1 linux-2.6.31.5]# make modules_install<\/p><\/blockquote>\n<blockquote><p>[root@server1 linux-2.6.31.5]# make install<br \/>\nsh \/usr\/src\/linux-2.6.31.5\/arch\/x86\/boot\/install.sh 2.6.31.5 arch\/x86\/boot\/bzImage \\<br \/>\nSystem.map &#8220;\/boot&#8221;<\/p>\n<p>[root@server1 linux-2.6.31.5]# cat \/boot\/grub\/menu.lst<br \/>\n# grub.conf generated by anaconda<br \/>\n#<br \/>\n# Note that you do not have to rerun grub after making changes to this file<br \/>\n# NOTICE:\u00a0 You have a \/boot partition.\u00a0 This means that<br \/>\n#\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 all kernel and initrd paths are relative to \/boot\/, eg.<br \/>\n#\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 root (hd0,0)<br \/>\n#\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 kernel \/vmlinuz-version ro root=\/dev\/VolGroup00\/LogVol00<br \/>\n#\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 initrd \/initrd-version.img<br \/>\n#boot=\/dev\/sda<br \/>\ndefault=1<br \/>\ntimeout=5<br \/>\nsplashimage=(hd0,0)\/grub\/splash.xpm.gz<br \/>\nhiddenmenu<br \/>\ntitle CentOS (2.6.31.5)<br \/>\nroot (hd0,0)<br \/>\nkernel \/vmlinuz-2.6.31.5 ro root=\/dev\/VolGroup00\/LogVol00<br \/>\ninitrd \/initrd-2.6.31.5.img<br \/>\ntitle CentOS (2.6.18-164.el5)<br \/>\nroot (hd0,0)<br \/>\nkernel \/vmlinuz-2.6.18-164.el5 ro root=\/dev\/VolGroup00\/LogVol00<br \/>\ninitrd \/initrd-2.6.18-164.el5.img<br \/>\n[root@server1 linux-2.6.31.5]#<\/p><\/blockquote>\n<p>Then rebooted your system.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>[root@server1 ~]# uname -a;date;uptime Linux server1 2.6.18-164.el5 #1 SMP Thu Sep 3 03:33:56 EDT 2009 i686 athlon i386 GNU\/Linux Sat Oct 24 20:51:19 MYT 2009 20:51:19 up 4 min,\u00a0 2 users,\u00a0 load average: 0.24, 0.36, 0.16 [root@server1 ~]# cat \/etc\/redhat-release CentOS release 5.4 (Final) Download Kernel file from kernel.org, but it depends on your internet [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[74],"tags":[],"class_list":["post-1306","post","type-post","status-publish","format-standard","hentry","category-kernel"],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/posts\/1306","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/comments?post=1306"}],"version-history":[{"count":0,"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/posts\/1306\/revisions"}],"wp:attachment":[{"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/media?parent=1306"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/categories?post=1306"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/akuadi.org\/life\/wp-json\/wp\/v2\/tags?post=1306"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}