CentOS GRUB更改GRUB启动菜单
原文地址:blog.csdn/jzbgjsy/article/details/5337425

一、为什么需要更改CentOS GRUB呢?
1.当CentOS更新新的内核后,GRUB会自动加上新的kernel开机选项,导致开机选项越来越多,想将不必要的开机选项刪除.
2.CentOS GRUB预设开机为CentOS,你可以想将预设开机改成Windows.
3.修改预设CentOS GRUB等待时間.什么电脑是linux
4.预设不显示GRUB menu,直接進入Windows.
二、设置
开啟CentOS GRUB开机选项档 gedit /boot/grub/menu.lst
1.当CentOS更新新的kernel后,CentOS GRUB会自动加上新的kernel开机选项,导致开机选项越来越多,想将不必要的开机选项刪除.
  以下为我所要的开机选项,不需要者可自行刪除之
## ## End Default Options ##
title        Ubuntu, kernel 2.6.20-16-generic
root        (hd0,6)
kernel        /boot/vmlinuz-2.6.20-16-generic root=UUID=b923ef76-3246-411c-8095-7bca666b13a5 ro quiet splash
initrd        /boot/initrd.img-2.6.20-16-generic
quiet
savedefault
title        Ubuntu, kernel 2.6.20-16-generic (recovery mode)
root        (hd0,6)
kernel        /boot/vmlinuz-2.6.20-16-generic root=UUID=b923ef76-3246-411c-8095-7bca666b13a5 ro single
centos和ubuntuinitrd        /boot/initrd.img-2.6.20-16-generic
# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title        Microsoft Windows XP Professional转unicode
root        (hd0,0)
savedefault
makeactive
chainloader    +1
 
2.CentOS GRUB预设开机为Ubuntu,你可以想将预设开机改成Windows.
## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
静态结构体数组初始化# WARNING: If you are using dmraid do not change this entry to 'saved' or yournetty是什么意思
# array will desync and will not let you boot your system.
default        2
预设default 0,表示开机用Ubuntu开机,因为在我的电脑Windows为第三個选项,default2
3.修改预设CentOS GRUB等待时间.
## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout        3
预设为10秒钟,我改成等待3秒钟
4.不显示CentOS GRUB menu,直接進入Windows.html网页聊天室代码
## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
hiddenmenu
预设会显示GRUB menu,若你不想显示menu,要当按下ESC才显示,请将hiddenmenu前的#拿掉

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。