Operating System - HP-UX
1751913 Members
5150 Online
108783 Solutions
New Discussion юеВ

Re: ${HOME:-.}/.profile[22]: test: argument expected

 
Bill Hassell
Honored Contributor

Re: ${HOME:-.}/.profile[22]: test: argument expected

>> it never starts any services

Do you mean that the startup scripts do not run? What does /etc/rc.log show? Did you recently cd to the /etc/rc.config.d directory and edit some files? Check like this:

ls -lart /etc/rc.config.d | tail

There can never be any junk files in this directory or your system may be unable to boot into a normal mode.


Bill Hassell, sysadmin
Ravi S. Banda
Regular Advisor

Re: ${HOME:-.}/.profile[22]: test: argument expected

Since the last reboot (21-Apr-2010), I saw a file pointer under /sbin/rc3.d

lrwxrwxr-x 1 root sys 23 May 14 08:05 K98gcstartup -> /sbin//init.d/gcstartup
lrwxrwxr-x 1 root sys 23 May 14 08:05 S98gcstartup -> /sbin//init.d/gcstartup

I went to /sbin/init.d; moved the file gcstartup to /tmp directory.

gcstartup is associated with Oracle├в s crs/gc setup, created by Oracle, not by me.

Rebooted the server ├в everything seems to be fine.
I├в m still thinking whether I should give it a try by moving gcstartup file in /sbin/init.d directory ├в and see if it fails again to reboot.

Our ignite backups are run/overwritten once a day ├в so, the backups would have been overwritten onto the DDS tape ├в because when the server was up and running, nothing seemed wrong.

Thanks!
Ravi.
Patrick Wallek
Honored Contributor

Re: ${HOME:-.}/.profile[22]: test: argument expected

What happens now if you run the 'gcstartup' script manually?
Ravi S. Banda
Regular Advisor

Re: ${HOME:-.}/.profile[22]: test: argument expected



good point!

gcstartup contains the line at the end (not modified by me) to startup Oracle Agent 10g:

if [ -f /apps/tstc/oracle/agent10g/install/unix/scripts/agentstup ]; then
/bin/su - oracle -c "/apps/tstc/oracle/agent10g/install/unix/scripts/agentstup $1"
fi

gcstartup, when run, prompts me to choose the database instance - because we have multiple database instances for the UNIX user 'oracle'; it validates which option we choose - if we don't choose any option or press enter, it would say:

${HOME:-.}/.profile[22]: test: argument expected
${HOME:-.}/.profile[25]: test: argument expected
${HOME:-.}/.profile[29]: test: argument expected
${HOME:-.}/.profile[32]: test: argument expected
${HOME:-.}/.profile[35]: test: argument expected
${HOME:-.}/.profile[38]: test: argument expected
${HOME:-.}/.profile[41]: test: argument expected
${HOME:-.}/.profile[44]: test: argument expected
${HOME:-.}/.profile[47]: Q: unknown test operator

well, that explains it!!!


Thanks!
Ravi.
Ravi S. Banda
Regular Advisor

Re: ${HOME:-.}/.profile[22]: test: argument expected

i will assign the points and close this thread.
Ravi S. Banda
Regular Advisor

Re: ${HOME:-.}/.profile[22]: test: argument expected

Points assigned!
Dennis Handly
Acclaimed Contributor

Re: ${HOME:-.}/.profile[22]: test: argument expected

>I went to /sbin/init.d; moved the file gcstartup to /tmp directory.

In general, what's in there is ignored and it is just a place to hold all of the rc scripts. It is the presence of the symlinks in /sbin/rc?.d/ that do the actual work.