I recently installed ubuntu 10.04 LTS and formatted my windows 7 hdd, but the windows 7 entry is still showing in grub. How can I remove the entry from grub?

Greetz

link|improve this question

0% accept rate
feedback

migrated from stackoverflow.com Jun 3 '10 at 11:35

This question came from our site for professional and enthusiast programmers.

4 Answers

If I remember corretly, you need to edit /boot/grub/menu.lst on your linux drive and remove the windows 7 entry (it's a text file)

The entry looks something like this:

title Windows 7
root (hd1,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1 
link|improve this answer
1  
That would be correct for grub 1, but Ubuntu 10.04 uses grub 2, which has a more complicated scheme, generated from files in /etc/grub.d – Douglas Leeder Jun 3 '10 at 10:44
feedback

what version of grub do you use?

if you use grub 1 then you must edit /boot/grub/menulist.lst if you use grub 2 then you must edit /etc/grub.d/04... and after update you grub

link|improve this answer
feedback

Ubuntu 10.04 LTS uses Grub2, which no longer uses the /boot/grub/menulist.lst file for configuration.

Instead, you should edit the file /etc/default/grub.

If your hard disk still contains a Windows partition, add the line:

GRUB_DISABLE_OS_PROBER=true

to prevent Windows being added to your grub menu.

To write the change, run

sudo update-grub

which will write a new /boot/grub/grub.cfg file.

You can then run

cat /boot/grub/grub.cfg

to check that your Windows entry has disappeared.

Further information can be found on this page: https://help.ubuntu.com/community/Grub2

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.