Can't run chown -R fogproject:root /images/
-
Hi,
I’m currently facing an issue while configuring a new NFS-mounted directory in FOG Project. I’ve set up a new shared folder on my NAS at //volume2/imagesfog1 with a user account named fogproject having read and write permissions.The mounting process seems successful, but I’m encountering problems with changing ownership on the /images directory. Specifically, I’m unable to use the chown command as I get “Operation not permitted” errors for certain files and directories.
Here are the commands I’ve tried:
sudo chown -R fogproject:root /images
The error messages include:
/images/dev/.mntcheck
/images/dev
/images/.mntcheck
/images/#recycle/desktop.ini
/images/#recycle
/imagesCould someone please guide me on how to overcome this issue? I’ve read through the forums and documentation but haven’t found a solution yet. I should mention that I am not very experienced, as I am currently a trainee in a company
Any help would be greatly appreciated. Thank you!
-
@GlaDio Can you give the full error?
And can you also give us the output ofls -l /images
Also, what exactly are you trying to configure? Are you wanting to set up a separate storage node on a NAS? Are you trying to mount an nfs share on the fog server that you’re hoping will then mount to clients via the fog server? Are you trying to move the /images directory from the server to a NAS?
-
@JJ-Fullmer Sure, the full error is :
[root@srvclone techlabo]# chown -R fogproject:root /images/
chown: modification du propriétaire de ‘/images/dev/.mntcheck’: Opération non permise
chown: modification du propriétaire de ‘/images/dev’: Opération non permise
chown: modification du propriétaire de ‘/images/.mntcheck’: Opération non permise
chown: modification du propriétaire de ‘/images/#recycle/desktop.ini’: Opération non permise
chown: modification du propriétaire de ‘/images/#recycle’: Opération non permise
chown: modification du propriétaire de ‘/images/’: Opération non permise
(sorry its in french)And the output for ls -l /images :
[root@srvclone techlabo]# ls -l /images
total 8
drwxrwxrwx. 2 1024 users 4096 4 déc. 22:24 dev
drwxrwxr-x. 2 root root 4096 4 déc. 18:41 ‘#recycle’I am setting up a new configuration where I’ve created a shared folder on the NAS at //volume2/imagesfog1.
The goal is to mount this NFS share on the /images directory using the ‘mount’ command and make it automatic on boot by adding an entry to /etc/fstab. Essentially, I’m trying to establish a connection between the Fog server and the NAS for storage purposes. -
@GlaDio Now I could be wrong about this but I don’t think this is how you want to go about this.
Maybe if your NAS can do iscsi you could do that as it would appear more like a real disk but because you would have a file share for what is also a file share you’ll probably run into problems. The client will try to mount the /images share from fog but even if it is successful, that client won’t in turn be able to chain to the next file share. Even if that did work, you’re adding another link in the chain during imaging that could be unreliable.I believe there’s some old guides around on setting up a NAS as a storage node. It’s much better to have a full linux server where you can install fog as a storage node, but technically speaking it can be made to work by simply having an NFS share to point to as a storage node. Here’s one from the wiki that hasn’t been converted to the new docs site just yet https://wiki.fogproject.org/wiki/index.php?title=NAS_Storage_Node
I would suggest going that route instead. I’ve tried to make sub directories of the /images folder that are share paths (like for drivers for driver injection) but found that clients couldn’t get to them after mounting the /images share and I believe you’d run into the same issue.
All that said, if you want to continue down this other path the permissions probably need to be set on the NAS first then on FOG. There’s also probably some special nfs mount parameters to make it read/write and to allow permission changes to traverse.
-
@JJ-Fullmer Ok so if i understand, i need to install a fog project server on the nas and then install a fog project on my fedora machine with the mode storage install ? Thank you for your help, i appreciate it !
-
@GlaDio Check out https://docs.fogproject.org/en/latest/storage-node
Your existing fog server will manage the database. You can set up your NAS as a storage node or a separate server as a storage node by running the fog installer in storage node mode on that server.
Then you can set an image to be synced between the main server and the node or set an image to only be stored on the node and clients will boot to the fog server which will point them to the storage node to download the image.
-
@JJ-Fullmer Okay then, i’ll go for that ! For the moment i’m trying to test my fog server without the nas but when everything will be okay i will setup like you said. Thank you for your help !