LinuxQuestions.org
Register a domain and help support LQ
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 06-03-2007, 07:19 PM   #1
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Rep: Reputation: 0
Fedora 7 and using cifs in fstab?


Due to a dead harddrive, I'm rebuilding my linux machine a new drive and Fedora 7. Unfortunately, I cannot get my windows shared directories to mount correctly.

From FC5, my fstab had this line:
//192.168.0.101/n /mnt/p4/c smbfs credentials=/root/.smbpassword,dmask=777,fmask=777 0 0


After reading the various posts it seems that cifs has issues, but I finally set my fstab file with this line:

//192.168.0.101/n /mnt/p4/n cifs credentials=/root/.smbpassword,dir_mode=0777,file_mode=0777 0 0


Everything "looks" good (directory and file rights), but in reality I cannot write to any file.

In the many combinations I've tried (now lost count of) to access the shared drive, I usually end up with file rights of "rwxrwSrwt".

What am I doing wrong?

Thanks
 
Old 06-04-2007, 07:04 AM   #2
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 56
Try something like;

//192.168.0.101/n /mnt/p4/n cifs credentials=/root/.smbpassword,users,rw umask=008 0 0
 
Old 06-04-2007, 01:55 PM   #3
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Unfortunately, when I mount manually, the following error message is returned:

[mntent]: line 9 in /etc/fstab is bad

What could I be doing wrong?
 
Old 06-04-2007, 02:26 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,925

Rep: Reputation: 747Reputation: 747Reputation: 747Reputation: 747Reputation: 747Reputation: 747Reputation: 747
Syntax error.
Quote:
//192.168.0.101/n /mnt/p4/n cifs credentials=/root/.smbpassword,users,rw umask=008 0 0
Should be
.... credentials=/root/.smbpassword,users,rw,umask=008....
 
Old 06-04-2007, 05:30 PM   #5
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 56
Yep, thanks michaelk for catching my typo.
 
Old 06-14-2007, 09:57 PM   #6
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Sorry for the delay, I've been out of town for the last week.

I updated fstab for the typo, but still can't write to a file. Directories look fine, but all files are listed with file rights of "-rwxrwSrwt".

Just so there isn't any confusion, here is my fstab:

//192.168.0.101/n /mnt/p4/n cifs credentials=/root/.smbpassword,users,rw,umask=008 0 0

Any ideas what is wrong?

Thanks!!!
 
Old 06-14-2007, 10:27 PM   #7
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 56
Looks OK to me.........
Code:
//192.168.49.50/Laserfiche      /mnt/Desktop    cifs noauto,credentials=/home/lenard/bin/cifs.txt,users,rw,umask=008 0 0
Could be that you have not updated the samba packages.........

me i'm using the samba packages from samba.org rebuilt from the source using the Red Hat spec file found inside the extracted source.

http://us1.samba.org/samba/ftp/Binar....25a-1.src.rpm
 
Old 06-15-2007, 02:56 PM   #8
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Original Poster
Rep: Reputation: 0
Thanks for the message.

I double checked and I'm using samba version 3.0.25a-3.fc7 so I'm up to date.

I also tried adding the "noauto" to my fstab, but there was no change.

Any other ideas?
 
Old 06-15-2007, 03:15 PM   #9
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 56
No not really, does the share mount when done by hand???

mount-t cifs //192.168.0.101/n /mnt/p4/n credentials=/root/.smbpassword -rw

What does the smbpassword file look like, for example it should be something like(notice the spacing):

username = fred
password = letmein


The 'noauto' option is used because I do not need or want full time access to the share. i just posted mine as an example for comparison.
 
Old 06-15-2007, 06:36 PM   #10
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Original Poster
Rep: Reputation: 0
If I mount manually, nothing changes. I can see files, open them,but can't save anything. Yes, my credentials file looks correct.

I also tried connecting to a different XP machine where I shared the drive with the same results. Directories are wide open, but file show rights of "-rwxrwSrwt" and cannot write to any file or put a new file into a directory.

Not that it makes a difference, but the first machine (n drive in fstab) is a NTRS drive, while the second XP machine is using a fat32 drive. I've also tried turning selinux and firewalls off -- no change.

What else should I try (besides putting linux on the xp boxes).

Thanks
 
Old 06-16-2007, 05:22 AM   #11
Lenard
Senior Member
 
Registered: Dec 2005
Location: Indiana
Distribution: RHEL/CentOS/SL 5 i386 and x86_64 pata for IDE in use
Posts: 4,790

Rep: Reputation: 56
This is expected and normal: file show rights of "-rwxrwSrwt"

Example: -rwxrwSrwt 1 root root 249K Mar 6 10:09 tzupdater-1_0_1.zip

Are you mounting as root and your normal user account does not have write access???
Try making the user part of the groups, using my groups as an example;
$ groups lenard
lenard : lenard root daemon sys adm disk wheel
 
Old 06-16-2007, 08:20 PM   #12
powellbob424
LQ Newbie
 
Registered: Jun 2006
Posts: 6

Original Poster
Rep: Reputation: 0
OK, I've made some progress, but am still not there yet.

First, as suggested, I made sure that the group "users" (which already existed) contained both my usual username "bob" along with "root".

As bob, I can now edit/save a file and copy files into existing directories, but if I use gedit to edit a file it complains that it can't make the backup file.

As root, however, I still can't edit/save/copy files even though root owns all files. Directories are still show as wide open and file have "-rwxrwSrwt" for both bob and root.

Any more ideas?
 
  


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
cifs fedora 6 baldur_the_god Linux - Server 7 08-29-2007 01:07 PM
cifs mount in fstab help nitrohuffer2001 Linux - Software 1 04-22-2007 05:09 PM
Mounting windows share via cifs (fstab entry) - error 13 opening credentials file O(V)eGA_l2el) Linux - Networking 2 12-05-2006 11:22 AM
Win2k Fedora Samba\CIFS woes Lexical Unit Linux - Networking 0 09-13-2004 10:49 PM
kernel CIFS module on Fedora nicolax Linux - General 2 02-18-2004 10:21 AM


All times are GMT -5. The time now is 01:41 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