-
Bug
-
Resolution: Unresolved
-
Normal
-
None
-
rhel-8.9.0
-
None
-
sos-4.7.1-1.el8
-
Normal
-
sst_cee_supportability
-
False
-
-
Red Hat Enterprise Linux
What were you trying to do that didn't work?
The `sapnw` plugin executes `sapconf -n` which should not be executed while gathering sosreport.
As per the previous BZ # 1914102, the execution of `sapconf` resulted in modification of `/etc/security/limits.d/99-sap-limits.conf` and hence additional checks were added to avoid the execution.
Since the limits.conf file configuration is necessary for SAP setup, the condition check may result in a success & the execution of `sapconf -n` command resulting in change of limits.conf file.
As documented in SAP Note 2772999 - Red Hat Enterprise Linux 8.x: Installation and Configuration (https://me.sap.com/notes/2772999) the file `/etc/security/limits.d/99-sap-limits.conf` is required for a properly configured RHEL 8 system for running SAP software (please refer the section "Configuring Process Resource Limits".
For the same reason, the following code section can be removed so to avoid any possible execution of `sapconf -n` while gathering sosreport in RHEL 8:
- cat -n /usr/lib/python3.6/site-packages/sos/report/plugins/sapnw.py
…
133 # run sapconf in check mode
134 #
135 # since the command creates a limits.d file on its own,
136 # we must predicate it by presence of the file
137 if self.path_exists('/etc/security/limits.d/99-sap-limits.conf') \
138 or self.get_option('allow_system_changes'):
139 self.add_cmd_output("sapconf -n",
140 suggest_filename="sapconf_checkmode")
Please provide the package NVR for which bug is seen:
sos-4.6.1-1.el8.noarch
Expected results
The `sapconf -n` should not be executed during capturing of sosreport as it has been replaced by RHEL System Roles for SAP in RHEL 8.
Actual results
The `sapconf -n` is executed during capture of sosreport.
sos_reports/sos.txt:
sapnw
- commands executed:
* /usr/sap/hostctrl/exe/saphostctrl -function ListDatabases
* /usr/sap/hostctrl/exe/saphostctrl -function ListInstances
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 00 -function GetProcessList
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 00 -function GetVersionInfo
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 10 -function GetProcessList
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 10 -function GetVersionInfo
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 20 -function GetProcessList
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sapcontrol -nr 20 -function GetVersionInfo
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sappfpar all pf=/usr/sap/SID/SYS/profile/SID_D10_sal01
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sappfpar all pf=/usr/sap/SID/SYS/profile/SID_D20_sal01
* env -i LD_LIBRARY_PATH=/usr/sap/SID/SYS/exe/run /usr/sap/SID/SYS/exe/uc/linuxx86_64/sappfpar all pf=/usr/sap/SID/SYS/profile/SID_DEV00_sal01
* sapconf -n <<== Here
* su - sidadm -c "sapcontrol -nr 00 -function GetEnvironment"
* su - sidadm -c "sapcontrol -nr 10 -function GetEnvironment"
* su - sidadm -c "sapcontrol -nr 20 -function GetEnvironment"
- files copied:
* /usr/sap/SID/DEV00/work/dev_w0