Re: [Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-14 Thread Adam Hardy

Rune Kock on 13/10/08 20:21, wrote:

I don't think that the Samba-settings you mention matter much for
whether your network works.

Windows networking is rather arcane magic, sometimes it works and
sometimes it doesn't.

The central problem is how the workstations/servers locate each other.
 And that will be very different depending on whether you run a small,
simple lan, or a huge organisation with many network segments.

There are three mechanisms that can be used:

1) Ethernet broadcast.  This is the way that usually "just works".
However, all machines must be on the same network, and it sometimes
takes a few minutes from the machine starts until it is visible on the
net.  Be sure that all machines have unique names.

2) WINS server.  You set up one WINS server (Samba can do that), and
then let your DHCP-server tell the IP-address of the WINS-server to
the clients.  This is an old fashioned solution, but simple to set up
and it works well for small/medium size networks.  Again, be sure that
all machines have unique names.

3) DNS.  You set up a Microsoft DNS server, and have all your machines
register in that.  Non-MS DNS servers can be used, but then the
machines cannot register themselves, you'll need to configure
everything.  A basic setup will work with Samba, but you'll need MS
servers to go all the way (or perhaps Samba 4).  The way that MS
designed this, it seems that they assumed that every machine has a
public IP-address; it is very hard to grasp how this is properly
combined with NAT.  However, it is probably the only way to run a
really huge setup.

To elaborate a bit about the settings you mention:


workgroup = SAMBA_WORK_GROUP
domain master = yes


These two settings say that Samba should be the Domain Controller of a
Windows NT domain called SAMBA_WORK_GROUP.

Windows NT domains are not related to DNS in any way (though Windows
2000 domains are).  They are used 1) to allow an administrator to
centrally configure all participating machines, and 2) to allow a user
to log on to every participation machine with the same account.  The
clients must be joined to the domain to get these two advantages.

If you don't want to use the NT domain functions, you should set
domain master to no.  Workgroup must still be set -- probably you'll
want to set it to the same as the workgroup that you have set the
clients to (My Computer, Properties, Computer Name in Win XP).


local master = yes
preferred master = yes


These are related to the way that broadcast is handled, see above.
The master is a machine that collects the various broadcasted
information so that a newly booted client has a quick way to get it.
The machines on the lan vote about who should be the master; local
master allows Samba to run for master, while preferred master will
make Samba fight to get chosen.  When you run an NT domain, it is a
good idea for the domain controller to be master as well.  These
settings look OK.

... hope that I managed to confuse you as much as MS has managed to
confuse me


Yes it is more confusing, thanks... :)

Setting "domain master = no" seems to get me a big step further, so I'll keep it 
like that. I have "local master = yes" and "preferred master = yes" but I don't 
think changing them helped much so I'll leave them on "yes".


The 'fighting to be master' issue did manifest itself I think, because for a 
while I could get a connection which would then die after a minute, confusingly. 
But that was before I had configured any of the 'master' options.


Most importantly though you clarified this workgroup thang - I have now set up a 
proper workgroup, although it is funny that this Windows NT feature is so 
important to the Mac. It also seems to get the domain name wrong, thinking its 
hostname is 'sylvie@local' when DHCP should have told it to be 
'sylvie@localdomain', for instance (that's the Mac).


You're probably thinking "what the hell's he's doing?", but it does seem to be a 
bit more controlled now, rather than just randomly functional.


Best regards
Adam



Re: [Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-14 Thread richardvo...@gmail.com
>> local master = yes
>> preferred master = yes
>
> These are related to the way that broadcast is handled, see above.
> The master is a machine that collects the various broadcasted
> information so that a newly booted client has a quick way to get it.
> The machines on the lan vote about who should be the master; local
> master allows Samba to run for master, while preferred master will
> make Samba fight to get chosen.  When you run an NT domain, it is a
> good idea for the domain controller to be master as well.  These
> settings look OK.
>

And then on top of that there are B-nodes and P-nodes and hybrid nodes
and the node type can be controlled thru dhcp I think but hard to
control via client-side settings.  IIRC.

Arcane magic indeed.

I tend to always use DNS for resolution, even using FQDNs to make sure
Windows can't try to lookup the name via NetBIOS.



Re: [Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-13 Thread Rune Kock
I don't think that the Samba-settings you mention matter much for
whether your network works.

Windows networking is rather arcane magic, sometimes it works and
sometimes it doesn't.

The central problem is how the workstations/servers locate each other.
 And that will be very different depending on whether you run a small,
simple lan, or a huge organisation with many network segments.

There are three mechanisms that can be used:

1) Ethernet broadcast.  This is the way that usually "just works".
However, all machines must be on the same network, and it sometimes
takes a few minutes from the machine starts until it is visible on the
net.  Be sure that all machines have unique names.

2) WINS server.  You set up one WINS server (Samba can do that), and
then let your DHCP-server tell the IP-address of the WINS-server to
the clients.  This is an old fashioned solution, but simple to set up
and it works well for small/medium size networks.  Again, be sure that
all machines have unique names.

3) DNS.  You set up a Microsoft DNS server, and have all your machines
register in that.  Non-MS DNS servers can be used, but then the
machines cannot register themselves, you'll need to configure
everything.  A basic setup will work with Samba, but you'll need MS
servers to go all the way (or perhaps Samba 4).  The way that MS
designed this, it seems that they assumed that every machine has a
public IP-address; it is very hard to grasp how this is properly
combined with NAT.  However, it is probably the only way to run a
really huge setup.

