- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- ${HOME:-.}/.profile[22]: test: argument expected
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:21 PM
тАО11-05-2010 01:21 PM
${HOME:-.}/.profile[22]: test: argument expected
${HOME:-.}/.profile[22]: test: argument expected
${HOME:-.}/.profile[41]: test: argument expected
${HOME:-.}/.profile[44]: test: argument expected
${HOME:-.}/.profile[47]: Q: unknown test operator
${HOME:-.}/.profile[22]: test: argument expected
${HOME:-.}/.profile[25]: test: argument expected
it never starts any services and coming to the (console) login prompt.
I logged in Single-user mode, renamed .profile, copied from /usr/newconfig/etc/profile to $HOME, added only 2 lines, tried everything related to the .profile file, hard-booted by 'resetting', but it still reads the same .profile from somewhere and gives the error on the same exact lines - 22, 25, 29, 32, 35, 38, 41, 44, 47. I don't know where it is even reading it from.
anyone has any ideas?!
Thanks!
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:30 PM
тАО11-05-2010 01:30 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
Posting the errant '.profile' would help, especially since you "added only 2 lines".
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:31 PM
тАО11-05-2010 01:31 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
the current .profile that is located under $HOME (copied from /usr/newconfig/etc/profile) will be attached.
Thanks!
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:31 PM
тАО11-05-2010 01:31 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:37 PM
тАО11-05-2010 01:37 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
in the syslog.log ?
even before you log in ?
after you log in ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:40 PM
тАО11-05-2010 01:40 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
ps: I do have a case open with hp support - but so far, he is clueless!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:43 PM
тАО11-05-2010 01:43 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
check out any entries in there that look to be running some errant script that possible may "su" to some user, that users .profile is probably the one with the issue.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:47 PM
тАО11-05-2010 01:47 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
.profile and /etc/profile are different. Did you attach the proper file?
Typically that error occurs due to sloppy programming and variables not being set, or containing whitespace or "-".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 01:50 PM
тАО11-05-2010 01:50 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
anyways, i made a copy of the original .profile (renamed it as /tmp/.profile.orig), which is attached.
btw, since I have no network to that server (as I am in single-user mode), I am copying and pasting the contents of the file(s) into notepad and attaching here.
thanks!
Ravi.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 02:01 PM
тАО11-05-2010 02:01 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
There are at least three "profile" files in /usr/newconfig. That one is for /etc/profile. There is one for root .profile and another for other users.
>I made a copy of the original .profile, which is attached.
Nothing obvious here. If you keep adding "set -x" to every .profile, you'll eventually find the one that is printing the error. :-)
It would be helpful to at least point out which lines are 22, 25 etc, to see if there is any pattern. They should have "[...]".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 05:27 PM
тАО11-05-2010 05:27 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
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
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 08:31 PM
тАО11-05-2010 08:31 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 08:34 PM
тАО11-05-2010 08:34 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 08:41 PM
тАО11-05-2010 08:41 PM
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 08:50 PM
тАО11-05-2010 08:50 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 08:59 PM
тАО11-05-2010 08:59 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО11-05-2010 09:22 PM
тАО11-05-2010 09:22 PM
Re: ${HOME:-.}/.profile[22]: test: argument expected
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.