Permission denied error using chmod on a cifs mount

 
Thread Tools Search this Thread
Operating Systems Linux Red Hat Permission denied error using chmod on a cifs mount
# 1  
Old 02-19-2015
Permission denied error using chmod on a cifs mount

I have a RHEL 5.7 system with a cifs mount from a Windows 2007 file server that I need to fix the permissions on. Once the share is mounted the permission for the mount are 777. I need to change that to 770 on the top level directory and to 640 on the sub-directory .ssh/. But when I run chmod against it I get a permission denied error.

This is the line in my /etc/fstab file:

Quote:
//dvvn-mp-nas.lamar.edu/bmt_edi /home/srv_bmt_edi cifs rw,credentials=/etc/bmt_edi_cred.txt,uid=516,gid=522 0 0
The "credentials file contains the username and password used to authenticate to the file server. I associate it to a particular user/group on the RHEL system with the gid/uid options.

This is what the permissions look like after it's mounted:
Quote:
[root@mgmtprod01r5v ~]# ls -lha /home/ | grep srv_bmt
drwxrwxrwx 1 srv_bmt_edi srv_bmt_edi 12K Feb 19 14:14 srv_bmt_edi

and

[root@mgmtprod01r5v ~]# ls -lha /home/srv_bmt_edi/
total 224K
drwxrwxrwx 1 srv_bmt_edi srv_bmt_edi 12K Feb 19 14:14 .
drwxr-xr-x 23 root root 4.0K Dec 4 11:08 ..
drwxrwxrwx 1 srv_bmt_edi srv_bmt_edi 0 Feb 9 11:28 .ssh

As you can see, the perms are set to 777. I need to change these to 770 for /home/srv_bmt_edi/, I need to change my /home/srv_bmt_edi/.ssh/ sub-directory perms to 700 and I need to change the perms for my .ssh/authorized_keys file to 640. But when I try I get a permission denied error:

Quote:
[root@mgmtprod01r5v ~]# chmod 770 /home/srv_bmt_edi/
chmod: changing permissions of `/home/srv_bmt_edi/': Permission denied
I had this same share mounted as an smbfs share on a RHEL 4 box and it worked well. I'm sure it has something to do with my mount options but for the life of me I can't see what I'm doing wrong. Any help would be very much appreciated.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Linux

new file group permission of CIFS mount

After switching from smbfs mount, the dmask/dir_mode and fmask/file_mode no longer have an effect on the newly created files. It seems to use the system umask instead. I need the group to have write permissions without changing the root umask on the system. Any ideas? example fstab: ... (0 Replies)
Discussion started by: gadgetx23
0 Replies

2. UNIX for Dummies Questions & Answers

Permission Denied creating file under nfs mount

I have two servers, 82 and 70. My exports file on 82 reads / ...70(rw) on 70 I have a mountpoint called mnt_for_82 I execute on 70 mount -t nfs -o rw ...82:/ mnt_for_82 I go to server 70 and indeed can read and travers the mounted subdirectories. However, I try... (0 Replies)
Discussion started by: blaine.miller
0 Replies

3. AIX

Permission denied when rm or chmod

I got "Permission denied" error message when I rm or chmod a file. I'm the owner of the file "lice_20091123.tar". How can I solve this matter? lice@appl:/midasapp/lice> whoami lice lice@appl:/midasapp/lice> who am i guest pts/12 Nov 23 19:09 (ooo.ooo.ooo.oo) ... (3 Replies)
Discussion started by: kang
3 Replies

4. UNIX for Advanced & Expert Users

mount -t cifs permission denied by mount -t smbfs works fine

I am having trouble mounting with cifs, but mounting the exact same command with smbfs works fine. The share is on another samba server and is set to full public guest access. # mount -t cifs //servername/sharename /mnt/temp -o password="" mount error 13 = Permission denied Refer to the... (3 Replies)
Discussion started by: humbletech99
3 Replies

5. OS X (Apple)

Permission Denied Error with X11

Hello, I am using Tiger 10.4.11 I am trying out the GIMP, so I installed the X11 package from "Optional Installs" on the cd. Whenever I open X11, I get an error: xterm: could not exec /dev/null: Permission denied I have chmodded /dev/null to 777, as well as the /tmp directory. I deleted... (2 Replies)
Discussion started by: Ricardo-san
2 Replies

6. UNIX for Dummies Questions & Answers

NFS Mount: Permission Denied

Hi, - I have two solaris 10 servers. One is running nfs server (let's call it server-1) and has a share set through /etc/dfs/dfstab file: share -F nfs /opt/SHARE (where SHARE directory contains sub-items that I want to share) - On server-1, I have started the nfs server service and have... (2 Replies)
Discussion started by: jackola
2 Replies

7. Shell Programming and Scripting

xterm gives me permission denied error

When I try to run xterm at a command prompt in solaris 2.5.1, i'm getting a permission denied error. But the directory and user permissions look ok, they are part of a users group and then also root,sys,adm so what gives? Any ideas? Thanks! (1 Reply)
Discussion started by: kymberm
1 Replies

8. UNIX for Advanced & Expert Users

getcwd: permission denied error

When I do a 'cd /appl' and issue 'ls -al' command, I get the following error for .. directory. ./..: Permission denied But still I get a listing of other directories under /appl. Also, if I give 'man' for any command under this /appl folder, I get the following error: ... (3 Replies)
Discussion started by: Deepa
3 Replies

9. UNIX for Dummies Questions & Answers

rm Permission Denied error

I am very new to Unix. We have a script that will remove files from a directory. The account removing the files has the same permissions as the directory the files are located. We have logged in as the account and deleted the files from that directory but when we run the script with the account... (7 Replies)
Discussion started by: Cech2002
7 Replies

10. UNIX for Advanced & Expert Users

mount: failed, reason given by server: Permission denied

Hi , I have a filesystem on AIX 4.3.3 which i need to share with other clients who use Windows NT and Redhat linux 7.3. I use samba to share this with Windows NT Clients. Now i was to share this with Linux clients. When i try to nfs mount this on Linux i get "mount: failed, reason given by... (1 Reply)
Discussion started by: Sushesh
1 Replies
Login or Register to Ask a Question