1

I have 3 USB flash drives (newly purchased, original) which were used to create bootable drives to install Zorin OS on a PC. The flashing failed for some reason, and now I have 3 USB flash drives which look like this in Disk Management -

Screenshot.

In order to get my drives back to normal, after watching a bunch of videos/reading articles, I have tried the below so far -

  • First tried creating a simple volume, with default settings in the wizard; then I got a popup saying "Volume was created but not formatted", and then it would try to run format, and I received "the system cannot find the specified file type".
    • Went to diskpart, tried list disk > select disk # > clean/clean all; then it would say "Diskpart error, access denied. Check system logs." It would delete the created volume in the last step, but showed the access denied error. Also this is what was recorded in system logs - Cannot zero sectors on disk \\?\PhysicalDrive2. Error code: 5@0101000F.
    • Then started command prompt as administrator, still the exact same error. Using admin cmd should solve the access denied error right? Why is this happening?
  • My drives just won't format, tried from both manual format (from This PC and disk management) and diskpart format.
  • On This PC, when I try to open any of the drives it says "Please insert a disk in E:" (for eg.)

All of the above has been tried on 2 separate PCs, same error on both, even if cmd is in admin mode. What should I do?

I just want to convert my drives back to normal, so I can use them to transfer data around like before.


UPDATE: When I select a drive like this:

enter image description here

This is what I see:

enter image description here

10
  • 1
    So what happen if you right click on the unallocated and e.g., create a new partition?
    – Tom Yan
    Commented Dec 18, 2022 at 7:14
  • Hi, @TomYan, thanks for replying. I've added the details of what happens when I try to create a simple volume for one of the drives in my original question above. Kindly have a look there. Thanks!
    – kartik
    Commented Dec 18, 2022 at 7:19
  • 2
    Could you please use the site built-in image uploader? Even if you only get a link from that method it is a lot easier for people to move the images inline for you.
    – Mokubai
    Commented Dec 18, 2022 at 7:59
  • 1
    Consider clean all instead of clean on one of them and see. The former will zero out the whole drive. It might take quite a long time though, especially when these drives are likely pretty slow.
    – Tom Yan
    Commented Dec 18, 2022 at 8:05
  • 1
    Can you download DMDE and post screenshot of partitions TAB with 'advanced' option ticked? Commented Dec 18, 2022 at 21:24

3 Answers 3

1

In case the drives are actually dead / bricked, there's hardly anything you can do. Therefore, I'm assuming this is caused by a flaw in Windows itself.

I would suggest booting a Linux live medium and zero out the drive from there. However, it's probably a "chicken or the egg" problem here, so instead of preparing one and boot it on a physical machine, you can try booting an ISO on a VirtualBox VM, which allows you to attach the USB drive to the VM. Make sure you download the extension pack that is available separately and load it, so that you can enable USB3/XHCI on the VM.

WARNING: the following expose you to the risk of wiping you system or other data drives. No warranty or guarantee, especially not to PEBKAC!!!

On the other hand, you can also try msys2 instead (certainly it won't bypass as much as the VM approach).

I am not going to go through how you can get msys2. Just download the installer / tarball and install / extract the it, then go to the folder and run msys2.exe and let it initialize and follow the instruction.

Once it's done, run msys2.exe again as Administrator, which gives you a # (instead of $) prompt:

enter image description here

In the above cat /proc/partitions helps you to identify the device name you should use. But AFAIK, the enumeration simply correspond to that on the host, i.e., Disk 0 => sda, ..., Disk 2 => sdc

The command lines that follow zero out the first 1MiB of the drive and "hexdump" that respectively. If you see the same output (well the line orders of the second one might vary every time because of both stdout and stderr will be used), it probably means that your drive is not bricked. You might want to safely remove and re-attach the drive between the write and the hexdump-check.

Then you may try clean in diskpart again, which seems to initialize removable drive on recent Windows builds (similar to what convert mbr does on non-removable drvie), and try to create a partition/volume and format again.

You may also consider increase the value of count= to something larger to zero out a bit more, like 16 or 128. If you don't mind zeroing out the whole drive, you can replace count=1 with status=progress instead.

P.S. I can't help but suspect that the drives you got are counterfeit ones that were never supposed to work at all. On Linux you can make use of e.g. openssl enc + tee + a hash/checksum program like sha256sum to check whether random filling the drive actually worked. While technically you can also do that with msys2, tee appears to be awfully slow when used to write to a drive directly. Let me know if the above does not help. I'll try to demonstrate the method on a VirtualBox VM.

2
  • Please don't post images of text
    – gronostaj
    Commented Dec 19, 2022 at 14:15
  • I faced exactly the same issue. I've tried every built-in Windows 10 tool (both command-line and GUI) but without luck. Just zeroing the flash drive on Linux machine via dd have brought the device to life. Indeed, looks like Windows' flaw...
    – flaz14
    Commented Sep 13, 2023 at 9:34
0

Unallocated space on drive comes when drive lost its file system and unable to locate data location in the storage drive. There is only one option to resolve this issue is by clean formatting of the drive. Either you can format the drive by going to the disk management or use diskpart to clean the drive and redefine the file system.

5
  • 1
    Hello @Shivam, thanks for replying. When I go to diskpart and use clean after list disk & select disk 2 for eg., it says this - "Diskpart has encountered an error, Access is denied". Then this appears in system logs - "Cannot zero sectors on disk \\?\PhysicalDrive2. Error code: 5@0101000F". Then I receive "please insert a disk into USB drive E:" popup. What should I do?
    – kartik
    Commented Dec 18, 2022 at 8:01
  • 1
    @kartik Did you use an admin command prompt?
    – Tom Yan
    Commented Dec 18, 2022 at 8:07
  • 1
    @TomYan Yes - so I open cmd with admin rights, open diskmgmt and diskpart. In diskpart I select the disk in which I added a simple volume as you suggested, and used clean all. It waited a few seconds & then said again "Diskpart has encountered an error, Access is denied" but on Disk Management it shows that the volume on that disk has been cleared and now it shows Unallocated again. What should I do?
    – kartik
    Commented Dec 18, 2022 at 8:45
  • 2
    No idea then, at least not on/with Windows. It sounds like the drive is dead / bricked. No idea how it could happen to three of your drives though. (Could they be counterfeit?)
    – Tom Yan
    Commented Dec 18, 2022 at 9:25
  • 2
    Unallocated in Disk Management means 'no partitions detected'. It has not to do 'with lost file systems', it's just describing a state. Commented Dec 18, 2022 at 21:26
0

As we can see from your screenshot there's a lot going on:

enter image description here

Using the same tool (DMDE) we can wipe the MBR. You can use the free version for this.

Select the USB drive

enter image description here

Click Tools > Fill Sectors. A warning pops up, click Parameters.

enter image description here

Check "Allow Write', confirm you understand the warning.

Now Fill Sectors dialog opens

enter image description here

Click OK to overwrite 1 sector (512 bytes, the MBR), confirm warning message. MBR is now zeroed:

enter image description here

Try Formatting the USB drive again.

If you still get an error, repeat but zero-fill the entire USB Drive by clicking 'max' in Fill sectors dialog:

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .