List Info

Thread: ddns - getting close




ddns - getting close
user name
2006-02-21 01:55:27
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

So close...

If the client supplies a hostname to dhcpd when it is
requesting an IP, dhcpd 
updates the zone file.  very good.

If the client doesn't, I have this to construct a hostname:

# construct a hostname out of the IP being assigned.
# given that all IP's will begin with 192.168.1,
# only use the last byte - makes a shorter so easier to type
the host name.
# On Ubuntu installs, the installer will use this as the
permanate hostname
# so all boxes don't end up named localhost.  (that's a
good thing)

# Option 12: Host Name = "dhcp254"
option host-name=concat("dhcp",
binary-to-ascii(10, 8, "-", 
suffix(leased-address,1) ) ) ;

Which works, and the client picks it up (at least the Ubuntu
installer does, 
which is the only test I have now.)  But it doesn't make it
to dns land, and 
this is all I see in syslog:

Feb 20 19:50:14 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
Feb 20 19:50:15 localhost dhcpd: DHCPOFFER on 192.168.1.206
to 00:10:83:fc:4d:76 
via eth0
Feb 20 19:50:16 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
from 00:10:83:fc:4d:76 via eth0
Feb 20 19:50:16 localhost dhcpd: DHCPACK on 192.168.1.206 to
00:10:83:fc:4d:76 
via eth0

Feb 20 19:50:58 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
Feb 20 19:50:58 localhost dhcpd: DHCPOFFER on 192.168.1.206
to 00:10:83:fc:4d:76 
via eth0
Feb 20 19:51:01 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
from 00:10:83:fc:4d:76 via eth0
Feb 20 19:51:01 localhost dhcpd: DHCPACK on 192.168.1.206 to
00:10:83:fc:4d:76 
via eth0

(2 dhcps - one for pxe, one for installer)

^CarlK

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 04:04:29
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

For our DDNS implementation, we used:

ddns-hostname = concat ("rgboot-",
binary-to-ascii 
(16,8,"-",substring(hardware,1,6)));
option host-name= concat ("rgboot-",
binary-to-ascii 
(16,8,"-",substring(hardware,1,6)));

That seems to work for us.

Curt Rask

Carl Karsten wrote:
>    *** From dhcp-server -- To unsubscribe, see the end
of this message. ***
> 
> So close...
> 
> If the client supplies a hostname to dhcpd when it is
requesting an IP, dhcpd 
> updates the zone file.  very good.
> 
> If the client doesn't, I have this to construct a
hostname:
> 
> # construct a hostname out of the IP being assigned.
> # given that all IP's will begin with 192.168.1,
> # only use the last byte - makes a shorter so easier to
type the host name.
> # On Ubuntu installs, the installer will use this as
the permanate hostname
> # so all boxes don't end up named localhost.  (that's
a good thing)
> 
> # Option 12: Host Name = "dhcp254"
> option host-name=concat("dhcp",
binary-to-ascii(10, 8, "-", 
> suffix(leased-address,1) ) ) ;
> 
> Which works, and the client picks it up (at least the
Ubuntu installer does, 
> which is the only test I have now.)  But it doesn't
make it to dns land, and 
> this is all I see in syslog:
> 
> Feb 20 19:50:14 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:15 localhost dhcpd: DHCPOFFER on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> Feb 20 19:50:16 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
> from 00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:16 localhost dhcpd: DHCPACK on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> 
> Feb 20 19:50:58 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:58 localhost dhcpd: DHCPOFFER on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> Feb 20 19:51:01 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
> from 00:10:83:fc:4d:76 via eth0
> Feb 20 19:51:01 localhost dhcpd: DHCPACK on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> 
> (2 dhcps - one for pxe, one for installer)
> 
> ^CarlK
> 
>
------------------------------------------------------------
-----------
> List Archives : http://www.isc.org/ops/
lists/
> Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
> -or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
>
------------------------------------------------------------
-----------
> 

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 06:25:20
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

Hi Carl,

try something like this:

# The following is one line !!!
ddns-hostname = pick (option fqdn.hostname, option
host-name, concat ("", binary-to-ascii (10, 8,
"-", lea
sed-address)));

Regards

Holger

Carl Karsten schrieb:

