ORAchk 12.1.0.2.7 problems running as root with default shell as /sbin/sh
We run orachk from the root user using the orachk -a option. This worked fine in 12.1.0.2.6. In orachk 12.1.0.2.7 this fails with the following:
There are prompts in /etc/profile on 'xxxxxxx' for 'root' user which will cause issues in orachk successful execution. Please remove or comment all prompts in /etc/profile of root user and run again.
Looking at the debug report, the command it is failing on line 44209:
su root -c 'if [ -e /etc/profile ]; then (. /etc/profile >/dev/null 2>&1); fi'
Having spent some time looking at this, it appears that the -e option for testing is not available in sh. Our root user defaults to /sbin/sh which we don't want to change.