LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 02-17-2003, 12:36 PM   #31
bjshaw
LQ Newbie
 
Registered: Dec 2002
Location: Portland, OR
Distribution: RedHat Linux 8.0 server
Posts: 16

Original Poster
Rep: Reputation: 0

Nope, I tried that last suggestion of matching my Windows logins with my Samba usernames/passwords, but still the same problems.
 
Old 02-17-2003, 01:22 PM   #32
Pcghost
Senior Member
 
Registered: Feb 2003
Location: The Arctic
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820

Rep: Reputation: 46
To disable Iptables type

/etc/init.d/iptables stop

To prevent Iptables from starting at boot type

chkconfig --level 2345 iptables off
 
Old 02-17-2003, 01:40 PM   #33
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
More information

This is kind of crazy, bjshaw, I have already tried everything except the firewall stuff Pcghost has mentioned...

I think we are suffering the same fate... let me re-post my own problem and maybe we can both come up with some more questions!!! HA!

I am running Redhat 8, and the stock Samba version that comes along with it. Windows 98/ME sit on the other side of the 10/100 ethernet LAN. I have a SMC Barricade Router Switch that lets everything through...

I can ping my Redhat PC from Windows, and the otherway around. I have the Redhat PC named as Linux, and the Windows pc named as Windows. I can access Apache locally on Linux, and through the Lan from Windows. I can smbmount my //windows/mydocuments folder from Linux... but...

And here's the issue...

I click on Network Neighborhood in Windows... and my Linux computer does not show up... well, sometimes it does, and I heard this is an issue with Windows... however...

Even when it does, and I double click on it... it will not come up! Even if I type in "\\linux" in the explorer bar, it will not access the shares that I have available on Linux.

I had Mandrake 9 on my old machine and it did the samba shares quite well, but with Redhat 8... it is just a bear, I have been working on this for weeks... I even bought the "Using Samba" by O'Reilly Associates... to no avail.

Well, I hope this forum helps us out...

Does this sound like your problem too?

-Karl

Last edited by karl_herrick; 02-17-2003 at 01:43 PM.
 
Old 02-17-2003, 01:41 PM   #34
oneiltj
LQ Newbie
 
Registered: Jan 2003
Location: NE, Ohio
Posts: 19

Rep: Reputation: 0
Netbios name resolution and host names are two different creatures. This is a very common place of confusion. Let me attempt to explain:

Host names are resolved within /etc/hosts or DNS. As you resolve http://foo.bar.com or ftp://foo.bad.bar.com this happen either DNS or hosts depending how your network is configured. to resolve a name hosts is checked first and then any DNS setting you have. It's your common Internet, database instance resolve..

Netbios resolves it's names via WINS or LMHosts. Host names in DNS or hosts will not resolve MS Shares. It's apples and oranges.

Samba is of course using Netbios bound to TCP.

NOW - I assume your planning to use this machine as a mail server and a web server. I'm also assuming your adding Samba for local traffic. With this you give this machine a Samba name of ... well just about anything. Your web server hosts name, locale what ever would likely equal you FQDN.

Enough yammering from me.

-t
 
Old 02-17-2003, 01:46 PM   #35
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
Wins or lmhosts...

in reply to oneiltj --------

On my machine, I have samba running as a WINS server, AND, I have the lmhosts file listing both my windows pc, and my linux pc. Samba is also configured to search DNS, Wins, lmhosts, and the hosts file for name resolution. The O'Reilly Book covers this... :-) I seem to be missing something however...

For testing purposes, I can ping "Linux" from the winPC, and it reads an ip address of 192.168.2.2 and pings back fine. I can ping the winPC from the linuxPC by pinging "Windows", and it reads an ip address of 192.168.2.3 and pings back fine.

So I am pinging their names, and it works... I'm not sure if this is a realiable test for Samba... but samba is still not working...

Last edited by karl_herrick; 02-17-2003 at 01:52 PM.
 
