LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   SAMBA Win XP Conection Problem (https://www.linuxquestions.org/questions/linux-networking-3/samba-win-xp-conection-problem-471703/)

hmartires 08-07-2006 04:03 PM

SAMBA Win XP Conection Problem
 
Hello!
I'm trying to conecto my Windows XP to my Madriva 2006 Linux with samba.

I have 2 main problems that most likely are related:
1) Unable to conect from Windows to Linux
2) Unable to mount windows shares in Linux

When I browse My Network Places, I can't get the Linux machine.
When I use ms-dos "net view" I don't see the Linux Samba server.
I turned off my Sygate firewall already in XP and I haven't configure any in Linux, as far as I know.

I can ping both machines even with the host name intead of the IP address.
I have assigned to the WINS address, the IP of the Linux samba server, in the TCP/IP Advanced Properties in Win XP.

I have followed each and every step of the Howto that I found in this forum:
http://www.linuxforums.org/forum/lin...ups-howto.html

I have gone through a lot of reading trying to solve this issue, but so far, nothing. I can't conect Windows to Linux.
Please help me a little here, because I don't think this will be a big issue. I have the feeling that something is missing.

Follow are my config:
Linux gbox 2.6.12-12mdk #1 Fri Sep 9 18:15:22 CEST 2005 i686 Intel(R) Pentium(R) 4 Mobile CPU 1.60GHz unknown GNU/Linux

I have already installed and configured samba.
My smb.conf is like this:
#====== Global Settings ===
[global]

workgroup = casa
netbios name = gbox
server string = Samba Server %v
security = user
encrypt passwords = yes
smb passwd file = /etc/samba/smbpasswd
username map = /etc/samba/smbusers

log file = /var/log/samba/%m.log
socket options = TCP_NODELAY SO_SNDBUF=8192 SO_RCVBUF=8192

wins support = yes
hostname lookups = yes
hosts equiv = /etc/hosts
hosts allow = 192.168.0.1 127.0.0.1 localhost
hosts deny = All
interfaces = lo eth0
bind interfaces only = yes
guest ok = no
browse list = yes
printcap name = cups
printing = cups
load printers = yes

domain master = no
local master = no
preferred master = no
os level = 0

#==== Share Definitions ====
[public]
path = /home/samba/public
comment = Shared folders
guest ok = no
create mode = 0766
browseable = yes
public = yes
read only = no

[homes]
path = /home/%U
comment = Home Directories
browseable = no
read only = no
valid users = %U root

-------------------------

When I do a testperm, I get this:
Load smb config files from /etc/samba/smb.conf
Processing section "[public]"
Processing section "[homes]"
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions


In Linux I can conect to the local samba server with smbclient and see all the shares:
smbclient -L //localhost/public
Domain=[GBOX] OS=[Unix] Server=[Samba 3.0.20]

Sharename Type Comment
--------- --- -------
public Disk Shared folders
IPC$ IPC IPC Service (Samba Server 3.0.20)
ADMIN$ IPC IPC Service (Samba Server 3.0.20)
root Disk Home Directories

Domain=[GBOX] OS=[Unix] Server=[Samba 3.0.20]

Server Comment
--------- -------

Workgroup Master
--------- -------
CASA

It seems the server is running well and the smbd and nmbd deamons are ok.

Please, any help would be apreciated.
Thanks

cdhgee 08-09-2006 01:43 AM

Although you may not have configured any firewall in Linux, it is quite often enabled by default - it was in my Fedora installation, at any rate. Check to see whether the iptables daemon is running and stop it if necessary so you can check whether that's the problem.

jxrod2000 08-09-2006 07:00 AM

