So you want to test FC target mode?

Status
Not open for further replies.

X7JAY7X

Dabbler
Joined
Mar 5, 2015
Messages
20
Also, one more question. The OP stated "When the system comes back up any targets you've set up for iSCSI will show up as FC targets as well. Make sure not to use them via both access methods at the same time!".

Does this mean I cannot access the same target from one machine using FC and another machine using the network? I may not have enough FC cards so I might still have a mix of machines accessing the same NAS datastore that would be over FC and over network.
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
Does this mean I cannot access the same target from one machine using FC and another machine using the network?
No, that statement is not correct. You may use all transports simultaneously. You can even build multipath setup, combining FC and iSCSI together, for example for backup purposes.

The only problem I can guess is that if you setup both iSCSI and FC to the same host, that does not support MPIO (like desktop versions of Windows), you get same LUN reported several times. With improper use that may lead to data corruption due to simultaneous access. But problem would be the same if you set up two FC or two iSCSI links.
 

X7JAY7X

Dabbler
Joined
Mar 5, 2015
Messages
20
Mav,

Is there a way I can share the drives in one FreeNAS machine to another FreeNAS machine over Fibre Channel?

Thanks
Jason
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
Is there a way I can share the drives in one FreeNAS machine to another FreeNAS machine over Fibre Channel?
You can share any raw block device same way as sharing ZVOL. It has little sense, but possible. But remember that this won't be a real SCSI pass-through, CTL does not support that now. That is why you can't share CD/DVD or tape drive same way.
 

X7JAY7X

Dabbler
Joined
Mar 5, 2015
Messages
20
Mav,

Thanks for the help. How do I go about setting it up? I currently have on FreeNAS machine, lets call it NASESXI, with FC as a target for ESXI machines. I have another FreeNAS machine that I want to see the drives on the NASESXI machine.
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
How do I go about setting it up? I currently have on FreeNAS machine, lets call it NASESXI, with FC as a target for ESXI machines. I have another FreeNAS machine that I want to see the drives on the NASESXI machine.
I am not sure I understand your description. Do you want to chain machines to make NASESXI to be both target for ESXI machines and initiator for another FC target? That surely can be done, but would require separate FC ports on NASESXI for being configured as target and initiator. After that you configure another machine as target and NASESXI should see disks it exposes via FC.
 

X7JAY7X

Dabbler
Joined
Mar 5, 2015
Messages
20
No, I want the NASEXSI machine to be a Target only and the ESXI boxes as well as the other FreeNAS box would see its disks.

"After that you configure another machine as target and NASESXI should see disks it exposes via FC."
How do you expose disks on one machine and see them on the other?
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
So what is your problem? If you already know how to set up FC target, sharing raw disk is the same as sharing ZVOL: plug the disk to share, reboot to get more repeatable name for it, and go to iSCSI settings to create device extent from that disk. Unfortunately it is not possible to control LUN visibility for different initiators at this time, so both ESXI and second FreeNAS will see all the same LUNs. Actually recent kernel already can do different LUN mapping for different target FC ports, but there is no WebUI for it.
 

X7JAY7X

Dabbler
Joined
Mar 5, 2015
Messages
20
I am relatively new to FreeNAS. I setup the iSCSI on the ESXI box so I understand that but I am struggling on sharing over FC.

I created a device extent from a disk on the ESXI NAS. Where do I see the device extent on the other FreeNAS machine?
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
Ah, so ESXI is connected via iSCSI, not FC... Then reread this thread and configure FC target ports on NASESXI as described. After that on second FreeNAS with FC ports configured by default as initiator you should see all extents exported by NASESXI same as local SCSI disks: daX.

And be careful to not corrupt disks belonging to ESXI, as I have told, there is no way to control the access for FC now. For that reason you should avoid setting multipath to FreeNAS initiator, otherwise it will write gmultipath metadata, that overwrite the last sector of the LUN.
 

nicolaus

Cadet
Joined
Mar 17, 2015
Messages
3
At what version software I can find the check box for experimental target mode?

upload_2015-3-17_13-29-23.png
 

