On Sat, 9 May 2009, Mel Flynn wrote:

On Saturday 09 May 2009 15:09:45 Pieter Donche wrote:

case DHCP server             DHCP client       HOSTNAME env. var.

  1   isc-dhcp30-server       FreeBSD7-i386     not set
       on FreeBSD-amd64
  2   isc-dhcp30-server       SuSE Linux 10.3   set
       on FreeBSD-amd64

  3   some DHCP server        FreeBSD7-i386     set
       on unkown serverOS
  4   some DHCP server        SuSE Linux 10.3   set
        on unkown serverOS

Judging from this, you have a hostname set in /etc/rc.conf on freebsd 7 client
and/or dhcpd isn't configured to send one as it receives one from the client
and perhaps you have dynamic DNS configured?

There is no hostname= declaration in /etc/rc.conf in that FreeBSD7 dhcp client.

My dhcpd.conf contains mostly statically defined addresses (over a 100)
e.g. host somehostname { hardware ethernet aa:bb:cc:dd:ee:ff; fixed-address AAA.BBB.CCC.DDD; }
and one set of 6 dynamically assigned addresses.

We want regular users to always get the same IP address based on the MAC
address of their system, the pool of 6 is for visitors for one or a few
days that we do allow not to register their MAC address.

The freebsd7 client is one of the 100+ statically assigned ones, but
I might have done a try for the dynamic assignment with this PC (by taking
it temporarily out of /usr/local/etc/dhcpd.conf, restart dhcpd, try, then put it back in, restart dhcpd.

In fact in /var/db/dhcpd/dhcpd.conf I see I do have an entry
lease AAA.BBB.CCC.DDD {
  starts 4 2009/05/07 12:49:13;
  ends 4 2009/05/07 13:19:16;
  tstp 4 2009/05/07 13:19:16;
  binding state free;
  hardware ethernet aa.bb.cc.dd.ee.ff;
  uid "\001\000\013\333S>\025";
}
AAA.BBB.CCC.DDD being one of the pool of 6 and the ethernet adddress that
of the freebsd client.

I see that's "free'd" already (max lease time is 12 hours) and I tried back with that entry again as a statically defined one. Or does this dhcpd.lease entry still have an impact ???

The man of dhcpd.leases says "In order to prevent the lease database from growing without bound, the file is rewritten from time to time."
Can one do such a "rewrite" oneself, how ? would that help?

On the other hand the AAA.BBB.CCC.DDD IP address does have a hostname
specified in the DNS server (somewhere in our campus) (and that DNS
server can be queried from the freebsd client via nslookup or host command and it returns the correct hostname). So even in dynamic assignment, shouldn't HOSTNAME been set with that hostname from DNS?


If that's not the case, then you should add some debugging to /sbin/dhclient-
script in the check_hostname function.

--
Mel

_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[email protected]"

Reply via email to