diff options
-rw-r--r-- | sos/report/plugins/sapnw.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sos/report/plugins/sapnw.py b/sos/report/plugins/sapnw.py index e32afcdd..00984d5b 100644 --- a/sos/report/plugins/sapnw.py +++ b/sos/report/plugins/sapnw.py @@ -129,6 +129,12 @@ class sapnw(Plugin, RedHatPlugin): self.collect_list_dbs() # run sapconf in check mode - self.add_cmd_output("sapconf -n", suggest_filename="sapconf_checkmode") + # + # since the command creates a limits.d file on its own, + # we must predicate it by presence of the file + if os.path.exists('/etc/security/limits.d/99-sap-limits.conf') \ + or self.get_option('allow_system_changes'): + self.add_cmd_output("sapconf -n", + suggest_filename="sapconf_checkmode") # vim: et ts=4 sw=4 |