2

I have a win10 Pro box with a Samsung 840 Evo SSD (250Gigs) Trying to reformat a Samsung 840 Evo SSD (120Gigs) that was part of a ZFS SAN I recently dismantled, and re-purposed.

I can see the disk in DiskPart, but when I go to "clean" it I get an error.

VDS fails to write boot code on a disk during clean operation. Error code: 80070002@02070008

If I try to Initialize the drive in Disk Management I get:

Virtual Disk Manager The system cannot find the file specified.

I'm at wits end, I can't seem to find anything online regarding how to fix this. The drive is plugged directly into the MotherBoard (asus Z87-Pro).

Does anyone know how I can reformat this drive?

6
  • 1
    before clean use "ATTRIBUTE DISK CLEAR READONLY" in diskpart.
    – uDev
    Commented Feb 27, 2018 at 2:11
  • detail disk states: Read-only: NO Also ran the command it it threw an error: DiskPart failed to clear disk attributes.
    – Jon Lillie
    Commented Feb 27, 2018 at 3:08
  • 1
    Perhaps there's a problem with the disk? Commented Feb 27, 2018 at 3:18
  • The cause of issue related to window's SAN policy. Can you try it from linux? (ex. any live usb edition) @Twisty Impersonator: the disk may not fault, just some windows settings/policy protect the drive.
    – uDev
    Commented Feb 27, 2018 at 3:21
  • I finally got ahold of a USB stick with ubuntu live CD. the drive doesn't show up when you run lsblk. :/ etcher wouldn't install on my win 10 partition, and I got selected for jury duty
    – Jon Lillie
    Commented Mar 6, 2018 at 2:41

2 Answers 2

0

Obviously, this is too late for the OP, but for anyone who stumbles upon this question like I did, I have the answer. That answer is: wipe the drive with a linux utility. Nwipe, DBAN, DD, it doesn't really matter, as long as it can start from sector 0 on the drive. Even better is the hdparm command, especially for SSDs (but yes, it does work for spinning rust) as it's very fast because the controller on the HD does it. If the drive isn't recognized in Linux, then check whether it's recognized in your BIOS. Obviously, if BIOS can't see it, no OS is going to either. If BIOS does detect the drive, then make sure your kernel is new enough to handle whatever drive you're trying to throw in there (i.e. drivers). The only other caveat I can add is that if the BIOS recognizes it and you're sure you have the right drivers in the OS, you might have a SED (self-encrypting drive) in which case you'll need the master password to wipe it. If you don't have that, you're going to have to do research on your specific model of drive on how to get around that. I had this same problem, and in my case, the drive was in a USB enclosure, but pretty much everyone who has asked this question on the internet that I could find either had it in a RAID array (like the OP) or a USB enclosure.

The other common error message that accompanies the one OP had is, "virtual disk service Unexpected failure. Error code: 45D@02000018". The reason for all these errors is that RAID controllers and USB enclosure write some data to the very beginning (and sometimes very end) of a hard drive, PAST where Windows can access it (using the old C/H/S model, Windows usually doesn't start writing until Head 1, Sector 0, which means the first 64 sectors are out of bounds (you start counting at 0). The easiest thing to do is get a copy of Parted Magic and put it on a disk or USB and run Nwipe from it (do the 64 bit version for speed benefits) if you don't already have Linux on a box you can just put the drive in.

Afterwards, whatever your ultimate purpose is for the disk, do that; meaning, if you mean to attach it to a RAID controller, don't boot back into Windows and initialize it, put it straight into the RAID controller. Otherwise, you're going to have to go through this again. Hope this helps somebody out there.

Reference: https://wiki.archlinux.org/title/Solid_state_drive/Memory_cell_clearing https://wiki.archlinux.org/title/Securely_wipe_disk

4
  • Any reason for the downvotes on this? Is this bad/dangerous advice?
    – Ian
    Commented Apr 6, 2023 at 20:46
  • Just haters... Some people don't like it when you answer a question years after the fact. If you read what I wrote, all I'm saying is wipe the very beginning and end of the disk, where's the harm in that. I also provided links, read them for yourself and if you find it to be sound advice and do it, and it works, please upvote it so it helps someone who may not even ask the question like you did.
    – redbox
    Commented Apr 8, 2023 at 13:43
  • lol, stack exchange is as bad as reddit :) It didn't actually fix my own problem, because mine is just weird beyond belief, but I gave you the +1 for making me think.
    – Ian
    Commented Apr 8, 2023 at 22:10
  • @Ian: Can be various reasons. Poorly formatted. Plain bad advice. For example, wiping the drive might be pure overkill, it's probably enough to just zero-fill the first MB of the drive IF what's written there is actually the issue. Since this about an SSD, avoid useless disk wipes, and second my first step would be to verify the SSD's health state. Assuming it's read only, this could be because the firmware itself put the drive in a read-only state due to a problem with the drive it detected.
    – user705502
    Commented May 18, 2023 at 11:37
-1

If you are getting an error 'VDS fails to write boot code on a disk during clean operation. Error code: 80070013@02070008' and your SAS disk is showing as read-only in diskpart, the proper solution is to select the offending disk and execute ATTRIBUTE DISK CLEAR READONLY as suggested in the comment above.

9
  • And next comments state, not red only, it was tried and didn't work.
    – user705502
    Commented Dec 16, 2022 at 13:39
  • @JoepvanSteen Dumb question, but were you running diskpart as Administrator when you tried to clear the attributes? Do you have some paranoid antivirus which blocks writes to boot sectors? What about BIOS boot sector write protection? Finally, did you try using Samsung Magician to do secure erase? Commented Jan 26, 2023 at 1:57
  • I commented on OP's comment, he states in comment the disk is read-only. I am not poster of OP.
    – user705502
    Commented May 18, 2023 at 11:39
  • @JoepvanSteen If you are not OP then why are you claiming something they said is correct and what I said is incorrect when you cannot prove either? They stated Read-only shows as NO, but they never specified whether they were running diskpart or disk management as administrator. Commented Jul 25, 2023 at 14:25
  • What are you on about?! OP states (in comments) "Read-only: NO Also ran the command it it threw an error: DiskPart failed to clear disk attributes".
    – user705502
    Commented Jul 25, 2023 at 14:28

You must log in to answer this question.

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