Old 02-17-2003, 03:28 PM   #36
oneiltj
LQ Newbie
 
Registered: Jan 2003
Location: NE, Ohio
Posts: 19

Rep: Reputation: 0
Ping doesn't resolve netbios. nbtstat -? resolves netbios.

Karl - I'm a little short on time at this moment, have to run out the door. I'm not giving this the attention it deserves. I'll get back to you tonight, or tomorrow afternoon.

Remember though netbios uses TCP/IP it does not resolve name issues thru ping, dns or hosts :-)

catch ya in a couple hours.

-t
 
Old 02-17-2003, 08:02 PM   #37
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
that's weird

I tried the "nbtstat -a linux" from a command prompt on my Windows computer, and it couldn't find it... though it did find the "nbtstat -a windows"

In other news of my trying out stuff, I set the windows computer to "user level access" from the network in control panel... it first gave me some password stuff about a windows nt domain, or windows nt server... I chose server... but it hasn't made a difference.

I have the smb.conf file with the following
netbios name = Linux

Why would the windows computer not be finding the linux netbios name?

Last edited by karl_herrick; 02-17-2003 at 09:01 PM.
 
Old 02-17-2003, 08:56 PM   #38
oneiltj
LQ Newbie
 
Registered: Jan 2003
Location: NE, Ohio
Posts: 19

Rep: Reputation: 0
From your windoze machine do a nbtstat -a a.b.c.d ( what ever the IP address of the linux box is.) It should ( if netbios is working correctly ) return name and workgroup of the Samba server. If nmdb and smbd are up on the linux machine -AND- you have the proper ports for netbios entered in /etc/services you should be on your way.
And your correct nbtstat does not work well in linux. try netstat -a. You will be looking for netbios-ssn, dgm, ns to be present as listening.

If these are all present and you still have issues it's likley something with nb browsing and elections. things get hainy from here. There are many warning about this.

another thing to maybe try, kill WINS, rename lmhosts, bring your linux machine to run level 1 and back up to what ever run level you normaly have. This will reload network and Samba and force a little netbios election for master browser.

With wins and lmhosts disabled nbtstat -a to the linux machine from the windows machine. you should have some responce. If you now resolve the netbios name it may have something to do with wins or lmshost.
if not look at your smb.conf and look at you os level. I've seen some doc out there regarding issues with browser elections and os level.

Normaly you won't need both lmhosts and wins. If all machines are on the same subnet they are needed at all since it's all broadcast based communication.
 
Old 02-17-2003, 09:14 PM   #39
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
nbtstat -a

I tried the nbtstat -a 192.168.2.2, and it said host not found.... I checked my /etc/services file and it had these lines...

netbios-ns 137/tcp # NETBIOS Name Service
netbios-ns 137/udp
netbios-dgm 138/tcp # NETBIOS Datagram Service
netbios-dgm 138/udp
netbios-ssn 139/tcp # NETBIOS session service
netbios-ssn 139/udp

Is this correct? Next I will try the stuff with WINS, and lmhosts... by the way, the lmhosts file should be in all lowercase right? I have seen it both someplaces and am wondering which is right...

Thanks for your help so far... -Karl
 
Old 02-17-2003, 09:14 PM   #40
jamrock
Member
 
Registered: Jan 2003
Location: Kingston, Jamaica
Posts: 444

Rep: Reputation: 41
Here is a simple smb.conf file. Stop samba, backup the one you have, copy this one and restart Samba. If it works, start adding additional stuff until it stops working. Fix the problem and continue.

Make sure the /home/myshare directory exists before you start samba. Please don't use a Windows text editor to copy this into Linux. Windows adds stuff that Linux doesn't like.


I found a few inconsistencies on your original smb.conf file. We can deal with those later. Let me know if this works.






[global]


workgroup = bandrshaw
netbios name = linux1

hosts allow = 192.168.123. 127.

