aboutsummaryrefslogtreecommitdiffstats
path: root/package/network/ipv6
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2014-04-05 18:17:25 +0000
committerFelix Fietkau <nbd@openwrt.org>2014-04-05 18:17:25 +0000
commit6d3672b13bebd89a4639bf7f4079c90d81c29d31 (patch)
treebe55b62535555c2bb18c778706f4370f029b8fbe /package/network/ipv6
parentdca014db767b214182755e6b35467a9b8ce05cca (diff)
downloadupstream-6d3672b13bebd89a4639bf7f4079c90d81c29d31.tar.gz
upstream-6d3672b13bebd89a4639bf7f4079c90d81c29d31.tar.bz2
upstream-6d3672b13bebd89a4639bf7f4079c90d81c29d31.zip
odhcp6c: Add renew handler for proto dhcpv6
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com> SVN-Revision: 40386
Diffstat (limited to 'package/network/ipv6')
-rwxr-xr-xpackage/network/ipv6/odhcp6c/files/dhcpv6.sh9
1 files changed, 9 insertions, 0 deletions
diff --git a/package/network/ipv6/odhcp6c/files/dhcpv6.sh b/package/network/ipv6/odhcp6c/files/dhcpv6.sh
index 9b6275e3f9..90a83718e5 100755
--- a/package/network/ipv6/odhcp6c/files/dhcpv6.sh
+++ b/package/network/ipv6/odhcp6c/files/dhcpv6.sh
@@ -5,6 +5,8 @@
init_proto "$@"
proto_dhcpv6_init_config() {
+ renew_handler=1
+
proto_config_add_string 'reqaddress:or("try","force","none")'
proto_config_add_string 'reqprefix:or("auto","no",range(0, 64))'
proto_config_add_string clientid
@@ -67,6 +69,13 @@ proto_dhcpv6_setup() {
$opts $iface
}
+proto_dhcpv6_renew() {
+ local interface="$1"
+ # SIGUSR1 forces odhcp6c to renew its lease
+ local sigusr1="$(kill -l SIGUSR1)"
+ [ -n "$sigusr1" ] && proto_kill_command "$interface" $sigusr1
+}
+
proto_dhcpv6_teardown() {
local interface="$1"
proto_kill_command "$interface"