Antony,

Hostname / IP-address mapping is done either by /etc/hosts, or by DNS.

DHCP can send a hostname to the workstation.  Either it will send the 
hostname specified inside the 'host ws001 { ... }' entry in dhcpd.conf, 
if you have 'use-host-decl-names on;'.  OR, it will lookup the hostname 
from either /etc/hosts or DNS, if you have 'get-lease-hostnames true;' 
in dhcpd.conf.

I've always recommended using a /etc/hosts file for your mapping, 
basically, because I didn't want to get into the support headache of 
helping people setup their dns tables.  It's not rocket science, but it 
can be a real mess, depending on how people want things.

If you have a bunch of workstations and only 1 server, then a /etc/hosts 
file is the easy way to go.  If you have multiple servers, then keeping 
your hosts file in sync can become a problem, in which case using DNS is 
a good way to go.

And, if you do go with DNS, then you'll need a domainname, or something 
like .local or .ltsp.  It almost doesn't matter what you pick, so long 
as it doesnt' conflict with other sites you might want to contact.

btw, I've also been hearing good things about dnsmasq, which as I 
understand it, is capable of being both a DHCP server AND a DNS server. 
I haven't tried it myself though.

Jim McQuillan
[EMAIL PROTECTED]


Antony Gelberg wrote:
> Jim McQuillan wrote:
>> Antony Gelberg wrote:
>>> Hi all,
>>>
>>> I think I might have missed something in the docs - I want to set up a
>>> printer on one of my workstations.  I note that it needs to have a
>>> hostname, so CUPS can be set up on the server.  Hence I assume I need to
>>> have an entry such as:
>>>
>>>     host ws001 {
>>>         hardware ethernet     00:E0:18:E0:04:82;
>>>         fixed-address         192.168.0.1;
>>>         filename              "/lts/vmlinuz.ltsp";
>>>
>>> in my dhcp3.conf and
>>>
>>> [ws001]
>>>     PRINTER_0_DEVICE = /dev/lp0
>>>     PRINTER_0_TYPE   = P
>>>
>>> in my lts.conf.
>>>
>>> Is it best practice to have such stanzas for /every/ LTSP workstation on
>>> a network, or just ones that require specific configuration or have
>>> local devices etc?
>> You only need the host stanzas for the workstations that you want to 
>> have static IP addresses.  In your case, that is probably only the host 
>> with the attached printer.
>>
>> Make sure you also have one of the following entries in your dhcpd.conf 
>> file:
>>
>>     use-host-decl-names on;
>>
>> OR:
>>
>>     get-lease-hostnames true;
>>
>> MAKE SURE you don't have both of those set, as they'll conflict with 
>> each other.
>>
>> If you want to assign the hostname specified in dhcpd.conf 'host ws001 
>> {' then you'll need the first line 'use-host-decl-names on;'.  
> 
> Thanks for the informative response Jim.
> 
> I'd like to be sure that I understand this.  I would like to specify
> hostnames in dhcpd.conf, but I'm not running a local DNS server (yet).
> Presumably if I want to be able to access workstations /by name/ from
> the server without using /etc/hosts, I /have/ to run a DNS server with a
> whatever.local zone?  Then if I want to map hostname / IP in dhcp.conf,
> I use use-host-decl-names or if I want to do the mapping in my DNS zone
> file, I use get-lease-hostnames.
> 
> If somebody could confirm the above, or correct my understanding, I
> would be very grateful.
> 
> Antony
> 
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys-and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _____________________________________________________________________
> Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
>       https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
> For additional LTSP help,   try #ltsp channel on irc.freenode.net

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net

Reply via email to