How to: Use FOG (1.1.2) with FreeNAS (Storage node - 9.1.1)
-
Hello.
I have often seen people want to use Fog Server with a Storage Node FreeNAS. At my office, it works so i describe you step by step how to do.
There are probably several solutions i think, but i propose you a simple solution that works with me.I consider that your FreeNAS is ok for the installation and NIC.
[U]Fog Server[/U]: 192.168.56.102
[U]FreeNAS[/U]: 192.168.56.240[U][SIZE=5]FOG Server:[/SIZE][/U]
[U]Step 1[/U]: Storage Management
Add the Storage node.Storage Node Name: FNAS
IP Address: 192.168.56.240
Is Master Node: As you want.
Group: As you want.
Image Path: /mnt/Volume1/data/images
User/Pass: Free/Free (Not very secure )[U]Step 2[/U]: Image Management
For your image, choose the storage group witch contains the new storage node.[SIZE=5][U]FreeNAS[/U][/SIZE]:
[U]Step 1[/U]: Add Volume1
Storage -> ZFS Volume Manager:Volume Name: Volume1
Volume layout: All the disk (in my case)[U]Step 2[/U]: Create the path
Clic on [B]Volume1[/B] -> Create ZFS Dataset:
Dataset Name: [B]data[/B]
Compression level: inherit
Enable atime: inherit
ZFS Deduplication: inheritClic on[B] data[/B] -> Create ZFS Dataset:
Dataset Name: [B]images[/B]
Compression level: inherit
Enable atime: inherit
ZFS Deduplication: inheritClic on [B]images[/B] -> Create ZFS Dataset:
Dataset Name: [B]dev[/B]
Compression level: inherit
Enable atime: inherit
ZFS Deduplication: inherit[IMG]http://image.noelshack.com/fichiers/2015/18/1430127023-freenas42.png[/IMG]
[U]Step 3[/U]: Create .mntcheck
On the folder “/images” and “/dev”, create the file “.mntcheck”
CMD: touch .mntcheck
[U]Step 4[/U]: Create new user.
Account -> Users -> Add User
Username: Free
Primary Group ID: Free
Home Directory: /mnt/Volume1/data/images
Home Directory Mode: 777[IMG]http://image.noelshack.com/fichiers/2015/18/1430127205-freenas43.png[/IMG]
[U]Step 5[/U]: Permission for the path
Storage -> clic on data/images -> Change Permissions
User: Free
group: Free
Mode: 777
Type of ACL: Unix
Set Permission recursively: [B]YES[/B][U]Verification[/U]: cmd: ls -laR /mnt/Volume1/data/images
[U]Step 6[/U]: NFS
Don’t edit “/etc/exports”. In my case, when i restart the service, the file faded. I had to WEBGui.On the left.
Sharing -> Inux (NFS) Shares -> Add Unix (NFS) Share.Comment:…
Authorized networks: 192.168.56.0/24
All directories: OK
Maproot User: Free
Maproot Group: Free
Path: /mnt/Volume1/data/imagesOK.
[IMG]http://image.noelshack.com/fichiers/2015/18/1430127941-freenas44.png[/IMG]Idem for the folder “/dev”
[IMG]http://image.noelshack.com/fichiers/2015/18/1430128040-freenas45.png[/IMG][U]Verification[/U]: cmd: cat /etc/exports
[IMG]http://image.noelshack.com/fichiers/2015/18/1430128125-freenas46.png[/IMG][U]Step 7[/U]: FTP (I don’t know if it’s really necessary)
Services -> FTP -> Advenced Mode
Path: /mnt/Volume1/data/images
File Permission: 666
Directory Permission: 777Now: you can upload your client.
Problem, you may also get an error message at the end: FOGFTP: failed to rename file.
[url]http://www.fogproject.org/wiki/index.php/Images_Directory_Permissions[/url]Method 1 doesn’t works with me, so i use method 2.
[IMG]http://image.noelshack.com/fichiers/2015/18/1430128580-freenas47.png[/IMG]
CMD: cp -a /mnt/Volume1/data/image/dev/@MAC /mnt/Volume1/data/images/NameOfYourImage
cp -a to keep the same permission.
That’s it. If I have forgotten nothing, you can use FreeNAS with FOG Server
-
[quote=“Slowave, post: 46249, member: 29028”]Slowave,[/quote] thanks for posting your instructions.
They are also now located here in the WiKi: [url]http://fogproject.org/wiki/index.php/Use_FOG_with_FreeNAS[/url]
-
References also entered in:
[url]http://fogproject.org/wiki/index.php/NAS_Storage_Node[/url]
[url]http://fogproject.org/wiki/index.php/Knowledge_Base#Storage_Nodes[/url] -
I see an error: [url]http://fogproject.org/wiki/index.php/Use_FOG_with_FreeNAS[/url]
Step 6:
[U]Verification[/U]: cmd: cat /etc/exports. It’s not the good image.
-
fixed. sorry about that.
-
Cleaned up [url]http://fogproject.org/wiki/index.php/Use_FOG_with_FreeNAS[/url] to keep with some formatting guideslines. Let me know if I messed anything up.