To elaborate a bit about the settings you mention:

> workgroup = SAMBA_WORK_GROUP
> domain master = yes

These two settings say that Samba should be the Domain Controller of a
Windows NT domain called SAMBA_WORK_GROUP.

Windows NT domains are not related to DNS in any way (though Windows
2000 domains are).  They are used 1) to allow an administrator to
centrally configure all participating machines, and 2) to allow a user
to log on to every participation machine with the same account.  The
clients must be joined to the domain to get these two advantages.

If you don't want to use the NT domain functions, you should set
domain master to no.  Workgroup must still be set -- probably you'll
want to set it to the same as the workgroup that you have set the
clients to (My Computer, Properties, Computer Name in Win XP).

> local master = yes
> preferred master = yes

These are related to the way that broadcast is handled, see above.
The master is a machine that collects the various broadcasted
information so that a newly booted client has a quick way to get it.
The machines on the lan vote about who should be the master; local
master allows Samba to run for master, while preferred master will
make Samba fight to get chosen.  When you run an NT domain, it is a
good idea for the domain controller to be master as well.  These
settings look OK.

... hope that I managed to confuse you as much as MS has managed to
confuse me


Rune

On Mon, Oct 13, 2008 at 14:10, Adam Hardy  wrote:
> Thanks for the reply.
>
> Both dnsmasq and samba are set up by me, but the config I gave below could
> easily imply something I don't intend - I'm not 100% sure on it. Maybe at
> best 60% :(
>
> Shouldn't dnsmasq and the gateway DHCP server be the domain controller? And
> so samba should be subordinate - OK, I see now that setting up samba with
> "domain master = yes" could be bad.
>
> What I'm fundamentally unclear about is what the workgroup is - is it just a
> samba-style name for the domain - and therefore should be 'localdomain'?
>
>
>
> Adam
>
> richardvo...@gmail.com on 13/10/08 12:42, wrote:
>>
>> If you're set up as a domain controller, rather than plain workgroup
>> (and you are), then you need to forward dns requests for that domain
>> to the samba domain controller.  I think the needed dnsmasq
>> configuration option is "server".  You also need to make sure dnsmasq
>> is not filtering out Microsoft Networking requires, there's a
>> filterwin2k option or something like that which needs to be disabled.
>>
>> Hope this helps.
>>
>> On Mon, Oct 13, 2008 at 10:21 AM, Adam Hardy
>>  wrote:
>>>
>>> Just been wading through the docs and the mailing lists at samba.org
>>> trying
>>> to find out how I should configure my samba file server but I still
>>> haven't
>>> been able to work out the relationship of the samba server to the rest of
>>> my
>>> network.
>>>
>>> I'm running a SOHO with linux, OS X and windows clients which need to
>>> connect to the samba server to be able to run backups. I think it's
>>> causing
>>> conflict with the main gateway / DHCP server  (which runs dnsmasq).
>>>
>>> Samba has these 4 settings which are causing me complete confusion:
>>>
>>> workgroup = SAMBA_WORK_GROUP
>>> domain master = yes
>>> local master = yes
>>> preferred master = yes
>>>
>>> By all accounts this appears to be the way to allow the clients to browse
>>> the samba server, but I get problems with connections d

Re: [Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-13 Thread Adam Hardy

Thanks for the reply.

Both dnsmasq and samba are set up by me, but the config I gave below could 
easily imply something I don't intend - I'm not 100% sure on it. Maybe at best 
60% :(


Shouldn't dnsmasq and the gateway DHCP server be the domain controller? And so 
samba should be subordinate - OK, I see now that setting up samba with "domain 
master = yes" could be bad.


What I'm fundamentally unclear about is what the workgroup is - is it just a 
samba-style name for the domain - and therefore should be 'localdomain'?




Adam

richardvo...@gmail.com on 13/10/08 12:42, wrote:

If you're set up as a domain controller, rather than plain workgroup
(and you are), then you need to forward dns requests for that domain
to the samba domain controller.  I think the needed dnsmasq
configuration option is "server".  You also need to make sure dnsmasq
is not filtering out Microsoft Networking requires, there's a
filterwin2k option or something like that which needs to be disabled.

Hope this helps.

On Mon, Oct 13, 2008 at 10:21 AM, Adam Hardy
 wrote:

Just been wading through the docs and the mailing lists at samba.org trying
to find out how I should configure my samba file server but I still haven't
been able to work out the relationship of the samba server to the rest of my
network.

I'm running a SOHO with linux, OS X and windows clients which need to
connect to the samba server to be able to run backups. I think it's causing
conflict with the main gateway / DHCP server  (which runs dnsmasq).

Samba has these 4 settings which are causing me complete confusion:

workgroup = SAMBA_WORK_GROUP
domain master = yes
local master = yes
preferred master = yes

By all accounts this appears to be the way to allow the clients to browse
the samba server, but I get problems with connections dropping,
authentications failing and sometimes the server not even showing up.

Am I right that the workgroup name should be totally different from the
domain name I set for the DHCP clients in dnsmasq? (localdomain)




Re: [Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-13 Thread richardvo...@gmail.com
If you're set up as a domain controller, rather than plain workgroup
(and you are), then you need to forward dns requests for that domain
to the samba domain controller.  I think the needed dnsmasq
configuration option is "server".  You also need to make sure dnsmasq
is not filtering out Microsoft Networking requires, there's a
filterwin2k option or something like that which needs to be disabled.

Hope this helps.

On Mon, Oct 13, 2008 at 10:21 AM, Adam Hardy
 wrote:
> Just been wading through the docs and the mailing lists at samba.org trying
> to find out how I should configure my samba file server but I still haven't
> been able to work out the relationship of the samba server to the rest of my
> network.
>
> I'm running a SOHO with linux, OS X and windows clients which need to
> connect to the samba server to be able to run backups. I think it's causing
> conflict with the main gateway / DHCP server  (which runs dnsmasq).
>
> Samba has these 4 settings which are causing me complete confusion:
>
> workgroup = SAMBA_WORK_GROUP
> domain master = yes
> local master = yes
> preferred master = yes
>
> By all accounts this appears to be the way to allow the clients to browse
> the samba server, but I get problems with connections dropping,
> authentications failing and sometimes the server not even showing up.
>
> Am I right that the workgroup name should be totally different from the
> domain name I set for the DHCP clients in dnsmasq? (localdomain)
>
> Thanks
> Adam
>
> ___
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss@lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>



[Dnsmasq-discuss] samba and workgroups with dhcp

2008-10-13 Thread Adam Hardy
Just been wading through the docs and the mailing lists at samba.org trying to 
find out how I should configure my samba file server but I still haven't been 
able to work out the relationship of the samba server to the rest of my network.


I'm running a SOHO with linux, OS X and windows clients which need to connect to 
the samba server to be able to run backups. I think it's causing conflict with 
the main gateway / DHCP server  (which runs dnsmasq).


Samba has these 4 settings which are causing me complete confusion:

workgroup = SAMBA_WORK_GROUP
domain master = yes
local master = yes
preferred master = yes

By all accounts this appears to be the way to allow the clients to browse the 
samba server, but I get problems with connections dropping, authentications 
failing and sometimes the server not even showing up.


Am I right that the workgroup name should be totally different from the domain 
name I set for the DHCP clients in dnsmasq? (localdomain)


Thanks
Adam