How can I remove MBR from external HD?


Recommended Posts

Updated to be clear about what I'm trying to achieve (original post at bottom):

I want to remove boot information from the MBR of an external hard drive:

1) Currently, the external hard drive has GRUB written to MBR

2) The partitions on the external hard drive are new, and did not exist when GRUB was installed to the MBR

3) I would like to erase only GRUB's boot information from the MBR while keeping the partitions intact

4) The partitions, in order are 40GB FAT32, 500GB NTFS, 120GB EXT3. They are all storage volumes, no OS.

5) Right now, if I try to boot from USB, this drive is seen and GRUB tries to load. GRUB then fails since there is no longer an OS on this drive.

6) If I tell the computer to boot from USB, I would like the computer to skip over this drive, rather then trying to boot it.

Thanks,

Matt

________________OLD ORIGINAL POST BELOW________________

I have an external hard drive (connecting via USB) with three partitions, 1FAT32, 1NTFS, 1EXT3. I need to erase GRUB from the MBR, but can't figure out how to do it. I don't want to replace it with another boot manager, in fact that's the problem, I need the drive to NOT be bootable. I've long since erased the linux partition that installed GRUB in the first place, and this is strictly a storage volume now.

I have Windows Vista and Ubuntu set up on my computer, so if you know of any tools I can use under either OS, it'd be appreciated. I also have XP on a virtual machine.

~Matt

Edited by AlfredSka

accesser thats only for the main drive and that will restore the mbr but only on the active drive not anything else

The fdisk /mbr command only re-writes the MBR on the system drive (DISK-0) using BIOS calls. You cannot specify any other drive for the fdisk /mbr command to operate on other than DISK-0.

Um if you wipe the MBR -- then there would be no partitions on your disk

http://en.wikipedia.org/wiki/Master_Boot_Record

If the disk is partition, then it would have a MBR. I think what your looking to do is just remove the Boot Flag from one of the partitions -- not remove the MBR itself.

Any number of partitions tools would be able to remove the boot flag/active flag from a partition for you. Or overwrite the MBR with just your partition details, etc.. The above link gives you about everything you would need/want to know about the MBR ;)

It sounds like I need to explain a bit more:

1) ALL partitions were deleted before these partitions were created. Realize, the boot record is not written over by simply deleting partitions. None of the partitions have a boot flag. For proof, I've attached a screenshot of gparted:

gparted.jpg

2) I don't want the drive to boot ANYTHING. Essentially, if I have several devices hooked up to the computer at boot time, and I tell the computer to boot from USB, I want it to skip over this drive (and not consider it an option).

Here's some more information:

I found Roadkil's Sector editor which shows GRUB occupying the boot sector:

sec01.png

sec17.png

It looks like it's occupying sectors 0-17. I've never used a utility like this before. Would it be safe to write zeros to these sectors? Or would that delete information about my partitions as well?

If you use a WinPE disk, you can use DISKPART and use the CLEAN command in it to completely wipe all tables from the drive. If you decide to do so, be VERY careful as DISKPART has no safety features. :)

