Jump to content

Can't boot to windows after deleting ubuntu partition

ScratchHackeryt

I installed Linux just to try it out and then I thought that I will actually use it but then I realised that I'm not using it and I had almost no space on my hdd so I deleted my ubuntu partition and now I can't boot the computer because it keep reporting "error: no such partition". Then it says "Entering rescue mode..." and then it gives me the grub rescue command prompt

Link to comment
Share on other sites

Link to post
Share on other sites

Can you get back to the ubuntu desktop and check the partitions there?

Any chance you deleted the wrong partition.  That's gonna suck.....

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, TheGlenlivet said:

Can you get back to the ubuntu desktop and check the partitions there?

Any chance you deleted the wrong partition.  That's gonna suck.....

No I deleted the ubuntu partition

 

Link to comment
Share on other sites

Link to post
Share on other sites

Grub rescue shell???

 

Just type "exit" everytime it happens

Your resident osu! player, destroyer of keyboards.

Link to comment
Share on other sites

Link to post
Share on other sites

easier method for running recovery commands without external media.

automaticrepair

 

 

automaticrepairscreen

Once automatic repair mode is ready, you’ll see the Automatic Repair screen. From here select Advanced options.

troubleshoot

On the next screen, click Troubleshoot and then Advanced options once again.

advancedoptions

  fixmbr

 

after selecting repair>cmd prompt, enter:
BootRec.exe /fixmbr

you can also substitue the /fixmbr with thes commands:

/FixBoot. Writes a boot sector onto the system partition to start Windows

/ScanOs. Scans all disks for Windows installations and displays them to you.

/RebuildBcd. Scans all disks for Windows installations and prompts you to pick the ones you want to add to the BCD.

EOC folding stats - Folding stats - My web folding page stats

 

Summer Glau: Quote's The future is worth fighting for. Serenity

 

My linux setup: CPU: I7 2600K @4.5Ghz, MM: Corsair 16GB vengeance @1600Mhz, GPU: 2 Way Radeon his iceq x2 7970, MB: Asus sabertooth Z77, PSU: Corsair 750 plus Gold modular

 

My gaming setup: CPU: I7 3770K @4.7Ghz, MM: Corsair 32GB vengeance @1600Mhz, GPU: 2 Way Gigabyte RX580 8GB, MB: Asus sabertooth Z77, PSU: Corsair 860i Platinum modular

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, ScratchHackeryt said:

Any ideas on how I can boot to windows?

ps I ran Linux in dual boot mode

 

Do what @Electronics Wizardy said. You most likely need to fix boot stuff that causes from dual booting linux

 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, Xsilent(X) said:

Put Windows CD or Boot Installation and boot windows installation

Now Click on repair your Computer

1 minute ago, Xsilent(X) said:

Windows 10 Repair Your Computer Menu

easier method for running recovery commands without external media.

automaticrepair

 

 

automaticrepairscreen

Once automatic repair mode is ready, you’ll see the Automatic Repair screen. From here select Advanced options.

troubleshoot

On the next screen, click Troubleshoot and then Advanced options once again.

advancedoptions

  fixmbr

 

after selecting repair>cmd prompt, enter:
BootRec.exe /fixmbr

you can also substitue the /fixmbr with thes commands:

/FixBoot. Writes a boot sector onto the system partition to start Windows

/ScanOs. Scans all disks for Windows installations and displays them to you.

/RebuildBcd. Scans all disks for Windows installations and prompts you to pick the ones you want to add to the BCD.

 

EOC folding stats - Folding stats - My web folding page stats

 

Summer Glau: Quote's The future is worth fighting for. Serenity

 

My linux setup: CPU: I7 2600K @4.5Ghz, MM: Corsair 16GB vengeance @1600Mhz, GPU: 2 Way Radeon his iceq x2 7970, MB: Asus sabertooth Z77, PSU: Corsair 750 plus Gold modular

 

My gaming setup: CPU: I7 3770K @4.7Ghz, MM: Corsair 32GB vengeance @1600Mhz, GPU: 2 Way Gigabyte RX580 8GB, MB: Asus sabertooth Z77, PSU: Corsair 860i Platinum modular

Link to comment
Share on other sites

Link to post
Share on other sites

4 minutes ago, deXxterlab97 said:

Do what @Electronics Wizardy said. You most likely need to fix boot stuff that causes from dual booting linux

 

I don't have a windows disk and I would need another computer for that but I only hav one

Link to comment
Share on other sites

Link to post
Share on other sites

7 minutes ago, FPSwithaWacomTablet said:

Grub rescue shell???

 

Just type "exit" everytime it happens

Tried that didn't work

 

Link to comment
Share on other sites

Link to post
Share on other sites

1 minute ago, ScratchHackeryt said:

Tried that didn't work

 

Weird, since my laptop always drops me into the grub shell whenever I boot, caused by installing Linux (not a live CD) on a USB drive. I only need to type exit and it boots me back into Windows

