LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 12-28-2008, 11:19 AM   #1
alkos333
Member
 
Registered: Dec 2006
Posts: 271

Rep: Reputation: 31
Mounting CIFS with write permissions


Code:
root@tpt60:~# umask
0022
root@tpt60:~# mount -t cifs //192.168.1.100/SharedDocs /mnt/cifs --verbose -o guest,user=me,uid=me,gid=users,rw
parsing options: rw,guest,user=me,uid=1000,gid=100

mount.cifs kernel mount options unc=//192.168.1.100\SharedDocs,ip=192.168.1.100,ver=1,rw,guest,user=me,uid=1000,gid=100 
root@tpt60:~# ls -ld /mnt/cifs
dr-xr-xr-x 1 me users 0 2008-12-26 12:07 /mnt/cifs/

Why aren't there write permissions for /mnt/cifs ? I can't write to the share with a regular user "me"
 
Old 12-28-2008, 01:31 PM   #2
TSquaredF
Member
 
Registered: Dec 2005
Location: "The South Coast of Texas"
Distribution: Slackware64-current
Posts: 490
Blog Entries: 1

Rep: Reputation: 55
Is your share mounted rw on the server? I'm using "user" security in my smb.conf. Here is the way I mount on the server:
Quote:
/dev/hdb1 /mnt/hal ntfs-3g auto,uid=1000,gid=100,dmask=007,fmask=117
Then on the client (in /etc/fstab):
Quote:
//server/hal /mnt/hal cifs auto,credentials=/home/user/.creds,nobrl
My credentials file is:
Quote:
username=user
password=passwd
The ids & masks are automagically the same on the client as on the server.
Regards,
Bill
 
Old 12-28-2008, 11:29 PM   #3
alkos333
Member
 
Registered: Dec 2006
Posts: 271

Original Poster
Rep: Reputation: 31
This is a windows XP share though.
 
Old 12-29-2008, 07:56 AM   #4
slack1992man
LQ Newbie
 
Registered: Dec 2008
Location: NYC
Distribution: Slackware 12.2
Posts: 5

Rep: Reputation: 1
This fixed it for me when using autofs

http://lists.samba.org/archive/linux...er/001590.html
 
Old 12-30-2008, 03:46 PM   #5
alkos333
Member
 
Registered: Dec 2006
Posts: 271

Original Poster
Rep: Reputation: 31
I tried disabling the Unix Extensions, but that didn't help. It still doesn't show write permissions after I re-mount the windows share.

This worked fine prior to 12.2 upgrade.

Last edited by alkos333; 12-30-2008 at 04:35 PM.
 
Old 03-02-2012, 12:16 PM   #6
NinjaVZ
LQ Newbie
 
Registered: Mar 2012
Posts: 1

Rep: Reputation: Disabled
Thumbs up mount.cifs with write access

To get the write access for the user who will be using the mount you need to assign the uid and gid options when creating the mount (example):

mount.cifs //server/share /home/mrodri/mountpoint -o rw,credentials=/home/mrodri/.creds,gid=502,uid=502

//server/share is the servername and share that you want to connect to
/home/mrodri/mountpoint is the mountpoint at folder mountpoint of user mrodri
credentials point to a hidden file .creds of a format like:
username=mrodri
password=_password_
domain=_NTdomain_
uid and gid are the user id and group id assigned by linux to the mrodri user. Check those with your user administration program, centos 6, system-administration-users and groups

this worked for me.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
CIFS/fstab New files auto write-protected johnnie_1983 Linux - Newbie 1 09-08-2007 05:50 AM
NFS share not mounting with read/write permissions syphoncode.32 Linux - Software 1 06-15-2007 02:46 AM
mounting windows share with write permissions gw1500se Mandriva 10 04-15-2007 03:10 PM
Suse 10.2 CIFS permissions problem btberlin Suse/Novell 2 12-28-2006 09:25 AM
Mounting FAT32 with write permissions? 65_289 Linux - General 14 06-05-2002 03:40 PM


All times are GMT -5. The time now is 12:18 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration