Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sap_facts.sh - ps print only executable with path
The output of "ps -ef" not also includes the command but also the process age and process arguments. Both can have digits in its string which may interfere when grepping for an instance number like 00 or 01. To fix this, let ps print only the executable with its path. Example: ps with default output - 2 lines match where only 1st line should match /usr/sap/A22/D01/exe/sapstartsrv pf=/usr/sap/A22/SYS/profile/A22_D01_sapa22u01 -D -u a22adm /usr/sap/A22/ASCS02/exe/sapstartsrv pf=/usr/sap/A22/SYS/profile/A22_ASCS02_sapa22u01 -D -u a22adm Example: ps with custom layout, only one line matches as expected /usr/sap/A22/D01/exe/sapstartsrv
- Loading branch information