[Samba] Re: Marginal write performance & pauses in outgoing transfers

Dragan Krnic dkrnic at lycos.com
Mon Jul 28 10:07:13 GMT 2003


>Thanks a lot for your reply. Alright, it was not a 
>bug in Samba after all. You were right, I was wrong, 
>excuse me for blaming Samba and being an idiot :)  
>But please read on, because I'm still lost here.

It's all right to feel repentant but don't exaggerate.
You are OK, only a little stressed.

>As I expected, this was not an issue with my physical 
>network setup or topology. These machines are on the 
>same desk with no routers in the middle, and my hub 
>might be old and suck but, as I had said, I can 
>achieve equal incoming/outgoing transfer rates with 
>other protocols such as FTP. By the way, by "there 
>are no collissions" I meant "no more collissions than
>normal", just to remark that it wasn't a duplex or 
>network problem.

OK.

>This is what I did: I installed Windows XP in a 
>virtual machine (VMware) running inside the Windows 
>2000 box that was receiving from Samba at 100 KB/s, 
>with bridged networking. I transferred from Samba to 
>the virtual XP machine, and... consistent transfer, 
>with no pauses and very close to 10 mbps. It's still 
>the same physical computer and network card receiving 
>the traffic, but it's another OS picking it up.

Of course, XP is supposed to be an improvement upon 2k,
but that does not account fully for your problems.

>So, my network was fine and there's something wrong 
>with my Windows 2000 installation, which means I'm 
>most likely going to be stuck with one of those 
>sticky Windows-like problems.

Not necessarily. Have patience and take an unbiased
look at your configuration. It may take some time but
you can get it to work properly for sure.

>This is a log generated by tcpdump for the transfer 
>of a 6 MB file from Samba to Windows 2000. It 
>includes the initial process of me hitting Ctrl+C on 
>the selected file and pasting it in a different 
>directory on the Win2k box. Win2k took about 3 
>seconds just to copy the link to the clipboard before 
>turning the hourglass back into the normal pointer
>(I know these terms sound lame but hey, it's Windows).
>
>http://nss.sytes.net/slow.smb.tcpdump.01.log
>
>Note how there are certain whole seconds where 
>there's no traffic at all, and some others where just 
>three or four packets go through.

If necessary, use ethereal next time and store the 
fully detailed display in a print file. After 
compression it is much smaller. Your observation is
correct, there are long pauses between payloads, but
I don't see what it's waiting for.

>Browsing a directory on a Samba share from the Win2k 
>box is really sloppy too: sometimes (at random), it 
>takes Windows a couple of seconds to retrieve 
>information on a file when selecting it, such as size 
>and whatever it shows in the status bar for the 
>currently selected file. Watching the hub's activity 
>LED indicates the presence of the evil traffic pauses 
>between packets.

It's best to suppress the pop-up info in the file
browser (clear the box at
Options->Folder options->View->Popup-info) even when
you don't have problems.

>The main reason why I didn't want to send over my 
>smb.conf is that I had tried so many combinations 
>that I didn't know which to pick, but here's what I 
>had been always using:
>
>http://nss.sytes.net/smb.conf

It's a clean little smb.conf. I don't believe those
8k buffer specifications in socket options do much 
good, but they're probably irrelevant. Therefore throw
them out. On the other hand I wouldn't exclude 
"SO_KEEPALIVE" from socket options, so add it. I don't 
know what "dead time" does, but if you're sure you do, 
it's another toggle you can use in tests. I don't see 
much use for "interfaces" and "bind interfaces only". 
If you only have one NIC, you almost certainly don't 
need them.

But who's the browser master in your workgroup? If you
leave it undefined, then any of your clients will
claim it and there'll be some broadcast storms from 
time to time when they're settling the issue who shall
win the election. You should add the following options
in [global]:

   wins support = Yes
   preferred master = Yes
   domain master = True

and tell your clients to never start elections. That's
"MaintainServerList"="No" under HKLM key
SYSTEM\CurrentControlSet\Services\Browser\Parameters
in the Win2K registry.

I wish you good luck.


____________________________________________________________
Get advanced SPAM filtering on Webmail or POP Mail ... Get Lycos Mail!
http://login.mail.lycos.com/r/referral?aid=27005



More information about the samba mailing list