You are not logged in.

#1 2005-05-03 21:46:05

medicated
Member
From: Storm Lake, IA
Registered: 2005-03-11
Posts: 79

CIFS Default permissions..

I am having a few problems with a cifs mount.  First off, I can't mount the share unless I am root..kind of annoying.  Secondly..whenever I create a new file on the cifs share, its permission default to read only.  How do I go about specifying the default permissions..  After looking around recently..I've come across the "file_mode" argument in fstab, but it fails to do anything :s  When I check the permisisons, they're still read only..

Offline

#2 2005-05-03 21:50:18

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: CIFS Default permissions..

hmmm in the "options" column of your fstab (or the options passed to mount), add "users" (or is it "user"?) to allow users to mount it... also "umask=644" will give read access by default....

Offline

#3 2005-05-03 22:30:54

medicated
Member
From: Storm Lake, IA
Registered: 2005-03-11
Posts: 79

Re: CIFS Default permissions..

Yah, I have user in the fstab, but I still get an error..

mount error 1 = Operation not permitted
Refer to the mount.cifs(8) manual page (e.g.man mount.cifs)

And with umask to 755, still presents read only permissions.  Hmm..  I've searched all over for answers and just ended up confused.  Here is my current fstab

//web1-04/cacemic$ /mnt/pweb cifs user,noauto,credentials=/etc/cifs/cifs.web,umask=755 0 0 

Offline

#4 2005-05-03 22:38:58

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: CIFS Default permissions..

try the "rw" flag? also try replacing "user" with "users"

Offline

#5 2005-05-03 23:17:29

medicated
Member
From: Storm Lake, IA
Registered: 2005-03-11
Posts: 79

Re: CIFS Default permissions..

sad  Same thing.  Is there possibly a permissions issue with /sbin/mount.cifs?

lrwxrwxrwx  1 root root 18 2005-04-17 19:14 /sbin/mount.cifs -> /usr/bin/cifsmount

-rwxr-xr-x  1 root root 18572 2005-04-16 12:36 /usr/bin/cifsmount

Offline

#6 2007-08-11 19:36:42

b100dian
Member
Registered: 2007-06-09
Posts: 19

Re: CIFS Default permissions..

Altough 2 years later.. I had the same problem:)
I solved it by disabling CIFS Linux Extensions (cat 0 > /proc/fs/cifs/LinuxExtensions..or something).

This was the only way for file_mode and dir_mode to work. Alas, if these Linux Extensions don't already do what you mean;)

Offline

#7 2007-08-11 20:08:23

wonder
Developer
From: Bucharest, Romania
Registered: 2006-07-05
Posts: 5,941
Website

Re: CIFS Default permissions..

chmod +s /sbin/mount.cifs
chmod +s /sbin/umount.cifs
to solve the problem

my fstab
//192.168.0.3/D /mnt/pepi cifs username=Alexandru,password=1,noauto,users,uid=wonder,gid=users,file_mode=0644 0 0

Last edited by wonder (2007-08-11 20:11:05)


Give what you have. To someone, it may be better than you dare to think.

Offline

Board footer

Powered by FluxBB