Stuart Nixon
2007-Sep-26 08:41 UTC
[Samba] Very slow execution of programs from a SAMBA share
Hi. I've run into a significant performance problem, where Samba shares are fine except for programs executed from the shares, which take about 100x longer to launch than expected. Copying local Windows directories with large files to the Samba share is getting 30 Mbytes/second. However, trying to run programs from the same samba share is taking 30 seconds to 5 minutes to launch the application (compared to sub-second launch time from shares from Windows XP 64 Pro systems for the same programs). I'm trying to set up Samba 3.0.24 under Ubuntu 7.04 as WINS master workgroup (not domain) server, to share to a dozen systems running Windows XP Pro 64 SP2. Network switch is a Netgear 16 port Gigabit switch. The ADSL modem is acting as DCHP / DNS server for the network. For now firewalls are disabled on the Ubuntu server. Disabling firewalls on the XP Pro 64 clients is making no difference. I've tried many different things, and nothing seems to make any difference. I'm wondering if there is a SAMBA / XP 64 bit client problem, or if the problem is somehow related to the switch, because NBTSTAT is reporting a "MAC Address = 00-00-00-00-00-00" for the Samba server. I can't see any obvious problems. I can browse the samba server. The shares are visible and having no access problems. Other applications have no problem with UDP broadcasts working across the switch. The show-stopper problem is that application load time is horrible if an application is run from the Samba share (around 100x slower than it should be). The clients are standard XP Pro 64 with latest SP2 patches. They have no problem running applications from another XP Pro share. Any help or hints would be greatly appreciated. Output from nbtstat looks fine except for the MAC address: --------------------------- C:\>nbtstat -a snsix Local Area Connection 3: Node IpAddress: [10.1.1.7] Scope Id: [] NetBIOS Remote Machine Name Table Name Type Status --------------------------------------------- SNSIX <00> UNIQUE Registered SNSIX <03> UNIQUE Registered SNSIX <20> UNIQUE Registered ..__MSBROWSE__.<01> GROUP Registered SNS <1D> UNIQUE Registered SNS <1B> UNIQUE Registered SNS <1E> GROUP Registered SNS <00> GROUP Registered MAC Address = 00-00-00-00-00-00 ----------------------------- The smb.conf file is pretty standard, unless I've missed something obvious: ---------- smb.conf --------------- # # Samba for Linux # [global] workgroup = SNS netbios name = SNSIX server string = %h wins support = yes name resolve order = wins lmhosts hosts bcast domain master = yes local master = yes preferred master = yes os level = 35 dns proxy = no security = user encrypt passwords = true hosts allow = 10.1.1.0/255.255.255.0 127.0.0.1 EXCEPT 10.1.1.1 hosts deny = ALL socket options = TCP_NODELAY IPTOS_LOWDELAY # Logs log file = /var/log/samba/log.%m max log size = 1000 syslog = 0 panic action = /usr/share/samba/panic-action %d # shares [data] path = /mnt/data writable = yes user = sns -------------------------------------- Thanks in advance for any suggestions on how to resolve this problem. I want to move our servers over to Samba/Linux, but can't until this problem is resolved. Stuart
Stuart Nixon
2007-Sep-27 05:04 UTC
[Samba] Very slow execution of programs from a SAMBA share
> You could try setting some of the oplock options. I think "fake oplocks = yes" on the > application share could significantly increase the performance when executing.?der, Thanks for your response. The slow share problem turned out to be a Samba/Ubuntu 7.04 problem with some NICs - symptoms are slow access *unless* several clients are accessing the same share at the same time (or xfer of large files). Once you know what to search for, it turns out to be a very common issue for many people. Weird, and took a long time to resolve. I swapped NICs in the end. I then ran into another problem where Samba refused to be come master domain server because it thought there was already another, but non-existant server (which turned out to be Samba, from when the server was using a different IP address). Again much searching, to find that deleting /var/libs/samba/wins.dat and restarting Samba fixed that problem. Bottom line is that moving Samba to a new IP causes issues that can only be resolved by deleting wins.dat. I'm now trying to work out why Samba shares die whenever clients running DHCP get their IP lease renewed. Another show-stopper problem. If I don't solve it today I'll go back to Windows Server 2003. Which is a shame, but I can't afford to spend much more time on this. Samba looks great, and I appreciate the amount of time it must have taken to decode the CIFS protocols. But what is a bit worrying is that getting Samba to run in a pretty standard environment is turning out to be a huge nightmare, which would not encourage users to switch from Windows servers to Samba. The frustrating thing is that many of these problems look to be common issues that are likely to be common on small Windows networks wanting to use Samba. Regards, Stuart