Your resident osu! player, destroyer of keyboards.

Link to comment
Share on other sites

Link to post
Share on other sites

4 minutes ago, ScratchHackeryt said:

I don't have a windows disk and I would need another computer for that but I only hav one

 

you have to have some sort of boot media to do a repair! or else you cannot repair your system.

EOC folding stats - Folding stats - My web folding page stats

 

Summer Glau: Quote's The future is worth fighting for. Serenity

 

My linux setup: CPU: I7 2600K @4.5Ghz, MM: Corsair 16GB vengeance @1600Mhz, GPU: 2 Way Radeon his iceq x2 7970, MB: Asus sabertooth Z77, PSU: Corsair 750 plus Gold modular

 

My gaming setup: CPU: I7 3770K @4.7Ghz, MM: Corsair 32GB vengeance @1600Mhz, GPU: 2 Way Gigabyte RX580 8GB, MB: Asus sabertooth Z77, PSU: Corsair 860i Platinum modular

Link to comment
Share on other sites

Link to post
Share on other sites

Your only hope is some sort of USB or DIsk to boot off of. If you don't have one you really need to get one and always keep one. 

Gaming Desktop - AMD Ryzen 7 5800X, MSI MPG B550 Gaming Plus, 32GB Cosair Vengenace LP 3600mhz, EVGA RTX 3070 XC3 Ultra,  Sabrent Rocket 4 1TB NVME SSD, WD Blue SN570 NVME SSD, 4TB Mass storage, EVGA 750W G2, Corsair 270R

Link to comment
Share on other sites

Link to post
Share on other sites

Ah bootloader recovery. This isn't something that's easy for most users to do, but I'll try my best to explain how to do it.

 

  1. You need a Windows install media or recovery environment (the install media has one).
     
  2. When you're in the recovery environment, you need to launch the command line, which was given at:
  3. You need to have a partition that is marked as "Active". To do so, in the command line prompt, do the following:
    1. Type in: diskpart
    2. Type in: list disk
      This will show a list of disks on your drive. Note in the "Disk ###" column the disk number of your drive. To make this easier, unplug all drives except the one Windows is on. This'll ensure it's "Disk 0"
    3. Type in: select disk 0
    4. Type in: list partition
      Like "list disk", note the in the "Partition ###" column which partition is your Windows one, because you don't want to touch that. The problem is you don't get to see any labels, so you must go off by its size.

       
  4. This is where things get tricky. You need to create or have a small sized partition (about 200MB or so) for the boot loader. You can simply wing it by typing in

    create partition primary size=200

    This will create a 200MB partition. If don't have free space because the other partitions are in the way, you can do:

    delete partition #

    Where # is the partition number you want to delete. Remember not to delete your Windows one!
     
  5. In any case, once you have a suitable partition for the boot loader, type in:
    select partition #
    Where # is the partition you want to use for the boot loader
     
  6. Then type: active
     
  7. Verify the partition is active by typing in detail partition. It will say "Active: Yes" if it is.
     
  8. Type in: list volume
    This will show a list of volumes in your system. Note in the "Volume ###" column for that 200MB partition we created earlier.
     
  9. Type in: select volume #
    Where # is the volume of the 200MB partition.
     
  10. Type in: assign letter=S
    It doesn't have to be S, but for the purposes of this tutorial, we'll be using letter S.
     
  11. Exit out of the diskpart utility by typing in exit
     
  12. Figure out which drive letter is your Windows install (it might be C:\ or D:\)
     
  13. Type in Bcdboot [Letter]:\Windows /s S: where [Letter] is the drive letter of your Windows Install.

If you can install the hard drive in another computer, this becomes much easier. You can follow the steps at https://technet.microsoft.com/en-us/library/ee829683(v=ws.10).aspx. Don't mind the title. You also don't have to do everything (in fact, you shouldn't), but I'll quote the only parts that matter:

Quote

Use Disk Management console to create a new primary disk partition from unused disk space for the new System partition.

  1. Use 200MB of free space on an existing partition and shrink the partition.
     
  2. Create the new primary partition, and format using NTFS.
     
  3. Assign the drive letter, S:.
     

Mark the new partition as Active.

  1. Right-click on partition S:, and select Mark partition as Active.

Use bcdboot.exe to copy the Windows 7 boot files to the new System partition.

Execute the following command: Bcdboot D:\Windows /s S:. Bcdboot copies the required boot environment files for Windows 7 to the S: partition, and creates a new BCD store to boot Windows 7 from the D: partition. The new BCD store does not have a boot entry for Windows Vista after this step.

Also do not follow this to the letter. The command at the end for example may need different parameters.

Link to comment
Share on other sites

Link to post
Share on other sites

Try changing your PC's boot setting. It should be somewhere under 'Boot Menu' in the BIOS.

Roses are red, violets are blue. I enjoy foruming on LinusTechTips too!

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×