I have a known bad 4TB HD. I tried to rescue files with my regular PC but was just too cumbersome since I had to keep computer on, had case open with hard drive stiking out, etc.
I now have a new computer, so my old one became a proxmox server. I created a VM with ubuntu, and was able to passthrough a good 4TB hard drive that I plan to use to capture the recovered files. However when I try to passthrough the known bad hard drive I get an error. I want to use tools like ddrescue, testdisk, etc to try and recover some files.
When I list disks this is what I get
sda is the known bad hard drive
sdb is the hd being used by proxmox
sdc is the 4tb drive that will receive the recovered files
As a side note, I only passed the /dev/disk/by-id/wwn-0x5000c500e6c82XXX -> ../../sdc to my VM, do I also need to passthrough /dev/disk/by-id/ata-ST4000DM004-2U9104_ZW60PXXX -> ../../sdc or should I be passing only the ata one?
When I try to passthrough the bad drive I get this:
How can I access the bad drive to scan it and try to recover files?
Thanks in advance for any and all suggestions
I now have a new computer, so my old one became a proxmox server. I created a VM with ubuntu, and was able to passthrough a good 4TB hard drive that I plan to use to capture the recovered files. However when I try to passthrough the known bad hard drive I get an error. I want to use tools like ddrescue, testdisk, etc to try and recover some files.
When I list disks this is what I get
root@proxmox:~# find /dev/disk/by-id/ -type l|xargs -I{} ls -l {}|grep -v -E '[0-9]$' |sort -k11|cut -d' ' -f9,10,11,12
16:32 /dev/disk/by-id/ata-ST4000DM000_WDH0ZXXX -> ../../sda
16:32 /dev/disk/by-id/wwn-0x5000c5009d4b4XXX -> ../../sda
16:32 /dev/disk/by-id/ata-KINGSTON_SV300S37A240G_50026B7246055XXX -> ../../sdb
16:32 /dev/disk/by-id/wwn-0x50026b7246055XXX -> ../../sdb
19:01 /dev/disk/by-id/ata-ST4000DM004-2U9104_ZW60PXXX -> ../../sdc
19:01 /dev/disk/by-id/wwn-0x5000c500e6c82XXX -> ../../sdc
root@proxmox:~#
sda is the known bad hard drive
sdb is the hd being used by proxmox
sdc is the 4tb drive that will receive the recovered files
As a side note, I only passed the /dev/disk/by-id/wwn-0x5000c500e6c82XXX -> ../../sdc to my VM, do I also need to passthrough /dev/disk/by-id/ata-ST4000DM004-2U9104_ZW60PXXX -> ../../sdc or should I be passing only the ata one?
When I try to passthrough the bad drive I get this:
root@proxmox:~# qm set 104 -scsi2 /dev/disk/by-id/ata-ST4000DM000_WDH0ZA0M
update VM 104: -scsi2 /dev/disk/by-id/ata-ST4000DM000_WDH0ZA0M
qemu-img: Could not open '/dev/disk/by-id/ata-ST4000DM000_WDH0ZA0M': Could not read image for determining its format: Input/output error
could not parse qemu-img info command output for '/dev/disk/by-id/ata-ST4000DM000_WDH0ZA0M' - malformed JSON string, neither tag, array, object, number, string or atom, at character offset 0 (before "(end of string)") at /usr/share/perl5/PVE/Storage/Plugin.pm line 954.
volume /dev/disk/by-id/ata-ST4000DM000_WDH0ZA0M does not exist
root@proxmox:~#
How can I access the bad drive to scan it and try to recover files?
Thanks in advance for any and all suggestions