Make sure that the "microsoft client network" (I believe that's the name) is enabled for you network connection. I spent a few hours on the same problem, and this is why I couldn't connect. As a matter of fact the XP box wouldn't even boot when samba was running and the above wasn't enabled.
Just one more thing to check.

cdhgee 08-09-2006 07:26 AM

The "Client for Microsoft Networks" which I believe jxrod2000 is referring to is enabled as part of a Windows XP standard installation so you would have to explicitly disable it for it not to work. In any case, I think you wouldn't even see the network places if it wasn't enabled.

As for your XP box not booting, that's neither here nor there as that's nothing to do with Samba.

hmartires 08-09-2006 05:28 PM

More testing :(
 
Thanks in advance for the reply!

I'm not using any firewall at all. I turned off my Windows Sygate FW and iptables is not running.
"Client for Microsoft Networks" is already enable as well.

I have tryed some more stuff.
Typing name in explorer address window but nothing.
Even "net view" is DOS only show me the Windows machine.

ipconfig output
---------------
Windows IP Configuration

Ethernet adapter Home:
Connection-specific DNS Suffix . :
IP Address. . . . . . . . . . . . : 192.168.0.1
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Default Gateway . . . . . . . . . :

Ethernet adapter TV Cabo:
Connection-specific DNS Suffix . : ######## (Internet provider)
IP Address. . . . . . . . . . . . : 85.139.235.42
Subnet Mask . . . . . . . . . . . : 255.255.254.0
Default Gateway . . . . . . . . . : 85.139.235.254


ifconfig output
----------------
eth0 Link encap:Ethernet HWaddr 00:08:02:6B:C2:E7
inet addr:192.168.0.2 Bcast:192.168.0.255 Mask:255.255.255.0
inet6 addr: fe80::208:2ff:fe6b:c2e7/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:46 errors:0 dropped:0 overruns:0 frame:0
TX packets:855 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:5588 (5.4 KiB) TX bytes:42082 (41.0 KiB)

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:338 errors:0 dropped:0 overruns:0 frame:0
TX packets:338 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:20348 (19.8 KiB) TX bytes:20348 (19.8 KiB)


Just to ble clear, the network is working fine, I can ping both computers and I can share the Internet conection from Windows to Linux (ie. My Internet conection it's on the Windows machine).
I don't use any domain. I just use a workgroup which works well if I conect both the laptop and the desktop in Windows XP.
Now I just want to share some folders in the Linux laptop to the Windows desktop. I did this once and it worked well, asking the samba passwords and all of that. Now it just doesn't work...

Everything is fine with the SMB users and all the passwords are sett. I can conect localy to the samba shares (ie. from linux) withou any problems.

michaelk 08-09-2006 06:22 PM

Have you checked the smbd & nmbd logs for errors?

I quick review found a few problems with your smb.conf file.
Change:
os level = 0
to
os level = 64

Quote:

hosts allow = 192.168.0.1 127.0.0.1 localhost
This line only allows connections from the linux samba server itself
Use instead:
hosts allow = 127.0.0.1 192.168.0.0/24

Quote:

hosts deny = All
And this will also deny everything except the samba server itself.
You can delete this line.

Be sure to restart samba.

tuannie 08-09-2006 07:14 PM

I have had a look at your smb.conf file, you seem not to have security = share under [global].

Try and add in security = share

tell me if that fixes your problem

scott2004 08-09-2006 10:47 PM

Security = share is rather uncommon and old. The typical setting which most people will want is "security = user"

I still suspect a firewall is running on the Linux machine. Iptables only runs when creating kernel routing rules, I believe, so it would not show up except when creating the firewall rule set.

(What distro are you using?)

I would navigate to the setup GUI for your distro and verify that the firewall is disabled. All modern distros will enable it by default and most do not by default enable the samba ports. Visually verify this -- it is too likely to leave to chance.

Connecting via a smbclient on the samba server is no test of the firewall because this connection happens inside the machine's own firewall and uses the loopback interface.

pddm 08-09-2006 11:32 PM

Turn off SELinux

And read your logs!

scott2004 08-10-2006 08:56 AM

Ok... I see from your original post you're using Mandriva.

Mandriva does not use SeLinux. However, it does use a firewall package called shorewall. Shorewall is turned on by default and is almost certainly causing your problems.

You can see if shorewall is running, which it probably is, by typing:

/etc/rc.d/init.d/shorewall status

Assuming it is, go to the Mandriva control centre, then go to the security section and open the firewall dialogue. Check that you have enabled samba.IT IS NOT ENABLED BY DEFAULT.


All times are GMT -5. The time now is 02:53 AM.