LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-28-2004, 09:10 AM   #1
jalperin
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Rep: Reputation: 0
Fstab problem with Samba


I'm trying to automatically mount a second hard drive every time I boot up and then share it with Samba so that a networked Windows XP machine can access it.

I included the following line in my /etc/fstab file:
/dev/hdg1 /mnt/backup80 ext3 auto,user,rw,exec,suid 0 0

My Samba smb.conf file has the following section:
[music]
path = /mnt/backup80
browseable = yes
public = yes
write list = jeff


When I view the Samba shares through Konqueror, I can see the music share, but when I try to view its contents, I get the error:
The file or folder smb://duke/music does not exist.

I can browse /mnt/backup80 with no problem.

What's happening and how do I fix it? Thanks. --Jeff
 
Old 08-28-2004, 09:33 AM   #2
amfoster
Member
 
Registered: Aug 2004
Distribution: debian, SuSE
Posts: 365

Rep: Reputation: 35
I believe you have never actually mounted the share.

You are simply looking at what is shared in Konqueror.

Your Win box shud be able to access that mount assuming you started the samba daemons and you have a means of authenticating
 
Old 08-28-2004, 09:35 AM   #3
michaelk
Moderator
 
Registered: Aug 2002
Posts: 15,384

Rep: Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650Reputation: 1650
Have you checked your smb.conf file with the testparm command?
The following console command should show your music share.
smbclient -L <your_hostname>
 
Old 08-28-2004, 10:27 AM   #4
jalperin
LQ Newbie
 
Registered: Aug 2004
Posts: 10

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

I can see the music share from Windows XP, but when I try to access it, it asks for username and password and then won't accept the correct username password. I've even tried inputting it in several different forms (DUKE\jeff, jeff@DUKE, etc.). I have another Samba share set up exactly the same way and I don't have to enter a password to see it. The only difference between that share and the music share is that it points to a directory on the bootup hard disk (specifically, /var/www/html). That's why I thought the problem was with how I mounted using fstab.

I have used testparm and everything checks out ok. When I execute the
smbclient -U jeff -L duke command, it can see the share, but I still don't seem to be tp access it.

Other thoughts? I'm new at this, so maybe I'm overlooking something simple.
 
Old 08-28-2004, 10:32 AM   #5
amfoster
Member
 
Registered: Aug 2004
Distribution: debian, SuSE
Posts: 365

Rep: Reputation: 35
The security setting in your smb.conf is probably reading
security = user

With this setting you must create samba users.
If you have an account for jeff on the Linux box, then execute
smbpasswd -a jeff password

substitute a password where I wrote password above.

This will create a file named /etc/samba/smbpasswd and it will be used for the username and password prompt on the Windows box.

You can change security = user to security = share, but anyone in the same work group will have access to that music directory.
 
Old 08-28-2004, 11:43 AM   #6
jalperin
LQ Newbie
 
Registered: Aug 2004
Posts: 10

Original Poster
Rep: Reputation: 0
I don't think it's the security issue you discussed because I already had that user/password setup. But I think I found a solution; I just don't understand why it works.

I added the following to my fstab:
/dev/hdg1 /var/www/html/music ext3 defaults 0 0 and then setup a section in my smb.conf and voila -- it worked just fine

Note that this line in my fstab:
/dev/hdg1 /mnt/backup80 ext3 defaults 0 0 (which is identical except for the /mnt/backup80 still doesn't work.

So is there some sort of problem with Samba browsing a /mnt ?
 
Old 08-28-2004, 03:25 PM   #7
amfoster
Member
 
Registered: Aug 2004
Distribution: debian, SuSE
Posts: 365

Rep: Reputation: 35
Mounting under the mountpoint /mnt/somedirectory doesn't give me an error as long as the mount point exists. Is is possible that you didn't have a directory named /mnt/backup80 ?
 
  


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
fstab problem: mount: can't find dvd in /etc/fstab or /etc/mtab Nikon01 Slackware 5 11-17-2006 06:15 AM
samba fstab gunnix Debian 4 07-02-2005 08:16 AM
fstab and samba? shanenin Linux - Networking 2 12-27-2004 04:52 PM
Samba in fstab, problem hraposo Debian 9 12-16-2004 06:36 AM
Samba and fstab Celettu Linux - Networking 2 07-13-2004 12:43 PM


All times are GMT -5. The time now is 11:28 AM.

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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration