1 雙啟動
一是修改預設的啟動項,就是說預設是Windows呢,還是預設是Linux呢;第二個是修改啟動項的位置。其實這二個都不是什麼問題,需要修改Linux下的一個設定檔,該檔案是:/boot/grub/grub.conf,以文字檔方式開啟,我的grub.conf設定檔是:
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,4)
# kernel /vmlinuz-version ro root=/dev/hda7
# initrd /initrd-version.img
#boot=/dev/hda
default=1
timeout=5
gfxmenu (hd0,4)/message
title RedFlag (2.6.22.6-1)
root (hd0,4)
kernel /vmlinuz-2.6.22.6-1 ro root=LABEL=/ vga=788 splash=silent
initrd /initrd-2.6.22.6-1.img
title Windows Vista(SP1)
rootnoverify (hd0,0)
chainloader +1
注意從 #boot=/dev/hda 行看,default=1表示預設的啟動項是第二個,0表示第一個,1表示第二個,以此類推。
timeout=5表示預設的等待時間(單位秒)。再往下看,有兩個啟動項:
title RedFlag (2.6.22.6-1)
root (hd0,4)
kernel /vmlinuz-2.6.22.6-1 ro root=LABEL=/ vga=788 splash=silent
initrd /initrd-2.6.22.6-1.img
這個是Linux啟動項,還有:
title Windows Vista(SP1)
rootnoverify (hd0,0)
chainloader +1
這個是Vista啟動項。
2 修改 啟動層級 linux
以管理員身份進入Linux,修改檔案:/etc/inittab
找到“id:5:initdefault:”,其中的5就是X-Window,為預設運行層級,一般我們把5改為3即可。
一共有7種啟動層級,分別為:
# 0 - halt (Do NOT set initdefault to this)
# 1 - Single user mode
# 2 - Multiuser, without NFS (The same as 3, if you do not have networking)
# 3 - Full multiuser mode
# 4 - unused
# 5 - X11
# 6 - reboot (Do NOT set initdefault to this)
各個運行級的詳細解釋:
0 為停機,機器關閉。
1 為單一使用者模式,就像Win9x下的安全模式類似。
2 為多使用者模式,但是沒有NFS支援。
3 為完整的多使用者模式,是標準的運行級。
4 一般不用,在一些特殊情況下可以用它來做一些事情。例如在膝上型電腦的電池用盡時,可以切換到這個模式來做一些設定。
5 就是X11,進到X Window系統了。
6 為重啟,運行init 6機器就會重啟。
0和6一般不用;
運行startx可啟動到層級5。