Learning about grub

Source: Internet
Author: User

Learning about grub
I have installed many ubuntu systems recently and have some knowledge about grub. I will share my recent studies with you today. If you have two ubuntu and windows systems (ubuntu is installed in win7 recently) and want to enable the system to start from windows by default, you should first go to the cd/etc/grub. d directory. The file names of the script files in this directory all start with numbers. below is my/etc/grub. the script file in the d directory determines the sequence in which the content of each file is executed when update-grub is executed, we only need to change the number 30 of the 30_os-prober file name to a number between 05 and 10 (not many options are 06, 07, 08, AND 09), for example, 08_os-prober. Why is it 30_os-prober? Let's open 30_os-prober and see what it is? It can be seen that it is a script to start windows and other systems. It is exactly the script we want to modify. Of course, why is the number between 05 and 10, because 10_linux is the linux Startup Script. Finally, execute sudo update-grub to update the grub. cfg script. In this way, the menu items in the created grub. cfg are automatically sorted before ubuntu.

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.