log file = /var/log/samba/%m.log

max log size=0

security = user

encrypt passwords = yes
smbpasswd = /etc/samba/smbpasswd


[homes]

comment = Homes directory
browseable = no
writable = yes

[myshare]

path = /home/myshare
public = no
writable=yes
printable=no
create mask = 0765
 
Old 02-17-2003, 09:19 PM   #41
jamrock
Member
 
Registered: Jan 2003
Location: Kingston, Jamaica
Posts: 444

Rep: Reputation: 41
Note that I have added the loopback address (127.) to your hosts allow command.

I assume that the Windows machine has an i.p. address starting with 192.168.123.


To make it a little more standard, use 192.168.1.

This may not even be an issue but I want to go back to basics. You will need to change the i.p. address of the Linux machine if you choose to go this route.
 
Old 02-17-2003, 09:22 PM   #42
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
my smb.conf

Here is what the new one looks like... and still no response from the linux machine on linux... And it still cannot see the netbios name using

nbtstat -a 192.168.2.2, or
nbtstat -a linux

but can see the windows machine using
nbtstat -a 192.168.2.3, or
nbtstat -a windows

smb.conf:

[global]

workgroup = HOMESHARE
netbios name = Linux
hosts allow = 192.168.2. 127.
log file = /var/log/samba/%m.log
max log size=0
security = user
encrypt passwords = yes
smbpasswd = /etc/samba/smbpasswd

[homes]
comment = Homes directory
browseable = no
writable = yes

[myshare]
path = /home/myshare
public = no
writable=yes
printable=no
create mask = 0765
 
Old 02-17-2003, 09:25 PM   #43
karl_herrick
LQ Newbie
 
Registered: Feb 2003
Location: Mason, MI
Distribution: Mdk 9.2, Fedora, Knoppix
Posts: 25

Rep: Reputation: 15
here's my lmhosts file

located in /etc/samba/

here's my lmhosts file

127.0.0.1 localhost
192.168.2.2 linux
192.168.2.3 windows
 
Old 02-18-2003, 05:22 AM   #44
jamrock
Member
 
Registered: Jan 2003
Location: Kingston, Jamaica
Posts: 444

Rep: Reputation: 41
karl_herrick,

Let me understand some things.

On which machine do you have a lmhosts file and where is it located?

Is the workgroup name the same in Windows and in the smb.conf file?

Is the netBEUI protocol loaded on your Windows machine?

Do you see the Linux machine in network neighborhood from the Windows machine?

If it appears what message do you get when you try to access the share?

Do you see the same user name in the /etc/passwd and /etc/samba/smbpasswd files as the one you log in on the Wndows machine?
 
Old 02-18-2003, 07:29 AM   #45
oneiltj
LQ Newbie
 
Registered: Jan 2003
Location: NE, Ohio
Posts: 19

Rep: Reputation: 0
I noticed a couple things in your config you may want to look at...

workgroup = HOMESHARE - Maybe all lower case here. I saw something simular to this in another thread.

netbios name = Linux - Same thing here. try lower case.

hosts allow = 192.168.2. 127. - Now this may be a problem. make sure you have no spaces in the address and drop the trailing dot.

Now someone correct me if I'm wrong here... If you would like all machines on your local subnet maybe drop the 127 at the end.
Also the machine you are attempting to allow is at x.x.x.3 correct? If my previous statement is incorrect regarding masking attempt changing 127 to 3.

-t
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
samba config issues: debian and xp spargonaut Linux - Software 36 03-31-2005 08:25 PM
redhat-config-samba does not start hobz Linux - Networking 9 01-17-2005 06:53 AM
can't open redhat-samba-config need help nvoke Linux - Networking 7 11-14-2004 05:09 PM
redhat-config-securitylevel and SAMBA chromedog Programming 0 05-02-2004 04:48 PM
redhat-config-samba cezarn Linux - Newbie 10 09-16-2003 09:06 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

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