Using SMB as default node
-
Hello, I’m trying to use FOG with a windows shared folder.
I’ve created the folder on windows and mounted on Ubuntu 22.04:
mount -t cifs //x.x.x.x/images /mnt/iso -v -o credentials=/home/user/.smbcredentials,file_mode=0777,dir_mode=0777,
I have access to the folder and can create/edit files. I also copied the folder /images to /mnt/iso/images
On fog I changed the default node Image Path and FTP path to /mnt/iso/images.
But when I try to capture the image I get the following error:
mounting x.x.x.x:/images/dev on /images failed: permission denied
Checking Mounted File System
An error has been detected.
Fatal error: Failed to mount NFS Volume
Computer will reboot in 1 minute.Any help would be greatly appreciated!
-
So this will not work for a few reasons, but it is possible to use windows.
Why it won’t work
When you boot into fog (FOS - Fog Operating System) it has loaded on the client machine.
The client machine then mounts an nfs share to upload/download an image from.
If your nfs share is pointing to another file share, the client only has access to the first NFS share, nfs won’t share out that smb share. I once tried to do something similar in a subfolder of /images for drivers. It has to be local.However, it is possible to create a storage node that is just an nfs share, and you can create an nfs share on a windows machine (preferably a windows server install).
We need to update the this doc still to be in the fog docs site and to apply to newer versions of windows but the general principles outlined in this wiki article https://wiki.fogproject.org/wiki/index.php?title=Windows_Storage_Node should still apply.
Essentially you need to
- Add the nfs server feature/role to the windows machine
- Create an nfs share on windows
- add a storage node definition in fog that points to the windows nfs share (see also https://docs.fogproject.org/en/latest/storage-node for info on storage nodes in general)
- there are some other steps to ensure you capture to the storage node as you configure the storage group/node that I don’t recall off the top of my head
-
-
@JJ-Fullmer Thank you, In the end I opted to add a second disk, structurewise couldn’t add the nfs,
Regards.