41

Probably due to a power outage, I suddenly lost access to a connected USB HDD yesterday. According to parted, I get the message “unknown partition table,” and gdisk says the GPT is corrupted. Using testdisk, I was able to copy the files to another drive and restore the partition table and mount the HDD.

Is it possible that the partition table was damaged by the power outage, or does this point to a different problem? Can I safely store data on such an HDD again, or should I replace it?

you are viewing a single comment's thread
view the rest of the comments
[-] brickfrog@lemmy.dbzer0.com 7 points 2 days ago* (last edited 2 days ago)

Adding on to the earlier comments you can run tests against the drive with smarctl e.g.

smartctl --scan (scans and lists all drives connected to your system)

smartctl -t short /YOUR/DRIVE (short non-destructive drive test, usually takes 3 minutes or so, afterwards run smartctl -a again to view test results towards the bottom of the output)

smartctl -t long /YOUR/DRIVE (this is a long more thorough test, non-destructive, this can easily take a few hours or even days depending on the size of your drive and whatnot)

smartctl -a or smartctl -x will give you testing progress in its output.

Or another option, if you can't run smartctl for some reason, and you're just testing a regular HDD not SSD, look into running a badblocks non-destructive scan.

this post was submitted on 25 May 2026
41 points (100.0% liked)

Linux Questions

3932 readers
4 users here now

Linux questions Rules (in addition of the Lemmy.zip rules)

Tips for giving and receiving help

Any rule violations will result in disciplinary actions

founded 2 years ago
MODERATORS