LinuxQuestions.org
Visit Jeremy's Blog.
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 12-31-2002, 06:45 AM   #1
nero64
LQ Newbie
 
Registered: Nov 2002
Location: My bedroom
Distribution: RH 7.1
Posts: 29

Rep: Reputation: 15
Samba woes


Well i couldn't get NFS working so i moved on to try Samba shares. Now i'm 0/2.

Every book and site i have read acts as though configuring samba is a breeze. Yeah just add a share to smb.conf and restart the samba service then your away. Well it ain't that simple.

I have followed the info to the letter. Yes the windows, Linux and samba accounts are all using the same name and password. I even went into the win 95 registry and added a key forcing clear passwords.

I am just wondering does everyone else have problems setting up samba for the first time (Judging by the posts they do). Is there any other Windows OS that is good for seeing that elusive or imaginary Linux machine. I am using win 95c and it ain't working.
 
Old 12-31-2002, 07:43 AM   #2
ixion
Member
 
Registered: Dec 2002
Location: USA
Distribution: SuSE, CentOS, Gentoo
Posts: 166

Rep: Reputation: 30
I would first of all recommend NOT using blank passwords. That confuses everything.

do this:

configure the smb.conf file with these arguments (you can tweak them later):

[global]
workgroup = *your domain*
server string = %h server (Samba %v)
invalid users = root
log file = /var/log/samba/log.%m
max log size = 1000
syslog = 0
encrypt passwords = true
socket options = TCP_NODELAY
dns proxy = no
passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\sUNIX\spassword:* %n\n *Retype\snew\sUNIX\spassword:*
%n\n .
obey pam restrictions = yes

then add the share. REMEMBER this:

create a new user on the 95 machine (user, password)
create a new user on the Linux machine (user, password)
type 'smbpasswd -a user' (w/o quotes) to add the user 'user' to the samba access list. Set all these with the same password. NOW, go and set the file permissions on the folder you are sharing to let the user 'user' access it locally. If you want to access a folder remotely on a Linux box, you first have to have permission to access it locally.

Please let me know if this helps or not. Setting up Samba IS a breeze when you know what you have to do. It's just finding someone who knows that's such a big problem.
 
Old 01-01-2003, 12:59 AM   #3
nero64
LQ Newbie
 
Registered: Nov 2002
Location: My bedroom
Distribution: RH 7.1
Posts: 29

Original Poster
Rep: Reputation: 15
Should the user i created be in the smbusers file. It is in the smbpasswd file but not the smbusers. How do i add a user that automatically inserts itself into this file. It says in the smb.conf that it maps names from that file.

I did what you said and still no go. I can see the workgroup from network neighbourhood which is called home, but i can only see the win95 machine, no linux machine and its share.

Just the other day i tried to set up DNS and i configured all the corresponding files. But it doesn't give me anything when i type nslookup. If i put a workgroup in the [global] section instead of a domain name does it matter.
 
Old 01-01-2003, 08:55 AM   #4
bubber
LQ Newbie
 
Registered: Dec 2002
Location: Aiken, SC
Distribution: Red Hat 8.0
Posts: 11

Rep: Reputation: 0
I had a degree of success with Samba starting real simple (as suggested by folks who know more than me). I use the following smb.conf file to let a RH8 box (a Micron) communicate with a Gateway running Win98 and a Vaio laptop running WinXP:

[global]
workgroup = COMPUTERLAB
netbios name = MICRON
server string = Micron Samba Server
security = share
log file = /var/log/samba/%m.log
max log size = 0
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
printing = lprng

;[homes]
; comment = Home Directories
; valid users = %S
; read only = No
; create mask = 0664
; directory mask = 0775
; browseable = No

[public]
path = /mnt/data
public = yes
guest only = yes
writable = yes
printable = no

[printers]
comment = All Printers
path = /var/spool/samba
public = yes
guest ok = yes
writable = no
printable = Yes
browseable = No

These boxes are in my study and are not connected to the internet. I believe that you may need a bit more work to produce a secure setup, but this may get you some initial success.
 
Old 01-01-2003, 02:23 PM   #5
ixion
Member
 
Registered: Dec 2002
Location: USA
Distribution: SuSE, CentOS, Gentoo
Posts: 166

Rep: Reputation: 30
happy new year, everybody!

anyway, are you starting the samba deamons on startup? What distro are you using (I apologize if I missed it)??

