Re: [Samba] Samba 3.5.8 - windows XP workstations disapear from browselist

2011-05-07 Thread Chris Smith
On Sat, May 7, 2011 at 3:38 PM, BartekR  wrote:
> socket options = TCP_NODELAY SO_SNDBUF=16384 SO_RCVBUF=16384
> security = share
> os level = 255
> domain master = no
> preferred master = yes

Try changing the above parameters.

Eliminate, or comment out:
===
# socket options = TCP_NODELAY SO_SNDBUF=16384 SO_RCVBUF=16384
===

Change the rest to either:
===
security = user
os level = 32
domain master = no
# preferred master = yes
===
or preferably this:
===
security = user
os level = 32
domain master = yes
preferred master = yes
===

You can still have guest shares with security = user, see:
http://blog.realcomputerguy.com/2010/12/samba-and-guest-shares-with-security.html

The smb.conf man page states that preferred master is best used with
domain master. It doesn't hurt to have a domain controller even you
don't join any systems to it.
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


[Samba] Samba 3.5.8 - windows XP workstations disapear from browselist

2011-05-07 Thread BartekR

Hello!

I have small network in my work. Workstations that connects to it runs 
various kind of OS. This includes:


1x Windows 95 (Brother Printer)
8x Windows XP <=problematic!
2x Windows Visa
2x Windows 7
1x Samba 3.5.8 (WINS,DNS, supose to be LMB)

There is a serious problem with a browselist. Ever single windows XP 
workstations disapear from browselist after an about 24 - 28 minutes 
after workstation powerup or smbd restart. After this they are still 
accesable by hostname, netbiosname, and ip. Other workstations are 
visible as they should be and don't disapear.


First i thought it is an name resolution problem but i run correctly 
configured dns server. This server answers for both types of querry: 
straight (domain->ip) and reverse (address->ip).It is well tested. Also 
i've made /etc/hosts and /etc/samba/lmhosts files. They contains same 
ip=domain setup as named.


Next thing was an firewall on my server (smbd and nmbd runs on it) but i 
found that it does not matter. Even turning off tcp_syncookies and 
rp_filter. Without success.


I have found an article suggesting that windows xp firewall is to blame. 
I dont think it is a true, because workstations runs diffrent types of 
firewall. One of them use windows firewall but others use another 
firewalling sollution. Both of theese disapear from browselist in the 
same way. Complete disabling of XP workstation firewall does not solve 
problem.


Every switch in my network was tested. I have excluded damaged one from 
topology. It was an device connecting 2 XP workstations (+uplink) on a 
edge of network. Still, no success with improving browselist stability.


Also i have tried diffrent configurations of samba. No succes. Now i run 
following configuration:



#=
[global]

#tested
max protocol = NT1
syslog = 0
unix charset = UTF-8
dos charset = CP852
time server = yes
#tested
#smb ports = 139
name resolve order = wins bcast hosts lmhosts
#tested
#interfaces = eth0 192.168.7.1 lo 127.0.0.1
#tested
#bind interfaces only = Yes
#tested
hosts allow = 192.168.7.0/24 127.0.0.1
#tested
enhanced browsing = no
keepalive = 30
loglevel = all:10
show add printer wizard = no
socket options = TCP_NODELAY SO_SNDBUF=16384 SO_RCVBUF=16384

workgroup = ENELPC
server string = Serwer
netbios name = belphegor
security = share
load printers = no
printcap name = /etc/printcap
printing = cups
guest account = nobody
log file = /var/log/samba/samba.%m
max log size = 1
#tested
local master = yes
#tested
os level = 255
#tested
domain master = no
#tested
preferred master = yes
domain logons = no
#tested
wins support = yes
wins proxy = no
#tested
dns proxy = no
passdb backend = tdbsam

#shares below
#[...]

#=

Lines followed by "#tested" were changed to find sollution but with no 
success.





There is log piece covering period of time while BARTEKR disappears:

#=

[2011/05/06 20:04:03.848346,  4] 
nmbd/nmbd_workgroupdb.c:170(find_workgroup_on_subnet)
  find_workgroup_on_subnet: workgroup search for ENELPC on subnet 
192.168.7.1: found.
[2011/05/06 20:04:03.848486, 10] 
nmbd/nmbd_sendannounce.c:381(announce_myself_to_domain_master_browser)
  announce_myself_to_domain_master_browser: t (1304705033) - 
last(1304704509) < 900
[2011/05/06 20:04:13.851328,  4] 
nmbd/nmbd_workgroupdb.c:170(find_workgroup_on_subnet)
  find_workgroup_on_subnet: workgroup search for ENELPC on subnet 
192.168.7.1: found.
[2011/05/06 20:04:13.851467, 10] 
nmbd/nmbd_sendannounce.c:381(announce_myself_to_domain_master_browser)
  announce_myself_to_domain_master_browser: t (1304705043) - 
last(1304704509) < 900
[2011/05/06 20:04:13.851514,  4] 
nmbd/nmbd_workgroupdb.c:281(dump_workgroups)

  dump_workgroups()
   dump workgroup on subnet 192.168.7.1: netmask=  255.255.255.0:
  <>ENELPC(1) current master browser = ENELPC
  <><-->ENELPC 408c9a23 (Serwer)
  <><-->BARTEKR 40011003 (Laptop)
  <><-->DRUK-KOLOR 40002003 ()
[2011/05/06 20:04:13.851589,  4] 
nmbd/nmbd_workgroupdb.c:281(dump_workgroups)

  dump_workgroups()
   dump workgroup on subnet  UNICAST_SUBNET: netmask=  127.0.0.1:
  <>ENELPC(1) current master browser = UNKNOWN
  <><-->ENELPC 40899a23 (Serwer)
[2011/05/06 20:04:13.851669, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851706, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851740, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851774, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851807, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851841, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wbddd, 35) -> 31
[2011/05/06 20:04:13.851874, 18] lib/util_tdb.c:358(tdb_unpack)
  tdb_unpack(wb