>    *** From dhcp-server -- To unsubscribe, see the end
of this message. ***
>
> So close...
>
> If the client supplies a hostname to dhcpd when it is
requesting an IP, dhcpd 
> updates the zone file.  very good.
>
> If the client doesn't, I have this to construct a
hostname:
>
> # construct a hostname out of the IP being assigned.
> # given that all IP's will begin with 192.168.1,
> # only use the last byte - makes a shorter so easier to
type the host name.
> # On Ubuntu installs, the installer will use this as
the permanate hostname
> # so all boxes don't end up named localhost.  (that's
a good thing)
>
> # Option 12: Host Name = "dhcp254"
> option host-name=concat("dhcp",
binary-to-ascii(10, 8, "-", 
> suffix(leased-address,1) ) ) ;
>
> Which works, and the client picks it up (at least the
Ubuntu installer does, 
> which is the only test I have now.)  But it doesn't
make it to dns land, and 
> this is all I see in syslog:
>
> Feb 20 19:50:14 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:15 localhost dhcpd: DHCPOFFER on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> Feb 20 19:50:16 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
> from 00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:16 localhost dhcpd: DHCPACK on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
>
> Feb 20 19:50:58 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
> Feb 20 19:50:58 localhost dhcpd: DHCPOFFER on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
> Feb 20 19:51:01 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7) 
> from 00:10:83:fc:4d:76 via eth0
> Feb 20 19:51:01 localhost dhcpd: DHCPACK on
192.168.1.206 to 00:10:83:fc:4d:76 
> via eth0
>
> (2 dhcps - one for pxe, one for installer)
>
> ^CarlK
>
>
------------------------------------------------------------
-----------
> List Archives : http://www.isc.org/ops/
lists/
> Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
> -or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
>
------------------------------------------------------------
-----------
>
>
>
>   



------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 08:52:32
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

Carl Karsten wrote:

>Which works, and the client picks it up (at least the
Ubuntu installer does,
>which is the only test I have now.)  But it doesn't
make it to dns land, and
>this is all I see in syslog:
>
>Feb 20 19:50:14 localhost dhcpd: DHCPDISCOVER from
00:10:83:fc:4d:76 via eth0
>Feb 20 19:50:15 localhost dhcpd: DHCPOFFER on
192.168.1.206 to 
>00:10:83:fc:4d:76
>via eth0
>Feb 20 19:50:16 localhost dhcpd: DHCPREQUEST for
192.168.1.206 (192.168.1.7)
>from 00:10:83:fc:4d:76 via eth0
>Feb 20 19:50:16 localhost dhcpd: DHCPACK on
192.168.1.206 to 00:10:83:fc:4d:76
>via eth0

Can you post your dhcpd.conf and the lease entry from the
dhcpd.leases file ?

Simon

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 15:03:53
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

Holger Honert wrote:
>    *** From dhcp-server -- To unsubscribe, see the end
of this message. ***
> 
> Hi Carl,
> 
> try something like this:
> 
> # The following is one line !!!
> ddns-hostname = pick (option fqdn.hostname, option
host-name, concat ("", binary-to-ascii (10, 8,
"-", lea
> sed-address)));

I can put "option" there?!

Thanks,

^C

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 16:32:09
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

On Mon, Feb 20, 2006 at 07:55:27PM -0600, Carl Karsten
wrote:
> # Option 12: Host Name = "dhcp254"
> option host-name=concat("dhcp",
binary-to-ascii(10, 8, "-", 
> suffix(leased-address,1) ) ) ;
> 
> Which works, and the client picks it up (at least the
Ubuntu installer does, 
> which is the only test I have now.)  But it doesn't
make it to dns land, and 
> this is all I see in syslog:

The 'host-name' option is one thing.  The
'ddns-hostname' is another.

Quoting dhcpd.conf(5) manpage:

       The DHCP server determines the client’s hostname by
first looking for a
       ddns‐hostname  configuration  option,  and using
that if it is present.
       If no such option is present, the server looks for a
valid hostname  in
       the  FQDN option sent by the client.  If one is
found, it is used; oth‐
       erwise, if the client sent a host‐name option, that
 is  used.   Other‐
       wise,  if  there  is a host declaration that applies
to the client, the
       name from that declaration will be used.  If none of
these applies, the
       server will not have a hostname for the client, and
will not be able to
       do a DNS update.

       The domain name is determined based strictly on the 
server  configura‐
       tion, not on what the client sends.   First, if there
is a ddns‐domain‐
       name configuration option, it is used.   Second, if
there is a  domain‐
       name  option  configured, that is used.  Otherwise,
the server will not
       do the DNS update.

I'm quoting that bit because it's impossible to find
otherwise.  It's
hidden in the ad-hoc ddns update documentation.  It just so
happens that
the interim uses the same source for 'client name'
information for ddns
updates.  To remove the mystery from this, the following
line is
fed into the parser at global scope when the daemon starts
up:

char std_nsupdate [] = "                              
                     \n\
option server.ddns-hostname =                               
               \n\
  pick (option fqdn.hostname, option host-name);            
               \n\
