[prev in list] [next in list] [prev in thread] [next in thread] 

List:       samba
Subject:    SAMBA digest 459
From:       samba () anu ! edu ! au
Date:       1995-04-19 13:04:10
[Download RAW message or body]

			    SAMBA Digest 459

Topics covered in this issue include:

  1) Re: Process per connection vs kernel mode driver
	by terry@cs.weber.edu (Terry Lambert)
  2) Re: Process per connection vs kernel mode driver
	by elf@netcom.com (Marc Singer)
  3) Re: Borwsing Problem
	by "Andrew.Tridgell" <tridge@arvidsjaur.anu.edu.au>
  4) Problem solved: 'When is "rm -f" not "rm -f" ? (nt and Mks)'
	by Daavid Turnbull <daavid@tusc.com.au>
  5) international chars (samba 1.9.12)
	by "Andrew.Tridgell" <tridge@arvidsjaur.anu.edu.au>

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

Date: Tue, 11 Apr 95 12:46:18 MDT
From: terry@cs.weber.edu (Terry Lambert)
To: samba@anu.edu.au
Cc: samba@anugpo.anu.edu.au
Subject: Re: Process per connection vs kernel mode driver
Message-ID: <9504111846.AA00926@cs.weber.edu>

Jurgen Botz <jbotz@orixa.mtholyoke.edu> writes:
> 
> Our local file system expert has been dubious about Samba, since it's a
> user-mode file server and his experience with user-mode file servers has
> been bad.  I guess the question I'm left with is:  If a user-mode file
> server can work so well, why are no commercial NFS file servers implemented
> this way?

It is expensive to cross memory protection domains.  Doing domain
crossing is *very* expensive on 386 hardware, which does not have
hardware protection for target addresses for a copyin.

Basically this means that to keep people from screwing with your
machine, you have to unmap the pages and check to see if the resulting
fault was really from an unmapped page or was from an unmapped page
that is really mapped but being protected (write faulted).

Another result of crossing a protection domain is buffer copies;
you can get around these for file reads by mmap'ing the file (one
of the optimizations that has been suggested for SAMBA for exectuable
file download to a client, since by touching a page you could then
implement read-ahead), but writing to the network still involves
copying from the user buffer to the network packet buffer.

Typically, a commercial NFS server will be entirely implemented in the
same protection domain as the kernel drivers for the ethernet, etc.,
and uses the same buffers in its file system and networking code.  The
only copies are packet fragmentation and header assembly/disassembly
from the buffer cache to/from the driver (usually on the card) memory
and to/from the dosk controller to the buffer cache.

A seriously optimized serve can save 7 copies and 4 protection domain
crossing for a single read.


Another consideration in a user space implementation is host
synchronization.

You can think of a file server as a consumer of the file system on the
machine it is running on; at the same time, the users that run any
processes on the machine also consume the file system.

If the server implements *anything* above and beyond the capabilities
of the UNIX process (ie: has *any* glue code), then there is the
possibility that a process on the system can make the information stale
between the time one client operation occurs and the next occurs.

Commercial implementations typically avoid this by being "dedicated"
servers: not allowing local processes other than the server process.


					Terry Lambert
					terry@cs.weber.edu
---
Any opinions in this posting are my own and not those of my present
or previous employers.

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

Date: Tue, 11 Apr 1995 15:33:51 -0700 (PDT)
From: elf@netcom.com (Marc Singer)
To: jbotz@orixa.mtholyoke.edu (Jurgen Botz)
Cc: samba@anugpo.anu.edu.au (Samba)
Subject: Re: Process per connection vs kernel mode driver
Message-ID: <199504112233.PAA02904@netcom2.netcom.com>

> *shrug*... I doubt that there'll be many situations where NT offers are
> considerable advantage over Unix/Samba.  And think about this... in a 
> recent thread we discovered that a few parameter tweaks can make a 100%
> difference in performance of Samba... I doubt that you'll be able to
> tune NT to anywhere nearly that degree or even have access to the
> necessary information to know what to tune.

I have been following this performance stuff for a while and I have
found my best tuning to reach only 75% of Windows/NT.  Granted there
are lots of unmentioned parameters regarding disk controllers, network
adapters, etc.  My observation is that while I can get about 300KB/s
read throughput from Linux/Samba to WfWg and 400KB/s read throughput
from NT to WfWg, the real problem has to do with reading large numbers
of files.  We routinely read all of the files in a large directory
tree and the relative performance of Samba/Linux is less than half of
Windows NT.  Though I would rather use Linux/Samba, my group still has
reasons for keeping the Windows server around.  

Perhaps when version 2.0 of Samba releases, we'll have enough protocol
functionality to get the higher throughput?

