Hello Rajesh,

Wednesday, January 01, 2003, 7:26:39 AM, you wrote:

RG> Hi All,
RG>      Is it possible to have thin clients with dynamic
RG> IP assigned?? Currently i have to assign fixed IPs to
RG> thin clients based on MAC addresses in dhcpd.conf.  To
RG> add new thin client, I have to note down its MAC
RG> address and add it in dhcpd.conf. 
RG>     I read one article on one site saying this is
RG> possible, but with only some specific switches.
RG> Actually i have lost that link. Does anyone has that
RG> link, so i could try to implement on my site?? Anyway,
RG> if anyone has implemented this at his/her site, plz
RG> share the knowledge. 

>From a former posting of mine (come back for advice if you need):


Date: Wed, 18 Dec 2002 20:01:47 +0100
From: Anselm Martin Hoffmeister <[EMAIL PROTECTED]>
X-Mailer: The Bat! (v1.53d)
Reply-To: Anselm Martin Hoffmeister <[EMAIL PROTECTED]>
Organization: Stockholm Projekt Computer-Service
X-Priority: 3 (Normal)
Message-ID: <[EMAIL PROTECTED]>
Subject: Re: [Ltsp-discuss] dhcpd
In-Reply-To: <25301741.1040227831@[192\.168\.1\.78]>
References: <25301741.1040227831@[192.168.1.78]>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit


[...]
LS> Just one question - The default dhcpd.conf seemed unnecessarily complicated
LS> for what I wanted to achieve. I certainly didn't want to have to know the 
LS> MAC addresses of all my machines before adding them to the LTSP LAN - what 
LS> I really want to achieve is for ordinary users in the company to grab an 
LS> LTSP floppy and just plug it in whenever they fancy, thereby slowly 
LS> migrating away from Windows.

LS> So, here's what I came up with for dhcpd.conf:

LS> ddns-update-style               ad-hoc;
I set this to "none" or "off" - don't remember. If you have no use for
the dynamic update feature, you should do so too. Why activate a
feature that clobbers your log files with dozens of messages a day.

LS> range                           192.168.1.50 192.168.1.99;
Many people have - you seem to know - a "host" statement for every
host, so that the hosts get assigned a host name. There, they specify
a mac address as well as the IP and the future hostname.

That is not the only way:

There is the possibility to hand them over a host-name generated from
the IP-address on-the-fly.. Enter the following quite at this place into
your dhcpd.conf:

  ddns-hostname = concat("ws",binary-to-ascii(10,8,"-",substring(leased-address,2,2)));

which will produce hostname like "ws1-51". Your chance to finetune,
but you could RTFM of dhcpd.conf and dhcp-eval for this. You have
dhcpd3 installed, don't you (not that old v2)?

Then, you could enter the following line into your nameservers
mobile.co.uk zone:

@ IN SOA stuff
...
router   IN A 192.168.1.1
$GENERATE 50-99 ws1-$ A 192.168.1.$

which takes the work to have the lines you thought you had to enter
inside /etc/hosts.

and inside your reverse zone (which SHOULD be setup!)
$ORIGIN 1.168.192.in-addr.arpa.
1       IN PTR router
$GENERATE 50-99 $ PTR ws1-$.mobile.co.uk.

That would mean you had to manipulate the zones on the router that
seems to do to name-services too, not the ltsp-server, obviously.

LS> default-lease-time              21600;
LS> max-lease-time                  21600;

LS> option subnet-mask              255.255.255.0;
LS> option broadcast-address        192.168.1.255;
LS> option routers                  192.168.1.1;
LS> option domain-name-servers      192.168.1.1;
LS> option domain-name              "mobiles.co.uk";
LS> option root-path                "192.168.1.14:/opt/ltsp/i386";
LS> use-host-decl-names             on;
LS> option log-servers              192.168.1.14;
LS> filename                        "/lts/vmlinuz-2.4.19-ltsp-1";

LS> That gets you so far, but then X, and I think NFS complain about not seeing 
LS> the machine in the hosts file (can't remember the exact error).

LS> So all I did was add every single DHCP address to the hosts file, and gave 
LS> it a name as shown below:

LS> 192.168.1.50            ws001
LS> 192.168.1.51            ws002
LS> 192.168.1.52            ws003
LS> 192.168.1.53            ws004
LS> 192.168.1.54            ws005
LS> 192.168.1.55            ws006
LS> 192.168.1.56            ws007
LS> 192.168.1.57            ws008
LS> 192.168.1.58            ws009
LS> 192.168.1.59            ws010
LS>  etc, etc, etc....

Which then would have no need. Well, they would have other names, not
even counting from 1, but does that really matter?

LS> Not particularly elegant, but it did the trick. So here's my question: 
LS> before I unleash my new LTSP beast upon my unsuspecting windows users - can 
LS> anyone see any reason why this setup might cause problems?

If you have more than 50 workstations, obviously. Your timeouts are on
21600 seconds (6h), so every time any hardware address requests an IP,
it will be locked for 6h.
As you wrote about 10 clients, I don't see to great the difficulties
coming.

LS> I already have all the windows workstations picking up their addresses from
LS> this config quite happily, and the LTSP floppy-booting workstations also 
LS> appear to be quite happy. Just thought I'd check though!



As I wrote, if you need more help on this, don't hesistate to contact
me on private mail at anselm DOT lts AT hoffmeister DOT be

Greetings and a happy new year,

Anselm

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to