你好,游客 登录 注册 搜索
背景:
阅读新闻

CentOS 6.4系统内核升级

[日期:2014-01-10] 来源:Linux社区  作者:tongcheng [字体:大 中 小]

CentOS 6.4系统内核升级

1.查看现有系统的内核版本
[root@localhost ~]# uname -a
Linux localhost.localdomain 2.6.32-358.el6.i686 #1 SMP Thu Feb 21 21:50:49 UTC 2013 i686 i686 i386 GNU/Linux
[root@localhost ~]#

2.下载交解压新内核文件
[root@localhost home]# tar xvf linux-2.6.38.7.tar.gz
[root@localhost home]# cd linux-2.6.38.7
[root@localhost linux-2.6.38.7]#

3.升级内核的具体步骤
[root@localhost linux-2.6.38.7]# make mrproper  --清除环境变量,即清除配置文件
[root@localhost linux-2.6.38.7]# make menuconfig  --在菜单模式下选择需要编译的内核模块
networking support  —>  networking options  —>  network packet filtering framework(netfilter)
(1).core netfilter configuration
A 勾中”Netfilter connection tracking support”  -m state相关模块是依赖它的,不选则没有。
B 将netbios name service protocal support(new)    编译成模块,不然后面升级iptables后启动时会出错
C 勾中“Netfilter Xtables support (required for ip_tables)”
(2).IP: Netfilter Configuration
A 将 “IPv4 connection tracking support (require for NAT)” 编译成模块。
B 勾中IP tables support (required for filtering/masq/NAT) 。
C 将 “Full NAT” 下的 “MASQUERADE target support” 和 “REDIRECT target support” 编译成模块
[root@localhost linux-2.6.38.7]# make clean    --确保所有东西均保持最新状态.
[root@localhost linux-2.6.38.7]# make bzImage  --生成内核文件
[root@localhost linux-2.6.38.7]# make modules  --编译模块
[root@localhost linux-2.6.38.7]# make modules_install  --安装模块
[root@localhost linux-2.6.38.7]# make install      --安装
[root@localhost linux-2.6.38.7]# vim /etc/grub.conf
default=0            --将这一行改为0(选择启动时加载哪个内核)
[root@localhost linux-2.6.38.7]# reboot    --重启系统

4. 验证内核是否成功
(1)系统启动时可以看到内核

CentOS 6.4系统内核升级
 
(2)在系统中查看内核

CentOS 6.4系统内核升级

CentOS 6.4系统中编译和升级内核  http://www.linuxidc.com/Linux/2013-08/89325.htm

更多CentOS相关信息见CentOS 专题页面 http://www.linuxidc.com/topicnews.aspx?tid=14

linux
相关资讯       CentOS 6.4 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款