KevinM
Contributor
- Joined
- Apr 23, 2013
- Messages
- 106
I have CIFS, NFS and iSCSI datasets on my production FreeNAS box that I am backing up to a remote location via ZFS replication. With CIFS and NFS I can see the data, so I know everything is fine. I wanted to verify that I could replicate an iSCSI file extent to the backup FreeNAS box and access the data. I was able to do that, but I got the following error when mounting a cloned snapshot of an NTFS filesystem:
My question is, how likely is it to be a problem if I create the snapshots at a time when the filesystems are likely to be idle? These are primarily NTFS filesystems that do not have live databases on them.
Steps taken: I created an iSCSI LUN on the production FreeNAS system and mounted it on a Windows 2008 server. I then copied an ISO to the mounted NTFS drive. I created a snapshot of the LUN and replicated it to the backup server. There I cloned the snapshot and exported it as an iSCSI LUN to a Linux system. On the Linux system I mounted the LUN as an NTFS filesystem, and in that filesystem I mounted the ISO as a loopback device and listed the files. Had anything been wrong with the ISO file I likely would not have been able to mount it and access the files.
nadia ~ # mount -t ntfs /dev/sdb1 /mnt
The disk contains an unclean file system (0, 0).
The file system wasn't safely closed on Windows. Fixing.
My question is, how likely is it to be a problem if I create the snapshots at a time when the filesystems are likely to be idle? These are primarily NTFS filesystems that do not have live databases on them.
Steps taken: I created an iSCSI LUN on the production FreeNAS system and mounted it on a Windows 2008 server. I then copied an ISO to the mounted NTFS drive. I created a snapshot of the LUN and replicated it to the backup server. There I cloned the snapshot and exported it as an iSCSI LUN to a Linux system. On the Linux system I mounted the LUN as an NTFS filesystem, and in that filesystem I mounted the ISO as a loopback device and listed the files. Had anything been wrong with the ISO file I likely would not have been able to mount it and access the files.
Code:
nadia ~ # iscsiadm -m discovery -t st -p 172.16.1.2 172.16.1.2:3260,2 iqn.2011-02.org.example.istgt:test nadia ~ # iscsiadm -m node --login Logging in to [iface: default, target: iqn.2011-02.org.example.istgt:test, portal: 172.16.1.2,3260] (multiple) Login to [iface: default, target: iqn.2011-02.org.example.istgt:test, portal: 172.16.1.2,3260] successful. nadia ~ # dmesg | tail [527792.198567] Loading iSCSI transport class v2.0-870. [527792.228127] iscsi: registered transport (tcp) [527792.348421] iscsi: registered transport (iser) [527858.032067] scsi3 : iSCSI Initiator over TCP/IP [527859.290666] scsi 3:0:0:0: Direct-Access FreeBSD iSCSI Disk 0123 PQ: 0 ANSI: 5 [527859.293567] sd 3:0:0:0: Attached scsi generic sg2 type 0 [527859.296290] sd 3:0:0:0: [sdb] 104857600 512-byte logical blocks: (53.6 GB/50.0 GiB) [527859.298065] sd 3:0:0:0: [sdb] Write Protect is off [527859.298068] sd 3:0:0:0: [sdb] Mode Sense: 83 00 00 08 [527859.298793] sd 3:0:0:0: [sdb] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA [527859.338887] sdb: sdb1 [527859.344653] sd 3:0:0:0: [sdb] Attached SCSI disk nadia ~ # mount -t ntfs /dev/sdb1 /mnt The disk contains an unclean file system (0, 0). The file system wasn't safely closed on Windows. Fixing. nadia ~ # cd /mnt nadia mnt # ls QA $RECYCLE.BIN System Volume Information TEST nadia mnt # cd TEST nadia TEST # ls ubuntu-10.04.4-desktop-i386.iso nadia TEST # mkdir ~/iso nadia TEST # mount -o loop ubuntu-10.04.4-desktop-i386.iso ~/iso mount: block device /mnt/TEST/ubuntu-10.04.4-desktop-i386.iso is write-protected, mounting read-only nadia TEST # df Filesystem 1K-blocks Used Available Use% Mounted on /dev/sda1 40251776 7772496 30434608 21% / udev 1016452 4 1016448 1% /dev tmpfs 410292 1012 409280 1% /run none 5120 0 5120 0% /run/lock none 1025724 76 1025648 1% /run/shm none 102400 12 102388 1% /run/user /dev/sdb1 52425724 13006996 39418728 25% /mnt /dev/loop1 711084 711084 0 100% /root/iso nadia TEST # cd ~/iso nadia iso # ls autorun.inf dists isolinux pics preseed ubuntu casper install md5sum.txt pool README.diskdefines wubi.exe nadia iso # cd .. nadia ~ # umount iso nadia ~ # umount /mnt nadia ~ # iscsiadm -m node --logout Logging out of session [sid: 1, target: iqn.2011-02.org.example.istgt:test, portal: 172.16.1.2,3260] Logout of [sid: 1, target: iqn.2011-02.org.example.istgt:test, portal: 172.16.1.2,3260] successful.