Does FOG work with iSCSI?
-
@Wayne-Workman It’s a Buffalo Terastation TS-RIXL NAS device. I want this to be my main storage node seeing it is 8T instead of 500G. It is also RAID5.
-
After doing some reading about iSCSI, NAS, and the like, I asked my boss why it had to be iSCSI and not NFS and said he just likes iSCSI. He said I can do NFS, that it didn’t matter. I hear that is easier than iSCSI?
-
@ManofValor 13 days of stress for what? lol. Fog is built for NFS.
-
@Wayne-Workman Right.
-
@george1421 said
@ManofValor A NAS is roughly equivalent to a second file server to store your images on. You could either connect the NAS to the linux server using NFS or you can setup your NAS as a FOG storage node.
For 2 of the 3 options this doesn’t involve FOG at all. If you setup your NAS as a FOG storage node you will need to setup some stuff on your NAS (ftp, NFS, and a NFS share)
So which NFS option would you recommend for a noob?.
-
You can set it up as either a file level device (nfs) or a block level device (iscsi). Either method will work. I don’t remember which OS you are using for your fog server. But I think I would go the nfs route because its the easiest.
On your Terastation just create a share and share it out via nfs. If you want to restrict access to this share only allow the fog server to mount this nfs share. The FOG server does need full read/write access to this share. You will need to know the path you shared out of your NAS, because you will have to tell your fog server how to connect to it. You may be able to use the following command from your FOG server to see what the shares are on your nas.
showmount -e <IP address of NAS>
<snip from another one of my posts that should get you pretty close>
The first step would be to create a mount point on your fog server and then connect to NAS either via nfs or iSCSI to the mount point on the fog server. You would do something in the order of
mkdir /mnt/fognas
mount -t nfs <nas_ip_addr>:/<nas_nfs_share> /mnt/fognas
Then create a bind mount between the /mnt/fognas and /images
mount -o bind /mnt/fognas /images
(note: you may need to move the images directory before the bind mount will work.) Once its setup. touch a file in the /images directory and confirm it is created on this nas. When that is done, mv the contents of the old /images directory to /mnt/fognas folder. Then review /images on the fog server to confirm all of the files are where they should be.
The last bit you need to update is the /etc/fstab so this mount and remount work every time.
(before you do this, post the contents of your /etc/fstab file)
<nas_ip_addr>:/<nas_nfs_share> /mnt/fognas nfs rw,hard,intr,rsize=8192,wsize=8192 /mnt/fognas /images bind bind 0 0
Understand I have not tested this myself, but what you want to do is possible (in theory). There will be a performance penalty for doing this since the image will need to move from the nas to the fog server and then from the fog server to the target computer. I have no clue on what you can expect (in regards to performance) from this configuration. I’m going to suspect your NAS will be the slowest part of the deployment.
-
I just setup a proof of concept following my previous instructions. Even with a bind mount you can not reshare a nfs connected file system. So my previous instructions are a fail, even using the bind mount.
iSCSI may be the only option to support this scenario.
-
OR - set it up as a storage node. NFS and FTP, that’s all you need. No mounting or anything like that.
-
@Wayne-Workman How do I make it the primary node? Is that something I can just set up in the FOG management console?
Is this the process?
https://wiki.fogproject.org/wiki/index.php/Managing_FOG#Adding_a_Storage_Node
Under “Adding a Storage Node”? -
@ManofValor Yes and Yes.
On the terastation, you need a directory called /images and another folder in there called /dev
in both of these, you need files named
.mntcheck
you need the whole /images directory shared out with 777 permissions
you need to create a
fog
user that has ftp rights over the entire /images directory as well, the password for the fog user should be the username/password set in the storage node area.and that’s all there is too it. With any luck, it’ll work on the first try.
-
@Wayne-Workman How do I do the install again and not the update. When I run ./installfog.sh it just updates.
-
@ManofValor I believe the argument would be run with:
./installfog.sh --no-upgrade
or
./installfog.sh -U
It may not work properly with your local fog user though (it will reset the password in the process).
-
@Tom-Elliott But this what need to do add/change the storage node to my NAS, right?
-
@ManofValor What do you mean?
-
@Tom-Elliott I’m trying to make my Buffalo Terastation my primary storage for my images. I’ve never dealt with NAS/NFS and of course I’m new to FOG, so I’m trying to figure out how to connect my NAS. A couple posts up I asked Wayne if that was how I do this and in the video it took me through the install of FOG again, though I think in the vid it was a fresh install. I hope I’m making sense.
-
@ManofValor The only thing you would need to do is edit the /opt/fog/.fogsettings file. Look for the storageLocation= variable in the file. Make whatever change is needed.
You would also need to update the node in the GUI to look at the same place as storageLocation and edit the /etc/exports file. After that, just reboot the server and all should be well.
It seems you’re overthinking things.
While following the info in the video is not a bad idea, understand that in IT you don’t have to everything exactly like shown. What they’re showing in most of those situations is how to start from “nothing” to get to “something”.
-
@ManofValor Mind you, you would not need to rerun the installer in “no-update” mode either.
-
@Tom-Elliott Thanks Tom. I know over think things a lot, I hate that. I also assume things a lot and that has gotten me in trouble so I’m kinda paranoid to make sure I get it right, since I’ve never done it, so thank you for being patient with me. So to make sure I understand things correctly, I change “storageLocation=‘/images’” to what, the IP of the NAS? Then I go into the fog management console and change the current storage node settings or add one?
-
@ManofValor Well your images need to be available either on one or the other. You can create a Storage Node out of the NAS you have by ensuring there is a user and password and that is defined in the storage node definition created to handle it. You mounting it to your FOG server would not work because it would require you mounting either iSCSI (which you’ve already learned is not a very simple thing and I doubt iSCSI targets and query strings are setup for a simple things such as a nas), or some other FS managing tool other than CIFS (Windows Share/Samba) or NFS (What FOG typically uses).
By making the NAS a “node” you will lose such things as the ability to replicate to other nodes and multicast tasks. I don’t know of a good way around that for you unless you’re able to do a TON of research in installing the FOG system on the NAS directly.
-
@Tom-Elliott said in Does FOG work with iSCSI?:
By making the NAS a “node” you will lose such things as the ability to replicate to other nodes…
Meaning like a secondary backup?
… and multicast tasks.
You mean deploying/Imaging multiple clients?
What would you suggest in my situation, whether it’s the easiest or not, to get connected to my NAS? What would you do?