From c576290a354d07b1507bda1c36e81c8d6d481f6d Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Fri, 9 Aug 2019 18:20:11 +0200 Subject: pkg/host: fix linux netdevices detection We don't use ip command for netdevices and tun setup. --- pkg/host/host_linux.go | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) (limited to 'pkg/host/host_linux.go') diff --git a/pkg/host/host_linux.go b/pkg/host/host_linux.go index 54a4f093c..25da4b016 100644 --- a/pkg/host/host_linux.go +++ b/pkg/host/host_linux.go @@ -8,7 +8,6 @@ import ( "fmt" "io/ioutil" "os" - "os/exec" "regexp" "runtime" "strconv" @@ -395,7 +394,7 @@ func init() { checkFeature[FeatureFaultInjection] = checkFaultInjection checkFeature[FeatureLeakChecking] = checkLeakChecking checkFeature[FeatureNetworkInjection] = checkNetworkInjection - checkFeature[FeatureNetworkDevices] = checkNetworkDevices + checkFeature[FeatureNetworkDevices] = unconditionallyEnabled } func checkCoverage() string { @@ -541,7 +540,7 @@ func checkNetworkInjection() string { if err := osutil.IsAccessible("/dev/net/tun"); err != nil { return err.Error() } - return checkNetworkDevices() + return "" } func checkUSBInjection() string { @@ -551,13 +550,6 @@ func checkUSBInjection() string { return "" } -func checkNetworkDevices() string { - if _, err := exec.LookPath("ip"); err != nil { - return "ip command is not found" - } - return "" -} - func checkDebugFS() string { if err := osutil.IsAccessible("/sys/kernel/debug"); err != nil { return "debugfs is not enabled or not mounted" -- cgit mrf-deployment