(If you're using Vista, I think the install disc has it too. Just boot from it and open a command prompt.)

Here is the tool your looking for.

http://www.diydatarecovery.nl/mbrtool.htm

http://www.diydatarecovery.nl/MBRtool_manual.htm

MBRtool allows you to do the following things:

* backup, verify and restore the MBR, using backup-sectors or files

* backup, restore, wipe, clean or dump the track 0 for a disk

* edit or wipe the MBR Partition Table

* refresh the MBR bootcode, without destroying the Volume Bytes

* remove the MBR bootcode

* re-write the MBR signature bytes

* display the MBR sector or dump the MBR sector to file

* perform above mentioned edit, bootcode, display and dump functions on the MBR backups

* create a blank backup-file to create a MBR from scratch and restore it later

* perform attribute changes on partitions listed in the MBR Partition Table (hide, activate, delete etc.)

* manipulate the volume bytes that are associated with volumes in Windows NT / 2K / XP

You do not want to remove the MBR which contains where your partitions are -- you just want to remove the Grub Bootloader code.. Which is exactly what this tool will allow you to do.

MBRtool sounded promising, but alas it's not going to work for me.

I'm running a laptop, so the drive must remain on an external USB port. Unfortunately, MBRtool does not read USB drives. (I even used a ghost boot disc with USB support (UHCI.exe) to boot, then ran mbrtool without success.) MBRtool sees my laptop's hard drive just fine, but not anything on USB.

I'm suspecting there is a single hex key that I can change in the boot sector to say (Not Bootable), but I need to figure out for sure which it is.

EDIT: I'm currently looking into MBRwizard (http://www.mbrwizard.com/) and will report results.

Edited by AlfredSka
EDIT: I'm currently looking into MBRwizard (http://www.mbrwizard.com/) and will report results.

I tried MBRWiz, but issuing

mbrwiz /disk=1 /wipe=mbr

also wiped my partition table. I've restored the backup MBR, and I'm back to where I started. Any ideas of other tools that would work under windows? Or does someone know which key/sector I can change to specify non-bootable?

I found partial success by following the directions here: http://www.cyberciti.biz/faq/linux-how-to-uninstall-grub/

I used the linux method, which did get rid of GRUB, but my computer's boot sequence still can't get past the drive.

I also used the lilo method from the comments of that page, but encountered similar results.

In either case my partition table remained intact.

I tried MBRWiz, but issuing
mbrwiz /disk=1 /wipe=mbr

also wiped my partition table. I've restored the backup MBR, and I'm back to where I started. Any ideas of other tools that would work under windows? Or does someone know which key/sector I can change to specify non-bootable?

Try the following

mbrwiz /disk=1 /repair=1

this will replace the current MBR boot code with a standard Windows XP MBR, effectively overwriting any existing GRUB loader code. Also, this option leaves the partition table untouched!

This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Euro-Office must default to ODF to be considered "genuinely European", LibreOffice argues by David Uzondu Euro-Office is a web-based collaborative office suite that positions itself as a "European sovereign alternative" to American tech companies, backed by a coalition of developers including Nextcloud, IONOS, Abilian, BTactic, OpenProject, and, more recently, Tuta. The project officially went live a couple of days ago, but not before drawing heavy fire from LibreOffice developers, who called the marketing claim that Euro-Office represents the "first open-source office suite developed in Europe" a deceptive historical inaccuracy because projects like OpenOffice and LibreOffice existed decades earlier. Now that the project has launched, LibreOffice is back with another complaint, arguing that Euro-Office cannot consider itself "genuinely European" while it pushes proprietary Microsoft defaults on users. Euro-Office had promised to improve the OpenDocument Format (ODF) back in April, but the current release still plagues users with several technical failures. For instance, the suite lacks an admin setting to enforce ODF, and mobile editors completely block ODF saves, forcing files into Microsoft's OOXML formats. Some configurations force files into read-only mode, while editing frequently corrupts document formatting or erases data. LibreOffice thinks that merely supporting a format as an afterthought does not make you a sovereign alternative, as file formats are the battleground where" digital sovereignty is won or lost." The road to the first stable release of Euro-Office has been quite bumpy due to an aggressive public fallout with OnlyOffice, from which the coalition originally forked the project. OnlyOffice struck back by accusing the coalition of violating copyright terms under its AGPLv3 branding requirements by stripping the original branding anyway and forking the code. Getting Euro-Office up and running is a bit wonky (at least for non-technical users), as there is no direct installer to grab off the web. The easiest way we learnt is by using Docker. First, pull the official Euro-Office image from the GitHub Container Registry: docker pull ghcr.io/euro-office/documentserver:latest Then, run the container with active ports and a secure JWT token, enabling the test environment: docker run -i -t -d -p 8080:80 --restart=always -e EXAMPLE_ENABLED=true -e JWT_SECRET=my_secure_jwt_secret ghcr.io/euro-office/documentserver:latest And finally, open a web browser and go to the following address: http://localhost:8080 If you are running this on a remote server, replace localhost with your server's IP address. You will see the Euro-Office test page, where you can create new text documents, spreadsheets, or presentations directly in the browser. Image via Euro-Office Nextcloud promises that proper standalone desktop versions and mobile apps will arrive in a future release.
    • It’s any of their products not just windows.
    • Google Gemini has been failing for users across the United States, Europe, and Asia since early Wednesday morning, June 10, 2026, and more than six hours into the incident Google has yet to declare a fix............. https://www.techtimes.com/articles/318152/20260610/google-gemini-outage-tops-six-hours-errors-1076-1099-worldwideflash-lite-still-answers.htm
    • Fun fact: There are more Warhammer 40k games than there are stars in the universe.
  • Recent Achievements

    • Week One Done
      FBSPL earned a badge
      Week One Done
    • One Year In
      Jim Dugan earned a badge
      One Year In
    • One Month Later
      Tommi118 earned a badge
      One Month Later
    • One Month Later
      sjbousquet earned a badge
      One Month Later
    • Week One Done
      sjbousquet earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      486
    2. 2
      PsYcHoKiLLa
      197
    3. 3
      +Edouard
      155
    4. 4
      Steven P.
      83
    5. 5
      ATLien_0
      69
  • Tell a friend

    Love Neowin? Tell a friend!