FOG 1.1.1 : NAS and NFS issue : unable to change folder permission
-
Hi everybody.
First, sorry for my bad english but i’m french user …Second, i will explained the context :
- a FOG server, 1.1.1 version on a Debian 7 with IP address
- a NAS disk 1TB Seagate Black Armor 220, updated at the last firmware with IP address
I have the same fog user / password on the server and NAS.
The AIM : stock FOG client images on the NAS disk.
The issue : after a good PXE boot client, i can see this NFS error : mounting 10.xxx.xx.xx:/img_NAS on /images failed : Permission denied.
(like this error : [url]http://fogproject.org/wiki/index.php/Image_Upload:_Error_Checking_Mount[/url])On the NAS, i have created a share folder namned “fogimages” with “full access” permission for “fog” user.
On the FOG server, i have set up the NFS share with this configuration :
/etc/fstab :
1xx.xxx.xxx.xxxx:/DataVolume/fogimages /mnt/img_FOG nfs nouser,auto,rw,dev,exec,suid,nfsvers=3 0 0
(same error with 1xx.xxx.xxx.xxxx:/DataVolume/fogimages /mnt/img_FOG nfs defaults 0 0)/etc/exports :
/mnt/img_FOG *(ro,sync,no_wdelay,insecure_locks,no_root_squash,insecure)
/mnt/img_FOG/dev *(rw,sync,no_wdelay,no_root_squash,insecure)ls -la on /mnt :
drwxrwxr-x 3 root 1000 4096 juin 27 15:01 img_FOG : strange group … 1000 ?ls -la on /mnt/img_FOG :
drwxr-xr-x 2 nobody nogroup 4096 juin 27 15:01 dev
-rw-r–r-- 1 nobody nogroup 0 juin 27 14:53 .mntcheckls -la on /mnt/img_FOG/dev :
-rw-r–r-- 1 nobody nogroup 0 juin 27 14:53 .mntcheckWhen i do this command : chown -R fog:root /mnt/img_FOG, i have this error message :
chown: changement de proprietaire pour "/mnt/img_FOG/dev/.mntcheck " : Operation non permise
chown: changement de proprietaire pour " /mnt/img_FOG/dev " : Operation non permise
chown: changement de proprietaire pour " /mnt/img_FOG/.mntcheck " : Operation non permise
chown: changement de proprietaire pour " /mnt/img_FOG " : Operation non permiseI understood it’s a permission issue but i can change them on the FOG server.
What can i do / check ?Regards,
Jonathan.
-
Hi,
I think, i have a similar problem like this topic : [url]http://fogproject.org/forum/threads/permission-denied-when-trying-to-image-after-update-to-1-1-1-1-1-2.10941/#post-31514[/url]I have run a debug task on a client with the same issue : Permission denied when i try “mount -o nolock …”
Maybe my /etc/exports file is wrong … ?
-
[quote=“Jonathan Cool, post: 31811, member: 24834”]Hi,
I think, i have a similar problem like this topic : [url]http://fogproject.org/forum/threads/permission-denied-when-trying-to-image-after-update-to-1-1-1-1-1-2.10941/#post-31514[/url]I have run a debug task on a client with the same issue : Permission denied when i try “mount -o nolock …”
Maybe my /etc/exports file is wrong … ?[/quote]
Try this:
chmod -R 777 /mnt/img_FOG; -
I can’t change the rights
[CODE]root@image:/# chmod -R 777 /mnt/img_FOG
chmod: modification des permissions de " /mnt/img_FOG ": Operation non permise
[/CODE] -
You may need to change the permissions FROM the NAS.
-
i haven’t SSH access on the NAS. Just a web interface (Black Armor 220) and i have set all rights for “root” and “fog” users on this folder (/fogimages) …
-
[quote=“Jonathan Cool, post: 31649, member: 24834”]The issue : after a good PXE boot client, i can see this NFS error : mounting 10.xxx.xx.xx:/img_NAS on /images failed : Permission denied.[/quote]
Which directory is FOG Storage Management trying to use?
img_NAS or img_FOG?
-
I’m trying to use img_FOG on the Storage Management section in the FOG web interface.
-
hi.
Now it’s works !
The problem was a false storage management configuration for the NAS.
[I]Howto works with NAS[/I] (Seagate Blakc Armor, last firmeware):
[U]/etc/fstab[/U] :
IPadr_NAS_Seagate:/DataVolume/fogimages /mnt/img_FOG nfs auto,rw,dev,exec,nfsvers=3 0 0[U]/etc/exports[/U] :
/mnt/img_FOG *(rw,sync,no_wdelay,no_root_squash,insecure,fsid=2)
/mnt/img_FOG/dev *(ro,sync,no_wdelay,insecure_locks,no_root_squash,insecure,fsid=1)[U]ls -la /mnt[/U] :
drwxrwxr-x 4 root nfsfog 4096 juil. 2 08:09 img_FOG[U]/etc/passwd[/U] :
fog1001:1001::/home/fog:/bin/bash
[U]/etc/group[/U] :
fog1001:[U]On interface, Add Storage Management[/U] :
IP Adr : “IP of NAS”
Is Master Node : No
Image Path /DataVolume/fogimages (path of the NAS)
Management Username : fog (it’s a fog user on NAS)Done !
Now, i can upload an image on the NAS Storage
-
Hi !
Hm … i’m sorry but it’s not good … just after an upload image, the folder /dec/@mac couldn’t seem moved to /name_of_image … I think, it’s a problem with folder / owner permission … i can connect to the NAS folder by FTP (with fog user) and create / delete a file / folder in …/dev/@MAC.
When i’m connected to the NAS folder by FTP, i can see, for all folders : owner:group = ftp:ftp … -
This is a known issue with NAS. Which one I don’t know, so i’m just guessing all.
To fix, you need to reconfigure the NAS’s FTP home settings to mount into the proper location as well.
Essentially, as I understand it, NFS mount’s properly because you specify where it’s looking:
e.g. /volume1/images/In FTP, it strips the first folder (/volume1/) during connection, so it’s essentially trying to ftp the files to a non-existent folder:
/images
One way you could test to verify is link your /img_FOG folder to the root of the NAS Share.
-
[quote=“Tom Elliott, post: 32392, member: 7271”]One way you could test to verify is link your /img_FOG folder to the root of the NAS Share.[/quote]
When i try to mount (by fstab) :
1xx.xxx.xxx.xxxx:/DataVolume/ /mnt/img_FOG nfs nouser,auto,rw,dev,exec,suid,nfsvers=3 0 0mount -a say : mount.nfs : access by server while mounting 1xxx.xxx.xxxx.xx:/DataVolume/
If i try to mount 1xx.xxx.xxx.xxxx:/DataVolume/fogimages, the “mount -a” command works … but the problem is the same …
arg ! -
Hi.
I found a temporary solution : after the upload, i connect to the NAS by FTP and move the files into …/fogimages/dev/@MAC to …/fogimages/“folder named in FOG interface”.
After that, the download task works on an other computer but only for Mint Linux OS … (other distrib’ not tested yet). With Windows 7 image, i have an error message …
Maybe i need to create a new topic about this new issue ?