Permanently modify the startup sequence of grub2

Source: Internet
Author: User
Permanent modification of the grub2 startup sequence grub2 determines the sequence of startup items through the file sequence in the etcgrubd Directory: [html] $ cdetcgrubd $ ls-l-rwxr-xr-x1rootroot6743 September 13 201200_header-rwxr-xr-x1rootroo permanently modifies the grub2 startup sequence through/etc/grub. d/directory file order to determine the sequence of startup items: [html] $ cd/etc/grub. d $ ls-l-rwxr-xr-x 1 root 6743 September 13 2012 00_header-rwxr-xr-x 1 root 5522 April 18 2012 05_debian_theme-rw-r -- 1 root root 7603, December April 18, 2012 08_os-prober-rwxr-xr-x 1 root 7780, December January 23 2013 10_linux-rwxr-xr-x 1 root 7603 September 20 13:48 17_oss-prober-rwxr-xr-x 1 root 6335 April 18 2012 20_linux_xen-rwxr-xr-x 1 root 1588 November 27 2011 20_memtest86 +-rwxr-xr-x 1 root 1388 January 23 30_uefi-firmware-rwxr-xr-x 1 root 2013 April 18 214 40_custom-rwxr-xr-x 1 root 95 April 18 2012 41_custom-rw-r -- 1 root 483 February April 18 2012 README 08_os-prober was changed for the default startup item win8 Because it is now changed to ubuntu as the default boot, the 08_os-prober permission is changed to unexecutable. This directory has a readme translation: the executable files under this directory are arranged in the order of shell Extension (that is, by the first character, used to configure the order of grub ). Files starting with "00 _" are reserved for files starting with "10 _" of "00_header". files starting with "20 _" of the system itself can be created or changed by third-party programs to configure the startup sequence of "gurb2. It's easy to know the above. We only need to set the order of 08_os-prober to 10_linux, so that the windows option can be later than linux. Run the following command to copy 08_os-prober and rename it to 17_os-prober: [html] $ sudo cp 08_osprober 17_osprober [html] $ sudo chmod 644 08_os-prober // remove the executable permission of 08_oss-prober $ ls-l-rwxr-xr-x 1 root 6743 2012 00_header-rwxr-xr-x 1 root 5522 September 2012 7603 2012 05_debian_theme-rw-r -- 1 root 7780 September 2013 08_o-prober-rwxr-xr-x 1 root September 10_linux-rwxr-xr-x 1 root 7603 September 20 13:48 17_oss-prober-rwxr-xr-x 1 root 6335 April 18 2012 20_linux_xen-rwxr-xr-x 1 root 1588 2011 20_memtest86 +-rwxr-xr-x 1 root 1388 2013 214 30_uefi-firmware-rwxr-xr-x 1 root 2012 2012 40_custom-rwxr-xr-x 1 root 95 41_custom -rw-r -- 1 root 483 April 18 2012 README and then open the/etc/default/grub file to change the default startup item to the one you want: [html] $ sudo vim/etc/default/grub find GRUB_DEFAULT = and change it to 9. (Because linux starts counting from 0) update grub: sudo update-grub.
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.