[Dnsmasq-discuss] Cannot assign IPv6 address for /96 subnet

Simon Kelley simon at thekelleys.org.uk
Tue Feb 12 21:40:55 GMT 2013


On 12/02/13 01:13, Sheng Yang wrote:
> Yes, I just tried, and that works.
>
> I am using dhcp-host files to assign all the ips on the network, I
> guess that's what goes wrong...
>
> Here is the file content:
>
> id:00:03:00:01:06:4f:66:00:00:2e,[fc00:3:1602::dca1/96],test1,infinite
                                                      ^^^

You don't need the prefix length here, and it's stopping the parser from 
recognising the IPv6 address. This is probably the only problem


>
> And config file:
> resolv-file=/etc/dnsmasq-resolv.conf
> interface=eth0
> listen-address=fc00:3:1602::7473
> bind-interfaces
> expand-hosts
> dhcp-range=fc00:3:1602::7473,96,static
> dhcp-hostsfile=/etc/dhcphosts.txt
> dhcp-option=vendor:MSFT,2,1i
> leasefile-ro
> log-dhcp
> log-facility=/var/log/dnsmasq.log
> conf-dir=/etc/dnsmasq.d
> dhcp-option=option6:dns-server,[::]
>
> Do I need to specify prefix length in dhcp-host file?

See above, no you don't.


Cheers,

Simon.

>
> --Sheng
>
>
> On Mon, Feb 11, 2013 at 12:06 PM, Simon Kelley <simon at thekelleys.org.uk> wrote:
>> On 09/02/13 02:59, Sheng Yang wrote:
>>>
>>> Hi Simon,
>>>
>>> I found I can't assign IPv6 address for /96 subnet.
>>>
>>> I specified DHCP range use 96 bits prefixes:
>>>
>>> dhcp-range=fc00:3:1602::7473,96,static
>>>
>>> And here is nic:
>>>
>>> 2: eth0:<BROADCAST,MULTICAST,UP,LOWER_UP>  mtu 1500 qdisc pfifo_fast
>>> state UP qlen 1000
>>>       link/ether 06:8a:42:00:00:2f brd ff:ff:ff:ff:ff:ff
>>>       inet6 fc00:3:1602::7473/96 scope global
>>>          valid_lft forever preferred_lft forever
>>>       inet6 fe80::48a:42ff:fe00:2f/64 scope link
>>>          valid_lft forever preferred_lft forever
>>>
>>> I've enabled logdhcp, but didn't see anything in the log after restart
>>> the dnsmasq except loading configurations info.
>>>
>>> TCPDUMP shows:
>>>
>>> 02:54:53.695350 IP6 fe80::44f:66ff:fe00:2e.dhcpv6-client>
>>> ff02::1:2.dhcpv6-server: dhcp6 solicit
>>> 02:54:54.726548 IP6 fe80::44f:66ff:fe00:2e.dhcpv6-client>
>>> ff02::1:2.dhcpv6-server: dhcp6 solicit
>>> 02:54:56.838944 IP6 fe80::44f:66ff:fe00:2e.dhcpv6-client>
>>> ff02::1:2.dhcpv6-server: dhcp6 solicit
>>>
>>> More detail:
>>> 02:55:57.448471 IP6 (hlim 1, next-header UDP (17) payload length: 73)
>>> fe80::44f:66ff:fe00:2e.dhcpv6-client>  ff02::1:2.dhcpv6-server: [udp
>>> sum ok] dhcp6 solicit (xid=4157d (client-ID hwaddr type 1
>>> 064f6600002e) (option-request DNS-name Client-FQDN DNS NTP-Server)
>>> (elapsed-time 101) (Client-FQDN) (IA_NA IAID:1711276078 T1:3600
>>> T2:5400))
>>> 0x0000:  3333 0001 0002 064f 6600 002e 86dd 6000
>>> 0x0010:  0000 0049 1101 fe80 0000 0000 0000 044f
>>> 0x0020:  66ff fe00 002e ff02 0000 0000 0000 0000
>>> 0x0030:  0000 0001 0002 0222 0223 0049 4b0e 0104
>>> 0x0040:  157d 0001 000a 0003 0001 064f 6600 002e
>>> 0x0050:  0006 0008 0018 0027 0017 001f 0008 0002
>>> 0x0060:  0065 0027 0009 0006 7562 756e 7475 0000
>>> 0x0070:  0300 0c66 0000 2e00 000e 1000 0015 18
>>>
>>> Seems valid.
>>>
>>> If I didn't specify "96" in the dhcp-range line, it would complains:
>>>
>>> Feb  9 02:57:15 dnsmasq-dhcp[2134]: no address range available for
>>> DHCPv6 request via eth0
>>>
>>> I don't know which part of setup is wrong. Probably due to link local
>>> address is /64?
>>
>>
>> Let's make the problem simpler: is you specify a range for address
>> allocation, does it work?
>>
>> dhcp-range=fc00:3:1602::7473,fc00:3:1602::8000,96
>>
>>
>> How are you specifying the static addresses of your hosts?
>>
>>
>> Cheers,
>>
>> Simon.
>>
>> _______________________________________________
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss at lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>




More information about the Dnsmasq-discuss mailing list