-- 
Marc Singer      |                              The desert has little water.
elf@netcom.com   |                                The city has little time.

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

Date: Wed, 12 Apr 1995 10:04:40 +1000
From: "Andrew.Tridgell" <tridge@arvidsjaur.anu.edu.au>
To: bh@ddi.digital.net
Subject: Re: Borwsing Problem
Message-ID: <199504120004.KAA15721@arvidsjaur.anu.edu.au>

   But, when I go to the windows for workgroups machine that is part of the 
   TEISD domain, but ON A DIFFERENT SUBNET, when I go to browse, all I see 
   is the Nt machine and itself.  The samba machine is not listed.  If I 

Ok, the problem is that by default nmbd advertises itself as
browseable only to the local network.

You can make it advertise itself to any other network by configuring a
lmhosts file. You then either use -H on the command line or the
lmhosts filename in the Makefile.

So, lets imagine your samba box is 192.0.2.37 and your subnet mask is
255.255.255.0. This means nmbd will by default advertise itself on the
network 192.0.2.255.

If you want it to also be browseable by hosts with IP addresses
192.0.3.* then you would have this in your lmhosts file (asuming the
TEISD workgroup name)

192.0.2.255 TEISD G
192.0.3.255 TEISD G

If you happen to know who the master browser is on the 192.0.3.255
network and you know it's permanent (most master browsers are
dynamically chosen) then you could instead put it's IP address in the
lmhosts file instead of the broadcast address. 

Andrew


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

Date: Wed, 12 Apr 1995 12:36:04 +1000 (EST)
From: Daavid Turnbull <daavid@tusc.com.au>
To: Andrew.Tridgell@anu.edu.au
Cc: samba@anu.edu.au
Subject: Problem solved: 'When is "rm -f" not "rm -f" ? (nt and Mks)'
Message-ID: <199504120236.AA12600@ephor.tusc.com.au>

> 
[...]
> The problem is that the error level set by the "rm" command, even when
> used with the "-f" option is not 0 if the file does not exist when the
> file in question is located on a samba partition.  The obvious
> conclusion is a problem in MKS's "rm" but that does not explain why it
> only occurs when samba is involved.
> 
> Example: Note the only mod to the default PROFILE.KSH that comes with
> MKS is the addition of the PS1 environment variable to put the current
> directory in the prompt.  The motd has been changed to include the
> release of the MKS toolkit. Drive c: is a FAT partition, Drive d: a
> ntfs partition and drive w: a samba partition on a HP-UX host.
> 
> C:\>sh -L
> MKS Korn shell release 4.3
> C:/ > ls /tmp/foo/bar
> ls: File or directory "/tmp/foo/bar" is not found
> C:/ > rm -f /tmp/foo/bar || echo failed
> C:/ > cd d:
> D:/ > ls /tmp/foo/bar
> ls: File or directory "/tmp/foo/bar" is not found
> D:/ > rm -f /tmp/foo/bar || echo failed
> D:/ > cd w:
> w:/ > ls /tmp/foo/bar
> ls: File or directory "/tmp/foo/bar" is not found
> w:/ > rm -f /tmp/foo/bar || echo failed
> rm: cannot unlink entry "/tmp/foo/bar": Access is denied.
> failed
> w:/ >
> 
[...]
> 
> Can anyone shed any light on this issue?
> 
Problem solved.  Andrew picked up the ball and ran with it and an
alpha release of samba (ver 1.9.12) is now available.  We have been
using the alpha for a few hours and it seems stable.

Andrew has indicated that the fix was a one liner, the problem easily
detected having supplied Andrew with a level 10 dump.

Thank-you Andrew for samba and your proficient support of this
product.  In practice samba is a better supported product than any of
the commercial products.

regards __daavid 


-- 
Daavid Turnbull		TUSC Computer Systems Pty Ltd	daavid@tusc.com.au
	666 Doncaster Road, Doncaster, Victoria, Australia, 3108.
	Phone (+61 3) 840 2222		Fax (+61 3) 840 2277

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

Date: Wed, 12 Apr 1995 14:00:44 +1000
From: "Andrew.Tridgell" <tridge@arvidsjaur.anu.edu.au>
To: samba@anugpo.anu.edu.au
Subject: international chars (samba 1.9.12)
Message-ID: <199504120400.OAA16533@arvidsjaur.anu.edu.au>

I've just added a new global option in smb.conf that people in europe
may find useful. You can specify somehting like:

        valid chars = 0345 0366 0344 0305 0326 0304

this will allow the swedish chars to be used in filenames without
mangling. You could similarly do german, norwegian etc.

This patch, along with some other minor fixes (for NT mostly) is in
1.9.12.

Andrew

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

End of SAMBA Digest 459
***********************

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic