0

I recently followed this guide to dual-booting OEM Windows 8 and Ubuntu, and now I've got an awful GRUB menu full of redundant entries. All I want are two entries: one for Ubuntu, and one for Windows. I'd also like to be able to rename them, since the entry for Windows 8 has a name that doesn't make any sense.

1 Answers1

1

First try grub-customizer, see this answer, but you should know that grub-customizer has some issues with the newest grub-2.00.

If you like the manual editing way, open a terminal (Ctrl+Alt+T) and run

gksudo /etc/grub.d/40_custom && gedit /boot/grub/grub.cfg

Here you will create YOUR custom grub entries. If you have another Linux system (Windows no matters), then you must update these custom entries by hand every time a new kernel arrives in the other Linux system (not Ubuntu).

Now you must have two documents opened, the one (40_custom) is opened with root privileges.

Each entry begins with

menuentry 

and ends with this symbol }

Copy paste the entries you want from grub.cfg to 40_custom . Not Ubuntu's entries. Only the entries from ### BEGIN /etc/grub.d/30_os-prober ### and below.

When done, save the 40_custom document.

Run in terminal

sudo chmod 644 /etc/grub.d/30_os-prober
sudo chmod 755 /etc/grub.d/40_custom 
sudo update-grub 

Above commands will remove the execute permissions from 30_os-prober (that scans for other Operating Systems and add the entries) and will give execute permissions to your custom script (40_custom). Last command will update grub with the new values.

Check the new values with

cat /boot/grub/grub.cfg

Above method is a bit tricky and dangerous. You should edit the files very carefully because you may wind up with a corrupted grub menu or no menu at all. If that's the case, you have to use boot-repair from a Live media to restore grub.

More grub tips and tricks can be found in Ubuntu Wiki/Grub2, for custom menus look here.

Good Luck

NickTux
  • 17,865
  • 6
  • 57
  • 66