CentOS 7 grub Linux 修改默认的启动操作系统
2015-08-05 19:29
543 查看
可以用下面的方法修改grub默认的启动OS。
;查看当前的启动内核
root@localhost ~]# grub2-editenvlist
saved_entry=CentOS Linux(3.10.0-123.20.1.el7.x86_64) 7 (Core)
;查找要默认启动的操作系统名字
[root@localhost ~]# cat /etc/grub2.cfg | grep 3.4.44
menuentry 'CentOS Linux (3.4.44) 7(Core)'
--class centos --class gnu-linux --class gnu --class os--unrestricted $menuentry_id_option'gnulinux-3.10.0-123.el7.x86_64-advanced-e3146a2a-a237-4081-ba08-dbf258de434a'{
linux16 /vmlinuz-3.4.44 root=/dev/mapper/centos-rootro rd.lvm.lv=centos/swap vconsole.font=latarcyrheb-sun16 rd.lvm.lv=centos/rootcrashkernel=auto
vconsole.keymap=us rhgbquiet LANG=en_US.UTF-8
initrd16 /initramfs-3.4.44.img
;设置新的默认启动操作系统选项
[root@localhost ~]# grub2-set-default
"CentOSLinux (3.4.44) 7 (Core)"
;查看是否生效
[root@localhost ~]# grub2-editenv list
saved_entry=CentOS Linux (3.4.44) 7 (Core)
可以用下面的方法修改grub默认的启动OS。
;查看当前的启动内核
root@localhost ~]# grub2-editenvlist
saved_entry=CentOS Linux(3.10.0-123.20.1.el7.x86_64) 7 (Core)
;查找要默认启动的操作系统名字
[root@localhost ~]# cat /etc/grub2.cfg | grep 3.4.44
menuentry 'CentOS Linux (3.4.44) 7(Core)'
--class centos --class gnu-linux --class gnu --class os--unrestricted $menuentry_id_option'gnulinux-3.10.0-123.el7.x86_64-advanced-e3146a2a-a237-4081-ba08-dbf258de434a'{
linux16 /vmlinuz-3.4.44 root=/dev/mapper/centos-rootro rd.lvm.lv=centos/swap vconsole.font=latarcyrheb-sun16 rd.lvm.lv=centos/rootcrashkernel=auto
vconsole.keymap=us rhgbquiet LANG=en_US.UTF-8
initrd16 /initramfs-3.4.44.img
;设置新的默认启动操作系统选项
[root@localhost ~]# grub2-set-default
"CentOSLinux (3.4.44) 7 (Core)"
;查看是否生效
[root@localhost ~]# grub2-editenv list
saved_entry=CentOS Linux (3.4.44) 7 (Core)
相关文章推荐
- Centos7下安装MPlay和VLC
- linux下启动和关闭网卡命令
- linux下c语言实现简单----线程池
- Ubuntu Linux上安装java jdk的方法
- [转]手工释放linux内存——/proc/sys/vm/drop_caches
- linux下搭建SVN服务器
- linux下搭建SVN服务器
- Linux常用命令
- linux定时器
- Linux操作系统下测试磁盘读写速度
- QUEUEING IN THE LINUX NETWORK STACK
- Hadoop集群(第1期)CentOS安装配置
- Linux du 和 df 的区别
- linux设备驱动makefile入门解析
- linux 下配置objectiveC环境记录
- linux 下解决timewait 过多的问题
- linux
- 用vnc实现windows远程连接linux桌面
- (7) linux 编译并安装mysql-5.6.15.tar.gz ---> CentOS-6.6-x86_64 + mysql-5.6.15.tar.gz
- 在Linux里设置环境变量的方法(export PATH)