In Slackware, you can put the following lines in 'etc/rc.d/rc.local' or any other script that starts up (although I recommend rc.local, it's easier to keep track of) on boot. The lines are:

smbd -D
nmbd -D

Some distros come with an rc.samba file in the '/etc/rc.d/" directory, but I personally haven't messed with anything other than Mandrake and Slackware.

Also, remember that Mandrake will not allow servers to be started unless you install it in 'Higher' security mode. I ran into this problem a couple days ago on my laptop.

I would highly recommend using the 'domain master = yes' and there's another argument that makes the linux box the browser master for the local workgroup. This not only greatly improves network performance, but it will let your Windows boxes see eachother and the linux box everytime!

just curious, are you running any kind of firewall on the linux box?

Anyone who can fill in the blanks or correct me, please do.

Good luck!!

edit: by the way, you shouldn't have to mess with the smbusers file at all. To get rid of a user type "smbpasswd -x user" and then type "smbpasswd -a user" to add the user back into the samba users configuration (where 'user' is the username you're going to use). Also make sure there's no spaces in the usernames or passwords, and make sure all the passwords are correct in case.

Last edited by ixion; 01-01-2003 at 02:29 PM.
 
Old 01-03-2003, 12:43 AM   #6
nero64
LQ Newbie
 
Registered: Nov 2002
Location: My bedroom
Distribution: RH 7.1
Posts: 29

Original Poster
Rep: Reputation: 15
I have iptables and ipchains installed, they start up at boot time, but i am not using them and i have not configured them. I don't know how.

I read someone else having samba problems due to a firewall.

Is this my problem or doesn't it matter unless you have configured them to run.
 
Old 01-03-2003, 09:10 AM   #7
ixion
Member
 
Registered: Dec 2002
Location: USA
Distribution: SuSE, CentOS, Gentoo
Posts: 166

Rep: Reputation: 30
I would say it's a safe bet the firewall is interfering at least on some level. I don't know much about linux firewalls, yet, but have you checked the logs? Have they showed deny's to your Win95 box? If so, try turning off the firewall and see what happens at that point. If the firewall is the problem, then see which ports your Win95 machine is requesting, and open those up for it. I don't know how deep the linux firewalls go, but I'm sure you can even get down to MAC and IP specific requests making it to where ONLY the Win95 box can access your server through the open ports, resulting in higher security.

I hope this helps!
 
Old 01-03-2003, 01:49 PM   #8
DougW
LQ Newbie
 
Registered: Jan 2003
Location: Oklahoma
Distribution: Linux Mandrake 9.0
Posts: 5

Rep: Reputation: 0
Just for grins and incase it may help.
I finally got samba to accept files and file management from my XP box. This is what I did.

Created a shared drive as normal and set the permissions for Others to have read/write.

Went into samba.conf, scrolled all the way to the bottom where the shares are described.

(note: Open_share is the share name windoze will see)

[OPEN_SHARE]
path = /home/public/shares
public = yes
guest ok = yes
writable = yes
wide links = yes

Yes, it's wide open, but this is my intranet, mkay.

Last edited by DougW; 01-03-2003 at 01:51 PM.
 
Old 01-03-2003, 07:47 PM   #9
nero64
LQ Newbie
 
Registered: Nov 2002
Location: My bedroom
Distribution: RH 7.1
Posts: 29

Original Poster
Rep: Reputation: 15
yep i got it to work. I remember installing iptables a while back. So i got rid of that and i stopped the ipchains service and restarted samba.

I also got it to print something to the Linux Printer.
 
Old 01-03-2003, 08:29 PM   #10
balam
Member
 
Registered: Nov 2002
Location: us
Distribution: red hat
Posts: 143

Rep: Reputation: 15
HERE THE BEST AND WELL EXPLAIN LINK TO SET SAMBA.
i AM SURE THAT YOU WILL POST A THANKS.

http://www.mandrakeuser.org/docs/con...mba6.html#conf
 
  


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
Samba woes Imaboyo Linux - Software 13 09-21-2004 06:39 PM
Samba Woes webhead Linux - Networking 3 09-15-2004 10:40 PM
More Samba woes mmcinnis Linux - Networking 14 09-19-2003 07:56 AM
Samba WOES AnselmoMH Linux - Networking 4 06-25-2003 11:04 AM
samba woes... prodigius Linux - Software 1 01-14-2002 03:05 PM


All times are GMT -5. The time now is 01:08 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
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration