1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

LinuxのOS起動メニューにWindowsを追加する

Last updated at Posted at 2020-03-06

LinuxのOS起動メニューにWindowsを追加する

  • 40_customファイルを開く
vi /ect/grub.d/40_custom
  • 40_customファイルに下記内容を記述する
menuentry "Windows 7" {
    set root='(hd0,1)'
    chainloader +1
}
  • 40_customファイルの変更を反映する
grub2-mkconfig -o /boot/grub2/grub.cfg

LinuxのOS起動メニューでWindowsをデフォルトの起動OSに設定する

  • grubファイルを開く
vi /etc/default/grub
  • grubファイルのGRUB_DEFAULTの値を変更する
    LinuxのOS起動メニューにWindowsが2番目に表示されている場合は、2から1を引いた値の1を記述する
GRUB_DEFAULT=1
  • grubファイルの変更を反映する
grub2-mkconfig -o /boot/grub2/grub.cfg
  • Linuxを再起動する
sudo shutdow -r now
1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?