WIDE-DHCPv6 client configuration and dhcp6c manual

WIDE-DHCPv6 client configuration

The /etc/config/dhcp6c file controls the WIDE-DHCPv6 client package wide-dhcpv6-client configuration. It defines basic properties and interface settings.

Sections

A typical default configuration consists of one dhcp6c section with common settings and one or more interface sections, usually covering the lan and loopback networks.

Basic Properties

The section of type dhcp6c named basic defines common client settings.

Example:

config 'dhcp6c' 'basic' option 'enabled' '1' option 'interface' 'wan' option 'pd' '1' option 'domain_name_servers' '1' option 'script' '/usr/bin/dhcp6c-state'

All defined options of this section are listed below.

NameTypeRequiredDefaultDescription
enabledbooleanno0Specifies whether the DHCPv6 client should be started on boot
interfacestringyeswanSpecifies the logical interface name the client is running on
dnsstringnodnsmasqSpecifies the type of DNS server in use to propagate received DNS information. At the time of writing, only dnsmasq is supported
debugbooleanno0Enables additional debug information in the system log
pdbooleanno1Requests prefix delegation at the DHCPv6 server
nabooleanno0Requests a permanent, non temporary address at the DHCPv6 server
rapid_commitbooleanno1Signalize a rapid commit two message exchange (RFC3315)
domain_name_serversbooleanno1Request a DNS server addresses
domain_namebooleanno0Request the domain name
ntp_serversbooleanno0Request NTP server addresses (RFC5908)
sip_server_addressbooleanno0Request SIP server address (RFC3319)
sip_server_domain_namebooleanno0Request SIP domain names (RFC3319)
nis_server_addressbooleanno0Request Network Information Service (NIS) server address (RFC3898)
nis_domain_namebooleanno0Request Network Information Service (NIS) domain name (RFC3898)
nisp_server_addressbooleanno0Request Network Information Service V2 (NIS+) server address (RFC3898)
nisp_domain_namebooleanno0Request Network Information Service V2 (NIS+) domain name (RFC3898)
bcmcs_server_addressbooleanno0Request Broadcast and Multicast Control Service (BCMCS) address (RFC4280)
bcmcs_server_domain_namebooleanno0Request Broadcast and Multicast Control Service (BCMCS) domain name (RFC4280)
duidstringno(derived from MAC address)Override the DUID used for DHCPv6 requests. The DUID must be specified as a set of at least 7 colon separated heximal digits, e.g. 00:03:00:06:D8:5D:4C:A5:03:F2
scriptfile pathno/usr/bin/dhcp6c-statePath of script which is executed when a reply is received

Interface Settings

Sections of type interface define on which interfaces delegated prefixes are added and how they're aggregated. This sections are named, the section name corresponds to the covered logical interface.

Example:

config 'interface' 'lan' option 'enabled' '1' option 'sla_id' '0' option 'sla_len' '8'
  • lan specifies that this section belongs to the LAN interface
  • sla_id 0 selects the 1st subnet out of the delegated prefix
  • sla_len 8 defines that the received prefix is expected to be 56 bits in size ( 64 - 8 = 56)

The valid options of this section are listed blow.

NameTypeRequiredDefaultDescription
enabledbooleanno0Specifies whether a prefix should be added on this interface
sla_idintegeryes(none)Specifies the site level aggregator identifier (selects the subnet out of the delegated prefix)
sla_lenintegeryes(none)Specifies the site level aggregator length which is the difference of 64 and the delegated prefix size, e.g. /64 minus /56 from ISP = 8

Example

This example requests a /56 sized prefix and DNS servers on wan and configures two /64 subnets out of the prefix on lan and loopback. The loopback interface gets the first subnet assigned, lan the second.

config 'dhcp6c' 'basic' option 'enabled' '1' option 'interface' 'wan' option 'pd' '1' option 'domain_name_servers' '1' option 'script' '/usr/bin/dhcp6c-state' config 'interface' 'loopback' option 'enabled' '1' option 'sla_id' '0' option 'sla_len' '8' config 'interface' 'lan' option 'enabled' '1' option 'sla_id' '1' option 'sla_len' '8'

-------------------

dhcp6c(8) - Linux man page

Name

dhcp6c - DHCPv6 client daemon

Synopsis

dhcp6c [ -dDf ] [ -r all | <addresses...> ] [ -R <addresses...> ] [ -c pathspec ] [ -I ] <interface>

Description

 

dhcp6c is an implementation of the DHCPv6 client.

Using DHCPv6 messages and DHCPv6 options, dhcp6c is used to request and configure IPv6 addresses and host network configuration information (e.g., DNS) for a network interface from the DHCPv6 server. It can also be used as a requesting router to request and configure Prefix Delegation for a subnet.

The assigned IPv6 addresses and prefixes are saved as /var/lib/dhcpv6/client6.leasesXXXXXX; this file is used to request the same addresses and prefixes from the DHCPv6 server. Each dhcp6c client has a client DHCP Unique Identifier (DUID); the DUID file is saved as /var/lib/dhcpv6/dhcp6c_duid. The dhcp6c client configuration is defined in /etc/dhcp6c.conf.

Options

-c pathspec
Specifies

the configuration file for dhcp6c

-d
Enables dhcp6c to print debugging messages.
-D
Enables dhcp6c to print verbose debugging messages.
-f
Enables dhcp6c to work as a foreground application. This option is helpful for debugging.
-I
Allows dhcp6c to request network information only. Do not configure the interface.
-r all | <addresses...>
Allows dhcp6c to release the addresses specified. This option is used only when releasing addresses explicitly.
-R <addresses...>
Allows dhcp6c to request the specified addresses.

Files

/etc/dhcp6c.conf
Contains DHCPv6 client configuration information.
/var/lib/dhcpv6/dhcp6c_duid
Contains DHCPv6 client DUID.
/var/lib/dhcpv6/client6_leasesXXXXXX
Contains DHCPv6 client assigned IPv6 addresses and prefixes.

Errors

Check /var/log/messages if there are errors.

 

转载于:https://www.cnblogs.com/kungfupanda/archive/2013/03/12/2955591.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值