关于路由器CPU利用率过高的解决方案
2008-03-21 13:12
253 查看
系统环境:Centos5.2
硬件环境:Dell Optiplex 320
安装完成后使用Centos5.2 CD引导系统,进入系统后,再使用chroot切换到我们前面安装在硬盘的Centos5.2 ,最后在Centos5.2 上安装Grub2就可以了,使用Centos5.2 CD引导系统启动完毕后,打开终端使用如下命令chroot到硬盘中的我们安装的Centos5.2:
当系统显示boot的时候,输入命令:
linux rescue进入系统,进入系统后运行下面命令,
#chroot /mnt/sysimage
查看磁盘信息
#fdisk -l
分别列出当前磁盘的信息,如下:
.....
/dev/sda1 * ......... Linux
/dev/sda2 ........... Linux swap /Solaris
/dev/sda3 ........... Linux
我只分了三个,当然具体信息根据自己的机器来..
先创建一个目录,用于加载硬盘中的系统
#mkdir /media/root加载硬盘中的root分区,我这里的root分区是:/dev/sda3
#mount /dev/sda3 /media/root如果您有单独的boot分区,再加载boot分区,我的boot分区是:/dev/sda1
#mount /dev/sda1 /media/root/boot然后,将系统中的proc和dev加载到/media/root中,以便后续的chroot
#mount -t proc none /media/root/proc
#mount -o bind /dev /media/root/dev 最后使用chroot切换到硬盘中的系统
#chroot /media/root
卸载系统自带的grub,
#yum -y erase grub
下载grub-1.96或是更高版进行编译安装
安装时候会提示安装LZO library version 1.02或更高版,
Lzo下载地址:http://www.oberhumer.com/opensource/lzo/download/lzo-2.03.tar.gz
grub1.96下载地址:ftp://alpha.gnu.org/gnu/grub/grub-1.96.tar.gz
Lzo安装完成后开始安装Grub1.96
#./configure --prefix=/boot/grub2
#make
#make install
接着,将Grub2安装到硬盘的引导扇区中
#/boot/grub2/sbin/grub-install /dev/sda
然后,使用如下命令更新Grub2配置,自动发现系统可引导内核:
#/boot/grub2/sbin/update-grub提示/boot/grub2/sbin/update-grub:line 73:grub-probe:command not found
#vim update-grub 中的73,77,80行中grub-prode更改为如下:
/boot/grub2/sbin/grub-probe
保存后再执行/boot/grub2/sbin/update-grub显示成功
最后,和前面安装系统时类似的原因,我们要关闭内核的acpi支持,不然,虽然Grub2能够支持SATA引导系统,但是还是会因为acpi的原因而引导失败(msi非活动错误),修改/boot/grub/grub.cfg(Grub2的启动配置文件是grub.conf而不是menu.lsf)在启动文件中加入acpi=off,将:
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15 (single-user mode)" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro single
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}修改为:
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro acpi=off
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15 (single-user mode)" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro single acpi=off
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Microsoft Windows XP Professional" {
set root=(hd0,1)
chainloader +1
}
如果是双系统只要在前面加一段就OK了
强制保存退出,因为此文件是个只读文件,要不然保存不了.
按三次exit后重新启动,这时候您应该注意到引导时的Grub显示的是1.95的版本,(如果不是的话,嘿嘿,那就是前面Grub2安装的不对,请回去检查。)系统也正常的启动了!
大功告成!
本文出自 “hidly” 博客,请务必保留此出处http://380759.blog.51cto.com/370759/200550
硬件环境:Dell Optiplex 320
安装完成后使用Centos5.2 CD引导系统,进入系统后,再使用chroot切换到我们前面安装在硬盘的Centos5.2 ,最后在Centos5.2 上安装Grub2就可以了,使用Centos5.2 CD引导系统启动完毕后,打开终端使用如下命令chroot到硬盘中的我们安装的Centos5.2:
当系统显示boot的时候,输入命令:
linux rescue进入系统,进入系统后运行下面命令,
#chroot /mnt/sysimage
查看磁盘信息
#fdisk -l
分别列出当前磁盘的信息,如下:
.....
/dev/sda1 * ......... Linux
/dev/sda2 ........... Linux swap /Solaris
/dev/sda3 ........... Linux
我只分了三个,当然具体信息根据自己的机器来..
先创建一个目录,用于加载硬盘中的系统
#mkdir /media/root加载硬盘中的root分区,我这里的root分区是:/dev/sda3
#mount /dev/sda3 /media/root如果您有单独的boot分区,再加载boot分区,我的boot分区是:/dev/sda1
#mount /dev/sda1 /media/root/boot然后,将系统中的proc和dev加载到/media/root中,以便后续的chroot
#mount -t proc none /media/root/proc
#mount -o bind /dev /media/root/dev 最后使用chroot切换到硬盘中的系统
#chroot /media/root
卸载系统自带的grub,
#yum -y erase grub
下载grub-1.96或是更高版进行编译安装
安装时候会提示安装LZO library version 1.02或更高版,
Lzo下载地址:http://www.oberhumer.com/opensource/lzo/download/lzo-2.03.tar.gz
grub1.96下载地址:ftp://alpha.gnu.org/gnu/grub/grub-1.96.tar.gz
Lzo安装完成后开始安装Grub1.96
#./configure --prefix=/boot/grub2
#make
#make install
接着,将Grub2安装到硬盘的引导扇区中
#/boot/grub2/sbin/grub-install /dev/sda
然后,使用如下命令更新Grub2配置,自动发现系统可引导内核:
#/boot/grub2/sbin/update-grub提示/boot/grub2/sbin/update-grub:line 73:grub-probe:command not found
#vim update-grub 中的73,77,80行中grub-prode更改为如下:
/boot/grub2/sbin/grub-probe
保存后再执行/boot/grub2/sbin/update-grub显示成功
最后,和前面安装系统时类似的原因,我们要关闭内核的acpi支持,不然,虽然Grub2能够支持SATA引导系统,但是还是会因为acpi的原因而引导失败(msi非活动错误),修改/boot/grub/grub.cfg(Grub2的启动配置文件是grub.conf而不是menu.lsf)在启动文件中加入acpi=off,将:
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15 (single-user mode)" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro single
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}修改为:
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro acpi=off
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Debian GNU/Linux, linux 2.6.18-92.e15 (single-user mode)" {
linux (hd0,1)/vmlinuz-2.6.18-92.e15 root=/dev/sda3 ro single acpi=off
initrd (hd0,1)/initrd.img-2.6.18-92.e15.img
}
menuentry "Microsoft Windows XP Professional" {
set root=(hd0,1)
chainloader +1
}
如果是双系统只要在前面加一段就OK了
强制保存退出,因为此文件是个只读文件,要不然保存不了.
按三次exit后重新启动,这时候您应该注意到引导时的Grub显示的是1.95的版本,(如果不是的话,嘿嘿,那就是前面Grub2安装的不对,请回去检查。)系统也正常的启动了!
大功告成!
本文出自 “hidly” 博客,请务必保留此出处http://380759.blog.51cto.com/370759/200550
相关文章推荐
- 关于路由器CPU利用率过高的解决方案
- 关于路由器cpu利用率过高的解决
- 路由器CPU利用率过高的解决方法
- 思科路由器CPU利用率过高的故障
- 路由器CPU利用率过高的解决方法
- 路由器CPU利用率过高的解决方法
- [zz]存大量被占用(kswap进程CPU利用率过高)的解决方案
- 关于svchost.exe的CPU占用率过高的原因以及解决方法
- CPU、内存利用率过高问题排查(模拟)
- 关于win8系统开机后cpu占用率过高的问题
- [Oracle]Oracle数据库CPU利用率很高解决方案
- 关于"该主机 CPU 类型不支持虚拟化性能计数器"的解决方案
- Linux下xorg进程CPU占用率过高时的一个解决方案
- svchost.exe占用过高CPU和内存的解决方案
- 关于Memcached客户端CPU过高问题的排查
- 路由器CPU过高
- window系统svchost.exe占用CPU或者内存过高的解决方案
- 关于Memcached客户端CPU过高问题的排查
- 内核线程和用户态进程的cpu利用率过高时的调试方法
- 关于可剥夺式进程调度方案,计算CPU利用率的题目