option server.ddns-domainname = config-option domain-name;  
               \n\
option server.ddns-ttl = encode-int(lease-time / 2, 32);    
               \n\
option server.ddns-rev-domainname =
\"in-addr.arpa.\";";

So, when you configure a ddns-hostname option, you're
over-riding that
pick() that's already configured.

The problem you're having is that 'option host-name' is
the option
supplied by the client ("option"), not the
option in configuration to be
supplied to the client ("config-option").

-- 
David W. Hankins		"If you don't do it right the first
time,
Software Engineer			you'll just have to do it again."
Internet Systems Consortium, Inc.		-- Jack T. Hankins

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 17:19:48
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

David W. Hankins wrote:
>    *** From dhcp-server -- To unsubscribe, see the end
of this message. ***
> 
> On Mon, Feb 20, 2006 at 07:55:27PM -0600, Carl Karsten
wrote:
> 
>># Option 12: Host Name = "dhcp254"
>>option host-name=concat("dhcp",
binary-to-ascii(10, 8, "-", 
>>suffix(leased-address,1) ) ) ;
>>
>>Which works, and the client picks it up (at least
the Ubuntu installer does, 
>>which is the only test I have now.)  But it doesn't
make it to dns land, and 
>>this is all I see in syslog:
> 
> 
> The 'host-name' option is one thing.  The
'ddns-hostname' is another.
> 
> Quoting dhcpd.conf(5) manpage:
> 
>        The DHCP server determines the client’s
hostname by first looking for a
>        ddns‐hostname  configuration  option,  and
using that if it is present.
>        If no such option is present, the server looks
for a valid hostname  in
>        the  FQDN option sent by the client.  If one is
found, it is used; oth‐
>        erwise, if the client sent a host‐name option,
that  is  used.   Other‐
>        wise,  if  there  is a host declaration that
applies to the client, the
>        name from that declaration will be used.  If
none of these applies, the
>        server will not have a hostname for the client,
and will not be able to
>        do a DNS update.
> 
>        The domain name is determined based strictly on
the  server  configura‐
>        tion, not on what the client sends.   First, if
there is a ddns‐domain‐
>        name configuration option, it is used.   Second,
if there is a  domain‐
>        name  option  configured, that is used. 
Otherwise, the server will not
>        do the DNS update.
> 
> I'm quoting that bit because it's impossible to find
otherwise.  It's
> hidden in the ad-hoc ddns update documentation.  It
just so happens that
> the interim uses the same source for 'client name'
information for ddns
> updates.  To remove the mystery from this, the
following line is
> fed into the parser at global scope when the daemon
starts up:
> 
> char std_nsupdate [] = "                         
                          \n\
> option server.ddns-hostname =                          
                    \n\
>   pick (option fqdn.hostname, option host-name);       
                    \n\
> option server.ddns-domainname = config-option
domain-name;                  \n\
> option server.ddns-ttl = encode-int(lease-time / 2,
32);                    \n\
> option server.ddns-rev-domainname =
\"in-addr.arpa.\";";
> 
> So, when you configure a ddns-hostname option, you're
over-riding that
> pick() that's already configured.
> 
> The problem you're having is that 'option host-name'
is the option
> supplied by the client ("option"), not the
option in configuration to be
> supplied to the client ("config-option").
> 

"If none of these applies, the server will not have a
hostname for the client..."

I thought that there was a default name dhcpd would generate
in that case; so 
now I undersand a bit more, but im still missing something:


"'option host-name' is the option supplied by the
client"

_by_ the client?  I am totaly confused by that.  seems to me
dhcpd is supplying 
that to the client.

^C






------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

ddns - getting close
user name
2006-02-21 18:51:15
   *** From dhcp-server -- To unsubscribe, see the end of
this message. ***

On Tue, Feb 21, 2006 at 11:19:48AM -0600, Carl Karsten
wrote:
> "'option host-name' is the option supplied by
the client"
> 
> _by_ the client?  I am totaly confused by that.  seems
to me dhcpd is supplying 
> that to the client.

No, both the server and the client place options in the
packets they
transmit to each other.

Have a read at RFC2131.

-- 
David W. Hankins		"If you don't do it right the first
time,
Software Engineer			you'll just have to do it again."
Internet Systems Consortium, Inc.		-- Jack T. Hankins

------------------------------------------------------------
-----------
List Archives : http://www.isc.org/ops/
lists/
Unsubscribe   : http://www.
isc.org/sw/dhcp/dhcp-lists.php    
-or-          : mailto:dhcp-server-requestisc.org?Subject=unsubscribe  
------------------------------------------------------------
-----------

[1-8]

about | contact  Other archives ( Real Estate discussion Medical topics )