From 2958b9d48940c27ae29b4fb5a6900ac178519a89 Mon Sep 17 00:00:00 2001 From: Vincent Bernat Date: Thu, 19 May 2016 23:36:24 +0200 Subject: [PATCH] interfaces/linux: make veth special veth is always a physical interface. However, it may be hard to detect because when they are created, lower interface for the first one is none and lower interface for the second one is the first one. Hence, no loop detected, hence the second one is not considered as a physical interface. This is madness, just whitelist "veth". --- NEWS | 1 + src/daemon/interfaces-linux.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/NEWS b/NEWS index 8da7bcd5..ee2fa0d7 100644 --- a/NEWS +++ b/NEWS @@ -4,6 +4,7 @@ lldpd (0.9.3) + Always log to stderr (even in addition to syslog). * Fix: + `lldpcli -f {xml,json} watch` should work now. + + Consider `veth` interfaces as physical interfaces. lldpd (0.9.2) * Change: diff --git a/src/daemon/interfaces-linux.c b/src/daemon/interfaces-linux.c index 340b9e8d..6ac428f8 100644 --- a/src/daemon/interfaces-linux.c +++ b/src/daemon/interfaces-linux.c @@ -734,7 +734,7 @@ iflinux_add_physical(struct lldpd *cfg, } /* If the interface is linked to another one, skip it too. */ - if (iface->lower) { + if (iface->lower && (!iface->driver || strcmp(iface->driver, "veth"))) { log_debug("interfaces", "skip %s: there is a lower interface (%s)", iface->name, iface->lower->name); continue; -- 2.39.5