Solved

Rescue iSCSI LUN from Qnap NAS server

Posted on 2014-02-14
6
5,123 Views
Last Modified: 2014-02-24
Hi,

I hope someone had the same problems and solved them.

I've got a Qnap NAS with 2 disk drives (I think it is Qnap TS-212P, but I am not sure, because it is Fujitsu re-branded to Celvin Q700). There's a 1,6 TB of BACKUP data, which needs to be restored.
This NAS has iSCSI Target configured and all backup data was stored to iSCSI LUN.

Now, the problem:
iSCSI targets on this NAS do not want to either switch from Offline status to Online....or if they do, then none of iSCSI targets is not accessible from any client computer.

I have tried:
- upgraded Firmware/Software to latest, but got ERROR on 10% of process. NAS shows newer firmware version, but I doubt it is true.
- downgraded back to original Firmware, but get ERROR.
- tried to access it from Windows 2008, win 7, server 2012R2 initiator...but still the exact same error as described above.
- made a sector-by-sector clone of disks, and put them into another Qnap of the same series, working one...but at no avail - the exact the same problem on this other NAS
- took the disk out and mounted to a Linux machine...I can see iSCSI LUN file there, with correct size...but it is 1 single file with extension .000 and 1,6 TB of size. What can I do with this file?

Any idea how to rescue data from it?
I only need FILES and STRUCTURE intact....while file permissions and other parameters do NOT matter.
0
Comment
Question by:Andrej Pirman
  • 3
  • 3
6 Comments
 
LVL 76

Assisted Solution

by:arnold
arnold earned 500 total points
Comment Utility
When you connect to the iscsi Target, is the issue that the partition is seen as RAW?
test-disk is a good tool to use to try to recover something like that.
On a system that has access to 1.5TB of free space, connect to the iscsi target.

Then use testdisk, http://www.cgsecurity.org/wiki/TestDisk to scan the file system on the iscsi LUN disk.

once the scan is complete, it will give you the option to recover the files to another location (never try to recover it in place)
If you do not have a single 1.5TB free-space, you would need to go through several systems recovering and copying portions of data at a time.
Using the selection of what to recover, you can try and limit the data set to the amount of space you have available on the particular system.  Make sure only connect to the iscsi target from one system at a time.


IMHO, when you experience a failure, never upgrade/update anything on the device unless instructed by official vendor support staff.
Some device upgrades have no impact on the data, some warn that updates/upgrades must only be done where everything is operating in an optimal state.
0
 
LVL 18

Author Comment

by:Andrej Pirman
Comment Utility
Hi Arnold,

no, actually I do not see partition as RAW. It depends on device which disks are connected to:
- if I plug disks into original QNAP NAS, then I can see everything as normal, except when I go to iSCSI Target configuration, I see LUNs, I see Targets....but they are Offline. There's a button to "Make Online", but without effect.
- if I plug each of disks to any Linux machine, I see the whole filesystem of QNAP NAS, and among all other files, I see also 2 files, for example one 600GB and the other 900GB in size. Both files have .000 extension and for sure those are iSCSI LUNs.

I do not have an idea how QNAP's LUN is formatted and how can I browse it with some 3rd party tools.
0
 
LVL 76

Accepted Solution

by:
arnold earned 500 total points
Comment Utility
The iscsi LUN partition is not a filesystem that many linux systems can access.
You need to enable ssh on the QNAP.  then ssh into it.  This way you can see what is going on and perhaps why the LUNs can not be brought online.

http://wiki.qnap.com/wiki/How_to_SSH_into_your_QNAP_device

pvdisplay, vgdisplay, lvdisplay to see whether the iscsi LUNS are part of an LVM.



Make sure to look at the system logs to see what might be going on prior to proceeding to the below.


there is a way from the command line using lvchange -ay /dev/VolumeGroup that is offline.
0
How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

 
LVL 18

Author Comment

by:Andrej Pirman
Comment Utility
Hi Arnold,

you made me thinking the other way around.
I've used Ubuntu live CD with attached one ORIGINAL disk and one COPY, where on the latest was the exact the same config as in ORIGINAL, except of iSCSI LUN, which was in COPY-case of same size, but empty.
Then I copied over just the LUN file from ORIGINAL to working COPY. This is still in progress (1,6 TB of data....takes half a day for each step).

Now it helped me a lot this article: http://ubuntuforums.org/showthread.php?t=2191753 to mount ORIGINAL QNAP's data partition. In my case it was designated as "RAID partition", but I suceed mounting it with:
sudo mount -t ext3 /dev/sdc2 /media/external/

Open in new window


Will report back once copy is finished.
0
 
LVL 76

Expert Comment

by:arnold
Comment Utility
Usually a raid type is assembled using mdadm.
When mounting in these types of situations, it is better to include the -O ro with mount to indicate that the partition should be mounted as read-only.
0
 
LVL 18

Author Comment

by:Andrej Pirman
Comment Utility
Hi arnold,

I managed to re-attach my lost LUNs to iSCSI targets following this guy's experience:
http://forum.qnap.com/viewtopic.php?p=233166#p233314

We were close, and my friend also suggested to mount LUN with mount -loop option. But did not try it in this case.

thank you very much for participating!
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Suggested Solutions

How to fix error ""Failed to validate the vCentre certificate. Either install or verify the certificate by using the vSphere Data Protection Configuration utility" when you are trying to connect to VDP instance from Vcenter.
Microservice architecture adoption brings many advantages, but can add intricacy. Selecting the right orchestration tool is most important for business specific needs.
This tutorial will walk an individual through the steps necessary to enable the VMware\Hyper-V licensed feature of Backup Exec 2012. In addition, how to add a VMware server and configure a backup job. The first step is to acquire the necessary licen…
This tutorial will walk an individual through the process of installing the necessary services and then configuring a Windows Server 2012 system as an iSCSI target. To install the necessary roles, go to Server Manager, and select Add Roles and Featu…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now