Unable to detect partitions on a HP SmartArray RAID

How to use TestDisk to recover lost partition
Forum rules
When asking for technical support:
- Search for posts on the same topic before posting a new question.
- Give clear, specific information in the title of your post.
- Include as many details as you can, MOST POSTS WILL GET ONLY ONE OR TWO ANSWERS.
- Post a follow up with a "Thank you" or "This worked!"
- When you learn something, use that knowledge to HELP ANOTHER USER LATER.
Before posting, please read https://www.cgsecurity.org/testdisk.pdf
Locked
Message
Author
cjj1977
Posts: 3
Joined: 10 Jul 2018, 22:04

Unable to detect partitions on a HP SmartArray RAID

#1 Post by cjj1977 »

Hello,

I am trying to recover lost partitions on a HP Microserver (Gen8) server. The only internal disks are 4x 750GB HDDs configured as one logical RAID device using the built-in "BIOS" HP Smart Array Configuration Utility. I used this to set up the disks in a mirrored striped pair (0+1), total size 1.4TB. This device was divided into logical partitions for a CentOS 7.x installation. Be aware that the B120i SATA RAID controller in this device does not offer "full hardware" RAID; the Smart Array utility appears to just mark the disks according to the RAID configuration and then hand over the work to a software driver (HPVSA). For my CentOS install I had to slipstream this driver during installation.

After a kernel upgrade & reboot the RAID was no longer visible and the system would not boot beyond GRUB. I was able to enter the BIOS Smart Array Configuration Utility to confirm that the RAID was present and healthy. Sadly, I think I managed to trash my MBR & partition table when using those same HP BIOS utilities. :'(

So, I have fired up CentOS 7.4 in "rescue" mode with a compatible HPVSA driver and I can see the logical device once again, but no partitions. I have tried to use Testdisk to detect partitions but, after some initial excitement, it hasn't been able to work out the correct partition structure. I'm afraid I don't know enough about disk geometry to have made much of an attempt to use the advanced CHS options.

My question is whether this sort of fake RAID is throwing off Testdisk. I suspect there is something wrong going on as I have also tried PhotoRec and it is only offering me file fragments: for example the MP3s recovered are all 10 seconds long and duplicated, but otherwise are playable. I'm happy to follow up on PhotoRec as a separate thread, but my gut feeling is that there is one underlying problem that means Testdisk & PhotoRec aren't able to read the RAID in the necessary manner. The duplicate file fragments make me wonder if I'm getting data from both sets of the mirrored disks, or if the RAID is being treated as JBOD, etc.

Has anyone seen this? Is anyone able to explain what is going on? And, crucially, is there anything I should try in order to get these utilities to read the disks correctly?

User avatar
cgrenier
Site Admin
Posts: 5432
Joined: 18 Feb 2012, 15:08
Location: Le Perreux Sur Marne, France
Contact:

Re: Unable to detect partitions on a HP SmartArray RAID

#2 Post by cgrenier »

I don't know the device name of your smart array RAID. Does testdisk let you choose the correct device ?
If it's not the case, run "testdisk /dev/correct_device".

cjj1977
Posts: 3
Joined: 10 Jul 2018, 22:04

Re: Unable to detect partitions on a HP SmartArray RAID

#3 Post by cjj1977 »

When the HPVSA driver is loaded, I can work out which device it is using lsblk or fdisk -l. Generally I see it as /dev/sdc. At the moment when I run those tools I also see 2x partitions as /dev/sdc1 and /dev/sdc2.

I'm able to select the same device when TestDisk runs, and the total size of the device is correctly reported as 1.4TB. I have tried detecting partitions a few times, and every time it seems to find loads of partitions (10 or more), none of which seem to be realistic. I'm expecting no more than the usual 3 partitions for a Linux installation (/, /boot & swap) plus one extra partition for /home.

leecher
Posts: 1
Joined: 29 Jul 2018, 18:43

Re: Unable to detect partitions on a HP SmartArray RAID

#4 Post by leecher »

Capture.PNG
Capture.PNG (57.25 KiB) Viewed 2236 times
Same problem here on a Gen8 as well, running on Windows Server 2012. In my case I accidentally formatted a 3TB WDMyCloud (Ext2 File system. WD Red disk) and then disassembled the drive and plugged it into a Sata Bay for recovery (i had to create a new array and logical drive). As I'm writing this, Photorec has been scanning over 17 hours and remaining ETA is over 25 Hours (and growing). It detects the large partition i need, but can't recover any folder structure, only single files that Photorec places into "random" folders at specified destination.

I've tried several other softwares (Stellar phoenix, easeus, remo recovery, data liferguard, etc…) on ws2012, ubuntu, w7 (LIVE installation, VM's and also native installs, I should try a Oui-Ja too, just in case). I coud be complaining all da but Photorec is the best tool I've found until now.

I just hope this helps you someway. I will post the results if I happen to be alive when it completes scanning.

PS: Just read about some tool called "Isobuster" wich I'll try after Photorec if i find the courage to try again.

Image

cjj1977
Posts: 3
Joined: 10 Jul 2018, 22:04

Re: Unable to detect partitions on a HP SmartArray RAID

#5 Post by cjj1977 »

The "random" folders are typical for PhotoRec. If you look in the documents/FAQs you'll find a link to a couple of scripts that can make some sense of the files in these folders, especially JPEGs.

In my case this hasn't helped. I waited for PhotoRec to complete (took almost a week!) and all I found in these folders were file fragments, e.g. 10 second snippets of MP3 files, shards of EPUB books and so forth. With a bit of spot checking I have determined that each of these file fragments has been recovered twice. I suspect that, in my case, TestDisk & PhotoRec haven't been scanning the 4-disk RAID 0+1 correctly and has, instead, scanned each disk in turn. Or something like that.

User avatar
cgrenier
Site Admin
Posts: 5432
Joined: 18 Feb 2012, 15:08
Location: Le Perreux Sur Marne, France
Contact:

Re: Unable to detect partitions on a HP SmartArray RAID

#6 Post by cgrenier »

If PhotoRec only recover file fragments, it means the HP SmartArray RAID hasn't been configured as it was originally.

Locked