You are not logged in.
Hi, today I was wiping an old drive (1TB space).
1) I deleted all partitions (using fdisk)
2) Then used dd status=progress if=/dev/urandom of=/dev/sdX bs=1M
3) dd got cancelled almost at the end of it
4) Now in fdisk I can only create a partition with 6.8GiB.
How can I recover all that filled space?
Last edited by joaonunatings (2021-11-25 19:43:49)
Sway on ASUS ZenBook UX434DA-UM433DA: AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx, 16GB RAM, Samsung MZVLB1T0HALR-1TB SSD, Keychron K12 with Banana Switches Keyboard
Offline
dd got cancelled almost at the end of it
How? Did you cancel it or did it abort?
Now in fdisk I can only create a partition with 6.8GiB.
fdisk -l
You probably want to check https://wiki.archlinux.org/title/Smart
Maybe dd if=/dev/zero onto the drives head helps, but I doubt so…
Offline
if the capacity is no longer detected correctly, ( cat /proc/partitions and/or blockdev --getsize64 show the wrong size ) it is usually a hardware problem.
sometimes its possible for urandom to generate bogus partition tables (some partition formats don't have significant magic bytes to prevent mis-detection) so in case a program is simply confused by such byte patterns, then wipefs -a and/or zeroing might help
if the drive supports SMART you can also check smartctl -a, if it supports ata secure erase you can also try that, and for some drives even firmware updates may be applicable (but that's mostly SSDs)
but if its a hardware issue there's just nothing much you can do anymore, and neither should you trust such a misbehaving drive with data anymore
Offline
After rebooting computer I'm able to create a partition with the full capacity (931.5G). I was wondering if it's possible to check for drive specifications if this is the real full capacity size (I know that is a 1Tb drive from the shop where I bought, but sizes differ from actual memory that is free).
How? Did you cancel it or did it abort?
I cancelled it.
fdisk -l
Device Boot Start End Sectors Size Id Type
/dev/sda1 2048 1953525166 1953523119 931.5G 83 Linux
You probably want to check https://wiki.archlinux.org/title/Smart
This drive has no SMART support.
if the capacity is no longer detected correctly, ( cat /proc/partitions and/or blockdev --getsize64 show the wrong size ) it is usually a hardware problem.
$ cat /proc/partitions
8 0 976762583 sda
8 1 976761559 sda1
$ blockdev --getsize64 /dev/sda
1000204885504
Last edited by joaonunatings (2021-11-25 19:06:30)
Sway on ASUS ZenBook UX434DA-UM433DA: AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx, 16GB RAM, Samsung MZVLB1T0HALR-1TB SSD, Keychron K12 with Banana Switches Keyboard
Offline
After rebooting computer I'm able to create a partition with the full capacity (931.5G). I was wondering if it's possible to check for drive specifications if this is the real full capacity size (I know that is a 1Tb drive from the shop where I bought, but sizes differ from actual memory that is free).
Yes. That's correct.
https://www.google.com/search?q=1TB+in+GiB
Offline