How to set Windows bootloader as default bootloader?
Solution 1
There is a programm for windows called easy bcd. Install it when running windows and the proceed a described in the following link:
Nevertheless I think also the other answers are valid as the question was basically how to avoid that the sister is scared by grub to choose windows if necessary.
Solution 2
Edit that file, from terminal run
sudo gedit /etc/default/grub
(file has comments to help you). Find that line and set Windows number (number of Windows line in Grub, starting from 0). In my case that will be
GRUB_DEFAULT=2
Then save file and close gedit. Run that command to update grub:
sudo update-grub
Solution 3
PART 1:
Make Windows (ANY variant) the default Grub2 menu option.
Description: This sets Windows as the default boot option, and (with NO user action) the PC will auto-launch Windows on startup.
STEPS:
A. List your current menu items
sudo update-grub
B. Edit setup file
sudo gedit /etc/default/grub
Set the boot default to your Windows boot partition (eg.)
GRUB_DEFAULT=”Windows 7 (loader) on /dev/sda1″
WARNING: Just setting 'GRUB_DEFAULT=n', will NOT work after kernel updates, etc.
(Save the file and close.)
C. Update grub settings
sudo update-grub
Now, on boot, you will AUTOMATICALLY default to MS Windows.
PART 2: (Optional Extra)
Hide the Grub2 menu, and use the default menu option.
Description: This both hides the startup menu, and shortens the (usually 10 second) timeout. The PC will auto-launch whatever the default option is on startup.
NOTE: The user just needs to hold down the Shift key (on startup), to again see the Grub2 menu.
STEPS:
D. Edit setup file
sudo gedit /etc/default/grub
Uncomment the line '#GRUB_HIDDEN_TIMEOUT=0', to look like:
GRUB_HIDDEN_TIMEOUT=0
(Save the file and close.)
E. Update grub settings
sudo update-grub
Now, on boot, you will AUTOMATICALLY boot to the default menu option, UNLESS you hold down the Shift-key at boot time. Then the grub2 menu will re-appear.
FURTHER DOCUMENTATION:
http://ubuntuforums.org/showthread.php?t=1195275
Solution 4
Grub2 can be set to boot any system by default, but to change the order they appear in would be difficult.
It is also possible to hide the grub boot menu (for your sister) and only show it by pressing the shift key. I recommend caution here. Details here.
There are two ways setting the default boot using editing a grub file.
These are described in the Ubuntu Communuity Documentation Grub2 page
The two ways are
-
Boot which ever operating system you booted last time, the "saved method"
This is the on I use. It lets me decide which one I going to use and will allow me to reboot into that system, handy when I'm updating.
Boot a specific operating system by default, your exact question
To start we need to find out what we are booting, open a terminal (dash, type terminal, … ) and type in grep menuentry /boot/grub/grub.cfg
user@YourComputer:~$ grep menuentry /boot/grub/grub.cfg
menuentry 'Ubuntu, with Linux 2.6.35-31-generic' --class ubuntu --class gnu-linux --class gnu --class os {
menuentry 'Ubuntu, with Linux 2.6.35-31-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
menuentry 'Ubuntu, with Linux 2.6.35-30-generic' --class ubuntu --class gnu-linux --class gnu --class os {
menuentry 'Ubuntu, with Linux 2.6.35-30-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
menuentry "Memory test (memtest86+)" {
menuentry "Memory test (memtest86+, serial console 115200)" {
menuentry "Windows NT/2000/XP (loader) (on /dev/sda1)" {
menuentry "Ubuntu, with Linux 2.6.32-34-generic (on /dev/sdb1)" {
menuentry "Ubuntu, with Linux 2.6.32-34-generic (recovery mode) (on /dev/sdb1)" {
menuentry "Ubuntu, with Linux 2.6.32-33-generic (on /dev/sdb1)" {
menuentry "Ubuntu, with Linux 2.6.32-33-generic (recovery mode) (on /dev/sdb1)" {
menuentry "Windows Vista (loader) (on /dev/sdc1)" {
From mine you can see why I prefer the "saved" method.
Now you are ready to edit the grub file…
- Note: If you would rather use a GUI editor like Gnome Text editor, see the note at the end.
Type in the terminal sudo nano -B /etc/default/grub and your password if asked
user@YourComputer:~$ sudo nano -B /etc/default/grub
and the nano editor will open, thus (for mine)...
# If you change this file, run 'update-grub' afterwards to update
# /boot/grub/grub.cfg.
GRUB_DEFAULT=saved
#GRUB_HIDDEN_TIMEOUT=0
GRUB_HIDDEN_TIMEOUT_QUIET=true
GRUB_TIMEOUT=10
GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
#GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"
GRUB_CMDLINE_LINUX_DEFAULT="delayacct"
GRUB_CMDLINE_LINUX=""
# Uncomment to enable BadRAM filtering, modify to suit your needs
# This works with Linux (no patch required) and with any kernel that obtains
# the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
#GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"
# Uncomment to disable graphical terminal (grub-pc only)
#GRUB_TERMINAL=console
# The resolution used on graphical terminal
# note that you can use only modes which your graphic card supports via VBE
# you can see them in real GRUB with the command `vbeinfo'
#GRUB_GFXMODE=640x480
GRUB_GFXMODE=1280x800
GRUB_GFXPAYLOAD_LINUX=1280x800x8
# Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
#GRUB_DISABLE_LINUX_UUID=true
# Uncomment to disable generation of recovery mode menu entries
#GRUB_DISABLE_LINUX_RECOVERY="true"
# Uncomment to get a beep at grub start
GRUB_INIT_TUNE="480 440 1"
GRUB_SAVEDEFAULT=true
GRUB_BACKGROUND=/usr/share/images/grub/Apollo_17_The_Last_Moon_Shot_Edit1.tga
In my preferred way, I made these changes from the standard grub file:
- I changed the value of GRUB_DEFAULT to "saved"
GRUB_DEFAULT=saved
- and I added this line…
GRUB_SAVEDEFAULT=true
In the way you are asking far to this
- Change the value of GRUB_DEFAULT to the name of the Windows system you want to always boot. This will be found in the previous
grep …
output prior. For my system if I wanted to only allways boot my Window XP, I set GRUB_DEFAULT to "Windows NT/2000/XP (loader) (on /dev/sda1)", everything between the "'s.
GRUB_DEFAULT="Windows NT/2000/XP (loader) (on /dev/sda1)"
You could set GRUB_DEFAULT to the line number in the menu entry list (with 0 being the first), but when the kernel in Ubuntu is updated grub adds the new kernel to the top of the list, you would have to change the number, since Windows is the last one in the menu entry list. You can see this in my menu entry list.
Important last step
Now you have to run update-grub to update the system generated grub.cfg file in the /boot/grub directory.
Type into your computer sudo update-grub and your password if asked…
user@YourComputer:~$ sudo update-grub
Generating grub.cfg ...
Found background: /usr/share/images/grub/Apollo_17_The_Last_Moon_Shot_Edit1.tga
Found linux image: /boot/vmlinuz-2.6.35-31-generic
Found initrd image: /boot/initrd.img-2.6.35-31-generic
Found linux image: /boot/vmlinuz-2.6.35-30-generic
Found initrd image: /boot/initrd.img-2.6.35-30-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Windows NT/2000/XP (loader) on /dev/sda1
Found Ubuntu 10.04.3 LTS (10.04) on /dev/sdb1
Found Windows Vista (loader) on /dev/sdc1
done
Notes on nano
nano is especally easy to use in the terminal. Move around with the arrow keys. Type in you addtions, delete the unwanted.
The " -B" (or " --backup") option backs up the previous version of it to the current filename suffixed with a ~. Very handy in case of the dreaded Fat pfinger effect.
When you are though, Crtl-O will allow you to save your edits by hitting Enter. Closing nano without saving, Ctrl-X These and other options are shown at the bottom of the terminal screen with the ^ indicating Ctrl
^G Get Help ^O WriteOut ^R Read File ^Y Prev Page ^K Cut Text ^C Cur Pos
^X Exit ^J Justify ^W Where Is ^V Next Page ^U UnCut Text ^T To Spell
Notes about nano, sudoeditor, and other editors.
Some in the Ubuntu community suggest sudoedit instead of nano. I recommend nano (which is the default sudoedit editor in later distributions of Ubuntu) instead of sudoedit because the default can be overridden in non-obvious ways (unless you are an administrator). sudoedit is safer in that it automatically saves a backup copy of the edited file, but the "-B
" command line option in nano does the same thing. nano is safer than other editors like vi or emacs because it doesn't have scary shell escapes.
If you prefer not to use the nano editor and prefer the Gnome Text Editor, instead of sudo nano -B use gksu gedit. I generally do this for large files, and /etc/default/grub
could easily be considered a large file. Thus type in gksu gedit /etc/default/grub instead of sudo nano -B /etc/default/grub. Note that the Gnome text editor does not automatically make a backup!
Notes on my grub file
I made some changes to grub for my personal needs. Such as the background picture of the moon launch. How to do these are discussed at the Ubuntu Community Documentation page on Grub2, recommended.
Good luck!
Solution 5
If you would rather use the bios to set this, reboot your computer and enter the bios (by pressing DEL in my case).
Go to Boot Options --> (This step may vary) Hard Disk Drive priority --> 1st Priority -> Windows Boot Loader
The second step may vary depending on how you installed Ubuntu / Windows
The key is that if ubuntu is set to a higher priority (HDD priority or boot device priority), you should replace that with the Windows Boot Loader
Tojamismis
Updated on September 18, 2022Comments
-
Tojamismis over 1 year
I have a Win 7/11.10 dual boot system with Grub 2 as the default bootloader. However, I want to make Windows bootloader the default bootloader (grub 'dos' like interface scrares the hell out of my sister) so when I start the PC I will have the following boot options: 1. Windows 7 2. Ubuntu
NB: A process to reverse this operation so Grub can be the default bootloader again will also be appreciated
-
Admin over 12 yearsDon't miss Burg: goo.gl/w0msb Your sister may like it :-)
-
Admin over 12 yearsI don't know if the MBR can be moded to show Linux, but, if you want an attractive, not DOS-like console replacement for Grub, you can try burg. Also Burg Screenshots of various themes
-
Admin over 12 yearsAs for me, I have a very related question: how to make Windows a default option in a standard Grub menu.
-
Admin over 12 yearsIvan, use the Startup Manager from the repositories.
-
Admin over 12 years@mikewhatever: Last time I checked Startup Manager it was only working for GRUB and not recommended for use with GRUB2. I'm not sure if that's still the case though. Mysterio, you can use GRUB themes to make it less look like an ancient stone.
-
Admin over 12 yearsI do know of burg but i was too scared to go through the process
-
Admin over 12 yearspossible duplicate of Is it possible to boot Ubuntu using the Windows bootloader?
-
Admin over 12 yearsFrom the recovery console in Windows, there are
fixmbr
andfixboot
.
-
-
Tojamismis over 12 yearsPlease could you be specific. I am a newbie
-
Extender over 12 yearsOk, when I will be at home with my ubuntu box
-
Tojamismis over 12 yearsThanks for your answer i will like to know if i use your answer i will only get two options during the boot screen 1. Windows 7 2. Ubuntu. This way i only get to see Grub2 if i choose the Ubuntu option
-
Eliah Kagan over 12 years
-
david6 over 12 yearsThis does make Windows boot loader come up first, and hides the Ubuntu Grub2 menu. My solution avoids using a Windows-based solution (if that is what you are suggesting).
-
Eliah Kagan over 12 yearsIn this solution, GRUB2 still loads first. It doesn't display a menu, but it still loads and then hands off control to the Windows boot loader. This solution prevents Ubuntu from being loaded at all, unless it is separately added to the Windows boot loader, which would then become a "Windows-based solution" differing from dago's solution only by the addition of considerable unnecessary complexity.
-
david6 over 12 yearsNo. Simply hold down [Shift] key, and Grub2 menu appears. quote: "Hold down SHIFT to display the hidden menu during boot (formerly ESC is GRUB legacy)." from link (above).
-
Eliah Kagan over 12 yearsGood point; I don't know if that was in your answer when I commented, but if it was, then I apologize for not noticing! This is still not what Mysterio had asked for ("I want to make Windows bootloader the default bootloader .... so when I start the PC I will have the following boot options: 1. Windows 7 2. Ubuntu"), but it might meet his/her needs.
-
Jayo over 12 yearsyou didnt read the question
-
Jayo over 12 yearsyou didnt read the question
-
david6 over 12 yearsWhy do we want a Windows-based "download an app." type solution, when this can be easily resolved from within Ubuntu?
-
Luke over 12 yearsFirst of all we are here to answer questions and not to question the questions.
-
keepitsimpleengineer over 12 yearsI tried installing EasyBCD to use with a broken grub2, but it requires Vista/Win7 to install.
-
keepitsimpleengineer over 12 yearsWell Jayo, I did read the question, but if you'll check askubuntu.com/questions/82928/how-to-make-windows-boot-first/… you'll see "closed as exact duplicate by fossfreedom, Jorge Castro, Javier Rivera, Marco Ceppi" along with the suggestion that answers to that question be merged here ⋯ along with my comment that they were not exact duplicate questions. Check it out.
-
Frank Nocke over 4 yearsGooglers: First of all: Anno 2019 BcdEdit is Windows10 and (U)EFI ready. And if command line is good enough for you, look at
bcdedit