Linux grub-install命令

Linux grub-install命令:在设备上安装GRUB。

Linux grub-install命令 功能描述

使用grub-install命令可以将GRUB安装到指定硬盘或分区上。

Linux grub-install命令 语法

grub-install [选项] [安装设备]

命令中各选项的含义如表所示。



grub-install命令选项含义

Linux grub-install命令 示例

安装GRUB到/dev/sda1分区的第一个扇区中

[root@rhel ~]# grub-install /dev/sda1
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script 'grub-install'.
# this device map was generated by anaconda
(hd0)  /dev/sda

安装GRUB到主引导扇区中

[root@rhel ~]# grub-install /dev/sda
Installation finished. No error reported.
This is the contents of the device map /boot/grub/device.map.
Check if this is correct or not. If any of the lines is incorrect,
fix it and re-run the script 'grub-install'.
# this device map was generated by anaconda
(hd0)  /dev/sda
赞(0)
未经允许不得转载:极客笔记 » Linux grub-install命令
分享到: 更多 (0)

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址