aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sos/plugins/networking.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/sos/plugins/networking.py b/sos/plugins/networking.py
index bb930ad7..53f85ad4 100644
--- a/sos/plugins/networking.py
+++ b/sos/plugins/networking.py
@@ -191,10 +191,16 @@ class Networking(Plugin):
"biosdevname -d",
"tc -s qdisc show",
"ip -s macsec show",
- "iptables -vnxL",
- "ip6tables -vnxL"
])
+ # When iptables is called it will load the modules
+ # iptables and iptables_filter if they are not loaded.
+ # The same goes for ipv6.
+ if self.check_ext_prog("grep -q iptable_filter /proc/modules"):
+ self.add_cmd_output("iptables -vnxL")
+ if self.check_ext_prog("grep -q ip6table_filter /proc/modules"):
+ self.add_cmd_output("ip6tables -vnxL")
+
# There are some incompatible changes in nmcli since
# the release of NetworkManager >= 0.9.9. In addition,
# NetworkManager >= 0.9.9 will use the long names of