LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 12-26-2007, 04:31 AM   #1
yusufs
Member
 
Registered: Oct 2007
Posts: 162

Rep: Reputation: 30
samba drive permission denied


Hai all,

As root, Mounted a windows dir using samba in my RHEL ES 4.0 box ..

like

mount -t smbfs -o username=dba //192.168.0.84/archive /mnt/archive

and password is given and successfully mounted..

problem is that only root user can write to this directory and not others and I tried changing the directory permission and even tried changing the ownership.. when an normal user is trying like :


[oratest@oracle ~]$ touch /mnt/archive/new1.txt
touch: cannot touch `/mnt/archive/new1.txt': Permission denied

How can I resolve this ?


Yusuf
 
Old 12-26-2007, 04:45 AM   #2
DinoFly
Member
 
Registered: Nov 2007
Distribution: Fedora, CentOS,
Posts: 72

Rep: Reputation: Disabled
Quote:
Originally Posted by yusufs View Post
Hai all,

As root, Mounted a windows dir using samba in my RHEL ES 4.0 box ..

like

mount -t smbfs -o username=dba //192.168.0.84/archive /mnt/archive

and password is given and successfully mounted..

problem is that only root user can write to this directory and not others and I tried changing the directory permission and even tried changing the ownership.. when an normal user is trying like :


[oratest@oracle ~]$ touch /mnt/archive/new1.txt
touch: cannot touch `/mnt/archive/new1.txt': Permission denied

How can I resolve this ?


Yusuf
Hi Yusuf is 192.168.0.84 your machine? You should check permisions on //192.168.0.84/archive.
 
Old 12-26-2007, 05:19 AM   #3
yusufs
Member
 
Registered: Oct 2007
Posts: 162

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by DinoFly View Post
Hi Yusuf is 192.168.0.84 your machine? You should check permisions on //192.168.0.84/archive.


Thanks Dino,

192.168.0.84 is my machine..

I've given complete full rw access to all the users.. but as root users I can able to rw on the mounted drive /mnt/archive.. but not as other users..


Any comments ?

Yusuf
 
Old 12-26-2007, 07:40 AM   #4
alkos333
Member
 
Registered: Dec 2006
Posts: 271

Rep: Reputation: 31
If you want to allow the regular user to access the files add the following to your -o flag: "uid=<user>,gid=<group"
 
Old 12-27-2007, 02:19 AM   #5
yusufs
Member
 
Registered: Oct 2007
Posts: 162

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by alkos333 View Post
If you want to allow the regular user to access the files add the following to your -o flag: "uid=<user>,gid=<group"


Thanks alkos,, but the following command failed :


mount -t smbfs -o flag:uid=oratest,gid=501 username=dba//192.168.0.84/archive /mnt/archive

Do I have to make any changes ?.. if so, where.. where can I add rw in this command..


Please clarify


Thanks
Yusuf
 
Old 12-28-2007, 01:43 PM   #6
alkos333
Member
 
Registered: Dec 2006
Posts: 271

Rep: Reputation: 31
Code:
mount -t smbfs -o uid=oratest,gid=501,username=dba //192.168.0.84/archive /mnt/archive
Also, post the errors you get - that helps to clarify things quite a bit.
 
Old 12-29-2007, 12:48 AM   #7
yusufs
Member
 
Registered: Oct 2007
Posts: 162

Original Poster
Rep: Reputation: 30
Quote:
Originally Posted by alkos333 View Post
Code:
mount -t smbfs -o uid=oratest,gid=501,username=dba //192.168.0.84/archive /mnt/archive
Also, post the errors you get - that helps to clarify things quite a bit.


Thanks Alkos,

it worked fine .


root@oracle oracle]# mount -t smbfs -o uid=oratest,gid=501,username=dba //192.168.0.84/archive /mnt/archive
params.c:Parameter() - Ignoring badly formed line in configuration file: set path
Password:

Thanks
Yusuf
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
'permission denied" inspite of right permission flags on network drive anirudhvij Linux - Enterprise 8 05-22-2007 05:57 AM
Samba Permission Denied Adairen Linux - Software 6 12-11-2006 09:05 AM
Samba error: Permission denied dmkang Linux - Software 6 04-01-2005 08:29 AM
cd drive: permission denied aje Slackware 5 11-11-2004 08:50 PM
Permission denied with Samba and Win2k richa65 Linux - Software 8 08-29-2003 11:11 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 08:10 PM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration