LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   deleted linux partition causing problems to my system (https://www.linuxquestions.org/questions/linux-newbie-8/deleted-linux-partition-causing-problems-to-my-system-4175490424/)

adedamola 01-07-2014 07:41 AM

deleted linux partition causing problems to my system
 
Hello all, I recently deleted my linux partition from my system because I want to install a new distribution (ubuntu). I have windows running on the other partition. After deleting the linux partition from inside windows. I restarted my system but can't boot to windows. It bringing out the GNU GRUB. Please what can I do to make my system boot to windows.

kareempharmacist 01-07-2014 09:30 AM

what is the message that appears to you?

gengisdave 01-07-2014 09:42 AM

i think you have just a "grub>" prompt and nothing all; in that case, you have deleted config file. type this:
Code:

set root=(hd0,msdos1)
chainloader +1
boot

hd0,msdos1 means /dev/*da1 or the first partition on the disk, if you installed windows elsewhere, change it; windows 7+ boot from first partition regardless of its real partition (it has a separated 100 mb hidden partition)

TobiSGD 01-07-2014 10:04 AM

http://www.linuxquestions.org/questi...rtitions-4060/
In short: Install a new Linux system or repair the bootloader from your Windows installation DVD/CD.

adedamola 01-07-2014 10:07 AM

After writing the codes, it gave this message "BOOTMGR is missing" "press ctrl+Alt+Del to restart. Which I did and it still took me to the 'grub' prompt

gengisdave 01-07-2014 10:13 AM

tobi's solution it's fine too, btw, what windows are you using? in which partition it's installed? what are your disks?

TroN-0074 01-07-2014 10:47 AM

Install the version of Ubuntu you want in the same partition you had the Linux distro you deleted. That will give you the boot menu again.

In the future you dont need to deleted a linux distro in order to install a new one. You can just install the new one on top of the old one. the installer will format the partition no matter what.

If must boot into windows and re partition you hard drive then the alternative is to fix your MBR by booting from a Windows install disk.

Good luck to you.

jms89 01-07-2014 01:15 PM

Quote:

Originally Posted by gengisdave (Post 5093551)
i think you have just a "grub>" prompt and nothing all; in that case, you have deleted config file. type this:
Code:

set root=(hd0,msdos1)
chainloader +1
boot

hd0,msdos1 means /dev/*da1 or the first partition on the disk, if you installed windows elsewhere, change it; windows 7+ boot from first partition regardless of its real partition (it has a separated 100 mb hidden partition)

Do you know where I can find documentation to explain what exactly you've typed here means?

gengisdave 01-07-2014 01:25 PM

http://www.gnu.org/software/grub/manual/grub.html

haertig 01-07-2014 01:49 PM

This is one reason I still maintain a seperate boot partition. I don't want booting to be dependant on any particular operating system being installed (i.e., I don't want the boot configuration files to be present on a partition I may delete at some later date).

---

Originally when you had only Windows on your computer, Windows installed it's bootloader into track0. And the Windows bootloader jumped to the Windows partition to pick up the rest of it's executables and configuration.

Then you installed Linux. Linux overwrote the Windows bootloader in track0 with it's own GRUB bootloader. That new GRUB bootloader then jumped to your Linux partition to pick up more executables and it's configuration. One part of the GRUB configuration was to re-jump over to the Windows boot files in the Windows partition. This is called "chainloading". So in order to boot Windows, you were dependant on three things: (1) Part of GRUB installed in track0, (2) The rest of GRUB, including it's config files, installed on the Linux partition, and (3) The "second half" of the Windows bootloader installed on the Windows partition. When you deleted that Linux partition, you wiped out (2), which effectively stopped your computer from booting anything.

So what you have now is part of the GRUB bootloader installed in track0 of your hard disk. That part of GRUB is attempting to load additional GRUB executables, and config files, from that partition you deleted. But it can't, because you deleted that partition. This is easy to repair, and others have already given you recommendations on how to do the repair. But it helps to know what happened. Then it's easier to understand the various ways you can repair it.

One way is to install Ubuntu as you plan, and that will reinstall GRUB and it's config files in it's Linux partition. The GRUB re-installation will automatically detect that you have Windows installed, and create a Windows boot choice for you. And all will be good again (until you delete the Ubuntu partition, and then the problems will reappear). Another way to fix this is to have Windows replace the GRUB bootloader in track0 with it's original Windows bootloader (the one that was overwritten by GRUB). I am not overly familiar with Windows these days, but I think they call this "repair Windows installation" and you can accomplish it by booting with your original Windows installation disks. You would take this path for repair if you no longer wanted Linux and wanted to return to a Windows-only computer. Complicating this repair path slightly may be the fact that you do not have any Windows installation disks. Your computer probably came preloaded with Windows and you did not get any installation disks. But usually they provide some "recovery disk". If not, you need someone more Windows-savvy than I am to direct you how to repair a Windows bootloader without any Windows installation disks. I'm sure it is possible - I just don't know how myself.


All times are GMT -5. The time now is 09:07 AM.