Lost data after adding another hdd for device extent on iscsi

Status
Not open for further replies.

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
So, been checking out FreNAS for some time, and am using it for ZFS RAID, and CIFS shares.
I also have a Windows Home Server, that's virtualized and though attaching iscsi hdd to it would be just dandy!

So, Pulled a 1.8TB HDD and attached it to the Hypervisor using iscsi and a device extent on FreeNAS. all is well and performance is decent.

Removed another 1.8TB and attached it to FreeNAS, the ada labels get messed up, so I rearranged them and update my Device Extenst to add the 2nd 1.8TB HDD. No Probel mI think... but upon loading up WHS, it shows two blank HDD's!


WTF happened to my existing data? I checked the docs page for any warnings about data being wiped while fiddling with device extents...

Can someone tell me wtf happened and how to get my data back?
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
I Got most of my Data Back, seems FreeNAS wipes data before you use it with a Device Extent.

This appears to be a bug, and I'll file another post in the bugs section.
 

William Grzybowski

Wizard
iXsystems
Joined
May 27, 2011
Messages
1,754
FreeNAS does not wipe anything, it just presents the provider to iscsi target software, it _might_ wipe the last sector (512bytes) for glabel metadata if serial is not found.
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
A Friend used one of those Data Recovery Apps, and rebuild the partition table or something... I didn't have any apps installed to perform the work myself anymore...

I didn't think FreeNAS should wipe data, and can't think of any reason it would... but it did. I'm able to re-create the problem simply by adding a HDD (with partition layout) and adding it as a device extent.

The Windows Home Server is being replaced mostly by FreeNAS (combo CIFS and iSCSI to individual HDD's and ZFS RAID array's). Been mostly happy with FreeNAS, and have figured out most functionality with it.

Anyway, I should mention the Release version I'm using among other info:
-FreeNAS-8.3.0-RELEASE-p1-x64 (r12825)
-MSI P45 Platinum w/UEFI Firmware http://www.msi.com/product/mb/P45-Platinum---P45-Zilent.html
-Intel Core 2 Duo e8400 3.0GHz
-8GB DDR2 800 RAM
-2x Intel E1000 PT NICs (Don't like the Crabby Realtek NIC ;)
-soon to be added: Adaptec 4 port RAID card for more storage using ZFS.
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
[root@freenas] ~# sqlite3 /data/freenas-v1.db "select * from storage_disk"
1|Disabled|Always On|6XW1Y0A3||{serial}6XW1Y0A3|1|Disabled|Auto||||2|ada1
0|Disabled|Always On|5YD4GFAB|||1|Disabled|Auto||||3|ada2
1|Disabled|Always On|5YD4MZKT||{serial}5YD4MZKT|1|Disabled|Auto||||4|ada3
1|Disabled|Always On|S13PJ1KZ200751||{serial}S13PJ1KZ200751|1|Disabled|Auto||||5|ada4
1|Disabled|Always On|S13PJ1KZ200743||{serial}S13PJ1KZ200743|1|Disabled|Auto||||8|ada5
1|Disabled|Always On|WD-WCASJ1951092||{serial}WD-WCASJ1951092|1|Disabled|Auto||||9|ada6
1|Disabled|Always On|WD-WCASJ2278339||{serial}WD-WCASJ2278339|1|Disabled|Auto||||10|ada7

ada2 is pulled, and iSCSI is stopped. due to recover data, and sort this problem out. ada3 is the drive I added, and maybe I mixed up ada1 and 3 during device extent and ada1 is wiped as well... but luckily it was my test drive for my test whs migration.

BTW, Thank You for the HELP! :)
 

William Grzybowski

Wizard
iXsystems
Joined
May 27, 2011
Messages
1,754
Ok, I've identified the issue, you were right, sorry. There is a bug that will wipe partition table for non-zvol/non-multipath device extents.
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
So, now what?

AFAIK, this will be included in an update?

and for now, can I edit those files or upload them to my freenas (using winscp from windows)?
 

William Grzybowski

Wizard
iXsystems
Joined
May 27, 2011
Messages
1,754
You could test 8.3.1-BETA3, it is in sourceforge but has not been announced yet.

Use at your own risk =)
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
Upgrading, at my risk...
Let get Dangerous! Muahahah!

erm... ok ;) using GUI upgrade as I type this, server rebooted... I made a save config .db backup... and havn't read the import things for zfs volumes... or made backups. It's only movies so no big worries.

In theory, once 8.3 is out of beta, I should be able to gui upgrade then too, huh?

Thnx for the help, btw (or again...)

Update: Upgrade success! However...

When I go Storage -> View Disks -> All Serial Numbers are blanked... I was using the serial numbers to ensure my device extents were mapped right.

Things might be easier if I just used ZFS volumes ;)

Another Update: Data Wiping bug still present... Attempted deleting device extent, and adding the drive, wipes it of data... D:
So, again some more info: Installed 8.3.0 release p1 x64, GUI upgraded to 8.3.1 Beta3 lalala.txz (after reading release notes mentions to use this instead of .xz).

Can I update the files? doesn't seem hard... wait, now that it's this level, maybe the line numbers will match!
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
Ok, GUI upgraded again, from beta uhm... someverison to:
FreeNAS-8.3.1-RC1-x64 (r13329)

And.... Bug still there :p

Havn't looked at editing those files... but may look when time permitting.
 

William Grzybowski

Wizard
iXsystems
Joined
May 27, 2011
Messages
1,754
Found another bug that would wipe data once you delete the device extent. It will be fixed in RELEASE

Thanks
 

ZarK

Dabbler
Joined
Jan 24, 2013
Messages
20
GUI Updated to 8.3.1 p2 and all is OK!

ran tests first of course on another box, and then did it fer real ;)

Thought ya'd like to know, you know? :o
 
Status
Not open for further replies.
Top