[Bug 824024] [NEW] "semicolon expected" parsing errors on "cltt" in dhcpd.leases
Loïc Minier
lool at dooz.org
Wed Aug 10 15:40:34 UTC 2011
Public bug reported:
Hey
This is about bogus parsing of the leases file by dhcpd.
I don't know whether this is BOOTP specific or not, but I've setup isc-dhcp-server (dhcpd) to accept bootp clients with this config:
subnet 172.16.0.0 netmask 255.240.0.0 {
range dynamic-bootp 172.17.0.0 172.17.255.255;
option domain-name-servers google-public-dns-a.google.com, google-public-dns-b.google.com;
option routers 172.16.0.254;
option broadcast-address 172.31.255.255;
default-lease-time 600;
max-lease-time 7200;
filename "xyz";
}
eth1 is setup as follows in /etc/network/interfaces:
iface eth1 inet static
address 172.16.0.254
netmask 255.240.0.0
The BOOTP client is connected with a direct ethernet cable from an USB
ethernet adapter on my laptop to its first network interface and is
running RedBoot as a bootloader (it's an ARM box).
When dhcpd starts the first time, it looks something like this:
Aug 10 17:25:06 localhost dhcpd: Internet Systems Consortium DHCP Server 4.1.1-P1
Aug 10 17:25:06 localhost dhcpd: Copyright 2004-2010 Internet Systems Consortium.
Aug 10 17:25:06 localhost dhcpd: All rights reserved.
Aug 10 17:25:06 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Aug 10 17:25:06 localhost dhcpd: Wrote 0 leases to leases file.
then eventually the BOOTP request comes in when the device boots:
Aug 10 17:25:29 localhost NetworkManager[1190]: <info> (eth1): carrier now ON (device state 10)
Aug 10 17:25:29 localhost kernel: [21893.809257] asix 2-1.4:1.0: eth1: link up, 100Mbps, full-duplex, lpa 0xC1E1
Aug 10 17:25:30 localhost dhcpd: BOOTREQUEST from 00:14:fd:10:38:9a via eth1
Aug 10 17:25:30 localhost dhcpd: BOOTREPLY on 172.17.0.0 to 00:14:fd:10:38:9a via eth1
I run a network trace in parallel that shows that *two* BOOTP requests
come in with one second of interval, looking pretty much identical. The
second one is immediately answered with a lease.
Poking /var/lib/dhcp/dhcpd.leases at this point shows *two* entries for 172.17.0.0 looking something like:
lease 172.17.0.0 {
starts 3 2011/08/10 15:25:30;
ends never;
cltt 3 2011/08/10 15:25:30;
binding state free;
hardware ethernet 00:14:fd:10:38:9a;
}
this is listed twice with same IP and MAC address.
If I then restart dhcpd, I get:
Aug 10 17:31:30 localhost dhcpd: Internet Systems Consortium DHCP Server 4.1.1-P1
Aug 10 17:31:30 localhost dhcpd: Copyright 2004-2010 Internet Systems Consortium.
Aug 10 17:31:30 localhost dhcpd: All rights reserved.
Aug 10 17:31:30 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Aug 10 17:31:30 localhost dhcpd: /var/lib/dhcp/dhcpd.leases line 9: semicolon expected.
Aug 10 17:31:30 localhost dhcpd: cltt
Aug 10 17:31:30 localhost dhcpd: ^
Aug 10 17:31:30 localhost dhcpd: /var/lib/dhcp/dhcpd.leases line 17: semicolon expected.
Aug 10 17:31:30 localhost dhcpd: cltt
Aug 10 17:31:30 localhost dhcpd: ^
Aug 10 17:31:30 localhost dhcpd: Wrote 1 leases to leases file.
and the lease file now has only one entry like:
lease 172.17.0.0 {
starts 3 2011/08/10 15:25:30;
binding state free;
hardware ethernet 00:14:fd:10:38:9a;
}
There are two things wrong here:
* two entries in the lease file, not sure why
* can't parse its own leases on restart ("end" and "cltt" params)
Cheers,
ProblemType: Bug
DistroRelease: Ubuntu 11.10
Package: isc-dhcp-server 4.1.1-P1-17ubuntu5
Uname: Linux 3.0.0-0300rc1-generic x86_64
Architecture: amd64
Date: Wed Aug 10 17:32:19 2011
ProcEnviron:
LANGUAGE=fr_FR:fr:en_GB:en
PATH=(custom, user)
LANG=fr_FR.UTF-8
SHELL=/bin/zsh
SourcePackage: isc-dhcp
UpgradeStatus: Upgraded to oneiric on 2009-12-07 (611 days ago)
mtime.conffile..etc.dhcp.dhcpd.conf: 2011-08-10T17:23:15.277158
** Affects: isc-dhcp (Ubuntu)
Importance: Undecided
Status: New
** Tags: amd64 apport-bug oneiric running-unity
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to isc-dhcp in Ubuntu.
https://bugs.launchpad.net/bugs/824024
Title:
"semicolon expected" parsing errors on "cltt" in dhcpd.leases
Status in “isc-dhcp” package in Ubuntu:
New
Bug description:
Hey
This is about bogus parsing of the leases file by dhcpd.
I don't know whether this is BOOTP specific or not, but I've setup isc-dhcp-server (dhcpd) to accept bootp clients with this config:
subnet 172.16.0.0 netmask 255.240.0.0 {
range dynamic-bootp 172.17.0.0 172.17.255.255;
option domain-name-servers google-public-dns-a.google.com, google-public-dns-b.google.com;
option routers 172.16.0.254;
option broadcast-address 172.31.255.255;
default-lease-time 600;
max-lease-time 7200;
filename "xyz";
}
eth1 is setup as follows in /etc/network/interfaces:
iface eth1 inet static
address 172.16.0.254
netmask 255.240.0.0
The BOOTP client is connected with a direct ethernet cable from an USB
ethernet adapter on my laptop to its first network interface and is
running RedBoot as a bootloader (it's an ARM box).
When dhcpd starts the first time, it looks something like this:
Aug 10 17:25:06 localhost dhcpd: Internet Systems Consortium DHCP Server 4.1.1-P1
Aug 10 17:25:06 localhost dhcpd: Copyright 2004-2010 Internet Systems Consortium.
Aug 10 17:25:06 localhost dhcpd: All rights reserved.
Aug 10 17:25:06 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Aug 10 17:25:06 localhost dhcpd: Wrote 0 leases to leases file.
then eventually the BOOTP request comes in when the device boots:
Aug 10 17:25:29 localhost NetworkManager[1190]: <info> (eth1): carrier now ON (device state 10)
Aug 10 17:25:29 localhost kernel: [21893.809257] asix 2-1.4:1.0: eth1: link up, 100Mbps, full-duplex, lpa 0xC1E1
Aug 10 17:25:30 localhost dhcpd: BOOTREQUEST from 00:14:fd:10:38:9a via eth1
Aug 10 17:25:30 localhost dhcpd: BOOTREPLY on 172.17.0.0 to 00:14:fd:10:38:9a via eth1
I run a network trace in parallel that shows that *two* BOOTP requests
come in with one second of interval, looking pretty much identical.
The second one is immediately answered with a lease.
Poking /var/lib/dhcp/dhcpd.leases at this point shows *two* entries for 172.17.0.0 looking something like:
lease 172.17.0.0 {
starts 3 2011/08/10 15:25:30;
ends never;
cltt 3 2011/08/10 15:25:30;
binding state free;
hardware ethernet 00:14:fd:10:38:9a;
}
this is listed twice with same IP and MAC address.
If I then restart dhcpd, I get:
Aug 10 17:31:30 localhost dhcpd: Internet Systems Consortium DHCP Server 4.1.1-P1
Aug 10 17:31:30 localhost dhcpd: Copyright 2004-2010 Internet Systems Consortium.
Aug 10 17:31:30 localhost dhcpd: All rights reserved.
Aug 10 17:31:30 localhost dhcpd: For info, please visit https://www.isc.org/software/dhcp/
Aug 10 17:31:30 localhost dhcpd: /var/lib/dhcp/dhcpd.leases line 9: semicolon expected.
Aug 10 17:31:30 localhost dhcpd: cltt
Aug 10 17:31:30 localhost dhcpd: ^
Aug 10 17:31:30 localhost dhcpd: /var/lib/dhcp/dhcpd.leases line 17: semicolon expected.
Aug 10 17:31:30 localhost dhcpd: cltt
Aug 10 17:31:30 localhost dhcpd: ^
Aug 10 17:31:30 localhost dhcpd: Wrote 1 leases to leases file.
and the lease file now has only one entry like:
lease 172.17.0.0 {
starts 3 2011/08/10 15:25:30;
binding state free;
hardware ethernet 00:14:fd:10:38:9a;
}
There are two things wrong here:
* two entries in the lease file, not sure why
* can't parse its own leases on restart ("end" and "cltt" params)
Cheers,
ProblemType: Bug
DistroRelease: Ubuntu 11.10
Package: isc-dhcp-server 4.1.1-P1-17ubuntu5
Uname: Linux 3.0.0-0300rc1-generic x86_64
Architecture: amd64
Date: Wed Aug 10 17:32:19 2011
ProcEnviron:
LANGUAGE=fr_FR:fr:en_GB:en
PATH=(custom, user)
LANG=fr_FR.UTF-8
SHELL=/bin/zsh
SourcePackage: isc-dhcp
UpgradeStatus: Upgraded to oneiric on 2009-12-07 (611 days ago)
mtime.conffile..etc.dhcp.dhcpd.conf: 2011-08-10T17:23:15.277158
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/isc-dhcp/+bug/824024/+subscriptions
More information about the foundations-bugs
mailing list