nicolaus

Cadet
Joined
Mar 17, 2015
Messages
3
Only in later 9.2.1.x. It was enabled by default and removed in 9.3.

Thank you, well than if I want to enable FC Target I will need to do only this steps:
  1. # mountrw / && sed -i "" -e 's/\(role\)=2/\1=1/' /boot/loader.conf && mount -ur /
Create a postinit script that runs /usr/sbin/ctladm port -o on

How I can check out that all is ok?
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
Those are quotes from original recipe for 9.2.1.x. For 9.3 and new knowledge I would rephrase it:
1. sed -i "" -e 's/\(role\)=2/\1=0/' /boot/loader.conf
2. Create a postinit script that runs /usr/sbin/ctladm port -o on -t fc
3. Enable iSCSI and configure some extents, as guided. All those extents will also be visible over FC.
 

cmacnichol

Cadet
Joined
Mar 19, 2015
Messages
5
Hello,

I have successfully setup the Target and gotten a disk to be visible to sansurfer or windows and then within ESXI, this was just to make sure the link was working and I had done it right.

My setup is a little odd. I have all of my disks in a HP N40l with 8gb, 4 x 3TB and 4 x 1.5TB, which is severely under-powered for anything I want to do. I also have a HP DL380 G7, with 72gb ram and quad core proc, that I have a Freenas install on. This server however, does not have a lot of storage at all, enough for my Hosts and that is about it.

As the majority of my storage is going towards media on Freenas anyway, I passed through the Qlogic 2460 to the VM. What I would like to do here is use the Virtual Freenas as an Initiator to the Stand Alone Freenas. The hope here is that the Virtual Freenas would just treat the Stand Alone as Direct Attached Disks and I can create the Zvols from within the virtual FN and still take advantage of ZFS. The more processor and memory intensive applications I offload to the server the better and I understand that Freenas can start to take a decent amount of memory with ZFS.

Is this possible? If so, how do I put on the Virtual Freenas into Initiator mode where it will see the other one?

Or at this point am I completely over-thinking this and there is a better option? Thought about just offering up the storage pool to ESXI itself and create VMDK's, but was worried that due to the large size of those I would lose performance and could not take advantage of De-duplication...
 

mav@

iXsystems
iXsystems
Joined
Sep 29, 2011
Messages
1,428
It is generally possible to hook one FreeNAS to another via FC. Initiator mode for FC is enabled by default, so you don't need to do anything special. From the other side this scheme looks overcomplicated, so reliability and performance is questionable.
 

cmacnichol

Cadet
Joined
Mar 19, 2015
Messages
5
It is generally possible to hook one FreeNAS to another via FC. Initiator mode for FC is enabled by default, so you don't need to do anything special. From the other side this scheme looks overcomplicated, so reliability and performance is questionable.

I am getting that idea as I research this more. Just finished a truly excellent guide by Cyberjock. Makes me question a lot of what I was thinking of doing. Now I not sure what the best route it. I plan to use this for File Storage, about 1-2tb worth, that I do not want to lose and another 3 TB of media files that I just want protected from casual failure. Not the end of the world if it goes, just inconvenient. My Issue here is that the Microserver is no where near powerful enough to run Plex and the other media plugins. The server has plenty of power and memory to spare, but no access to the storage I need. I had the Fiber parts on hand, which is why I went this route in the first place. Looks like I need to rethink this. Any ideas would be appreciated...
 

cyberjock

Inactive Account
Joined
Mar 25, 2012
Messages
19,526
I think that's a fair assessment @cmacnichol. My personal take on FC is that it *can* be deployed with ZFS, and can be done relatively safely. The problem is that if you have that kind of knowledge and experience, you probably use FreeBSD and find FreeNAS to be too limiting and too "basic" for your needs. I talked to someone about FC once, and he said that it is not as easy as it looks on the surface, and if you don't have a deep understanding, you probably are screwing up.

He said something like "The litmus test is whether they need a guide to do FC on FreeNAS. If they do, they're certainly not qualified to do FC safely."
 
Status
Not open for further replies.
Top