diff options
author | Lennart Poettering <lennart@poettering.net> | 2016-06-03 17:57:04 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2016-06-03 17:57:04 +0200 |
commit | de4503c8d9ea9799437695c988296cc532530a14 (patch) | |
tree | b1e487c2417199772b685898f1d59cdb2aa70412 /src/network/networkd-link.c | |
parent | 18b9beb199199bc3ae744bbfca162b03bcc79c33 (diff) | |
parent | acac5b2f512e03830df06df3fc30aff28d01d6b3 (diff) |
Merge pull request #3409 from tomty89/update-2
networkd-dhcp6: DHCPv6 starting fixes
Diffstat (limited to 'src/network/networkd-link.c')
-rw-r--r-- | src/network/networkd-link.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/network/networkd-link.c b/src/network/networkd-link.c index 9ac0b47d77..ba4147f875 100644 --- a/src/network/networkd-link.c +++ b/src/network/networkd-link.c @@ -1444,15 +1444,12 @@ static int link_acquire_ipv6_conf(Link *link) { assert(link->dhcp6_client); assert(in_addr_is_link_local(AF_INET6, (const union in_addr_union*)&link->ipv6ll_address) > 0); - log_link_debug(link, "Acquiring DHCPv6 lease"); - - r = sd_dhcp6_client_set_local_address(link->dhcp6_client, &link->ipv6ll_address); - if (r < 0 && r != -EBUSY) - return log_link_warning_errno(link, r, "Could not set IPv6LL address in DHCP client: %m"); - - r = sd_dhcp6_client_start(link->dhcp6_client); + /* start DHCPv6 client in stateless mode */ + r = dhcp6_request_address(link, true); if (r < 0 && r != -EBUSY) return log_link_warning_errno(link, r, "Could not acquire DHCPv6 lease: %m"); + else + log_link_debug(link, "Acquiring DHCPv6 lease"); } if (link_ipv6_accept_ra_enabled(link)) { |