From ed1ba2c902624a1bc97d73bc29e64f3fab8658ac Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Sun, 1 Oct 2017 18:16:17 +0800 Subject: [PATCH] apn_start(): Extend error message when setting IPv6 address fails Tell the user about possible causes of failure to set the IPv6 address of the tun device, such as general lack of IPv6 support in the kernel/OS, or the use of /proc/sys/net/ipv6/conf/default/disable_ipv6 Change-Id: I5ff812425ee12b8386bb66521e05c93e825a4506 --- ggsn/ggsn.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ggsn/ggsn.c b/ggsn/ggsn.c index bafcb1b..f8aec9d 100644 --- a/ggsn/ggsn.c +++ b/ggsn/ggsn.c @@ -186,7 +186,8 @@ int apn_start(struct apn_ctx *apn) in46p_ntoa(&apn->v6.cfg.ifconfig_prefix)); if (tun_setaddr(apn->tun.tun, &apn->v6.cfg.ifconfig_prefix.addr, NULL, apn->v6.cfg.ifconfig_prefix.prefixlen)) { - LOGPAPN(LOGL_ERROR, apn, "Failed to set tun IPv6 address %s: %s\n", + LOGPAPN(LOGL_ERROR, apn, "Failed to set tun IPv6 address %s: %s. " + "Ensure you have ipv6 support and not used the disable_ipv6 sysctl?\n", in46p_ntoa(&apn->v6.cfg.ifconfig_prefix), strerror(errno)); apn_stop(apn, false); return -1;