How to un freeze drive in Linux?

2

I run

sudo hdparm -I /dev/sda

results:

Security:

Master password revision code = [redacted just in case it's sensitive data]

supported

not enabled

not locked

frozen

not expired: security count

supported: enhanced erase

My objective is to perform an enhanced secure erase (how? I'll find that out after I know how to unfreeze my drive) and also to detect and remove a Device Configuration Overlay. Relevant thread: Error when running 'hdparm --dco-identify' in Linux

I am trying to figure out why --dco-identify is failing and I suspect it may be as a result of the drive being "frozen". I recall this being a problem a year back when I was trying to securely erase an SSD. I gave up but suspected that connecting it via USB or hotswapping it might fix it.

Why? Refer to: https://ubuntuforums.org/showthread.php?t=1982585

So in the context of this post, I am trying to unfreeze my drive. How can I do this while it's connected via SATA?


Update: I tried this with an external HDD and ran

sudo hdparm -I /dev/sda

The drive is not frozen. Fascinating.

I ran:

sudo hdparm --dco-identify /dev/sdc

The command executed successfully!!

So that's confirmed but still does not answer my question about whether this can be achieved with an internal drive

user138072

Posted 2016-12-29T22:15:29.773

Reputation: 101

165534 is not in any way sensitive data. – Michael Hampton – 2017-11-29T17:35:38.593

Answers

3

If it's a laptop where it's hard to get to the disk drive to unplug it etc, use the suspend method. It worked for me. From the terminal I did this:

sudo systemctl suspend

Wait 1min, then tapped the laptop power button bringing the laptop back up and repeated the:

sudo hdparm -I /dev/sda

And viola, "not frozen".

Joe C

Posted 2016-12-29T22:15:29.773

Reputation: 510

This worked famously on several desktop computers as well – Elder Geek – 2019-07-21T17:02:56.840

1

Suspend & resume unfroze my drive.1

I just suspended my Laptop and then resumed it and then my drive was unfrozen. (You may need to hot-plug your drive before suspending - I did not need to.)

This is much easier than your approach.

1 https://serverfault.com/a/558556/453474

Arch Linux Tux

Posted 2016-12-29T22:15:29.773

Reputation: 275

0

Success!! I managed to unfreeze my drive by making the SATA port it is connected to hot-swappable. This involved me going into my BIOS. How you can achieve this will vary depending on your BIOS manufacturer.

Once the SATA port was hot-swappable, I did the following: 1) turned pc off 2) disconnected the SATA data cable from my motherboard. Left power cable connected. 3) turned PC on and booted into Linux 4) Connected HDD and Viola! It was unfrozen and "sudo hdparm --dco-identify /dev/sdb" was working! 5) I checked to confirm it was unfrozen by running "sudo hdparm -I /dev/sdb"

Note: device is at sdb now and not sda (as you will find in my other thread - linked above) because the HDD was connected after Linux was booted into!

Credit: https://linustechtips.com/main/topic/714345-connecting-hdd-after-computer-has-been-turned-on/#comment-9107915

If you cannot make your drive hot-swappable, you will have to buy a SATA-USB cable and connect your drive via USB.

user138072

Posted 2016-12-29T22:15:29.773

Reputation: 101