ORACHK execution fails with message " Badly placed ()'s. There are prompts in /etc/profile for 'oracle' user which will cause issues in orachk successful execution" (Doc ID 2268078.1)

Last updated on MAY 23, 2017

Applies to:

System Utilities - Version 12.1.2.8.0 and later
Information in this document applies to any platform.

Symptoms

On : 12.1.2.8.3 version, Orachk Tool

1. orachk (As root user)

Checking for prompts for oracle user on all nodes...

Badly placed ()'s.

There are prompts in /etc/profile on 'pgsapecd' for 'oracle' user which will cause issues in orachk successful execution. Please remove or comment all prompts in /etc/profile of oracle user and run again.

 2. Shell details

root@pgsapecpd3 ~]# ps -p $$
PID TTY TIME CMD
181537 pts/0 00:00:00 bash            
[root@pgsapecpd3 ~]# $SHELL --version
GNU bash, version 4.1.2(1)-release (x86_64-redhat-linux-gnu)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
[root@pgsapecpd3 ~]#

[oracle@pgsapecpd3 ~]$ ps -p $$
PID TTY TIME CMD
182797 pts/0 00:00:00 csh
[oracle@pgsapecpd3 ~]$ $SHELL --version
tcsh 6.17.00 (Astron) 2009-07-10 (x86_64-unknown-linux) options wide,nls,dl,al,kan,sm,rh,color,filec                <<<<<<< oracle user default shell is TCSH
[oracle@pgsapecpd3 ~]$

 3. orachk -debug

44891: + p_returncode=0
44892: + grep -ic '^oracle:' /etc/passwd
44892: + sed 's/ //g'
44892: + [[ 1 -ne 0 ]]
44893: + print_PMSG=/etc/profile
44894: + su oracle -c 'if [ -e /etc/profile ]; then (. /etc/profile >/dev/null 2>&1); fi'
Badly placed ()'s.
44894: + p_returncode=
44895: + echo 1
44895: + p_returncode=1
44896: + [[ -n 1 ]]
44896: + [[ 1 -eq 0 ]]
44902: + P_USR_STATUS_LOCAL=:oracle
44905: + [[ -n 1 ]]
44905: + [[ 1 -ne 0 ]]
44906: + echo -e '\033[1;31;40m\nThere are prompts in /etc/profile on '\''pgsapecd'\'' for '\''oracle'\'' user which will cause issues in orachk successful execution. Please remove or comment all prompts in /etc/profile of oracle user and run again.\n\n\033[0m'

There are prompts in /etc/profile on 'pgsapecd' for 'oracle' user which will cause issues in orachk successful execution. Please remove or comment all prompts in /etc/profile of oracle user and run again.


44907: + exit 1
1: + cleanup
23990: + [[ -n '' ]]

 

Changes

 None

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms