1753867 Members
7446 Online
108809 Solutions
New Discussion юеВ

Re: /bin/sh not found

 
SOLVED
Go to solution
titi chen
Occasional Contributor

/bin/sh not found

Dear all,

My system is HPUX 11.31 with BOE. And I keep receiving /bin/sh not found when the system start up or if I running script...

Where and how do I change/set this default interpreter so it is directed to /usr/bin/sh?

Thanks..
13 REPLIES 13
Ganesan R
Honored Contributor

Re: /bin/sh not found

Hi,

You should modify the script to use /usr/bin/sh instead of /bin/sh

Or you can copy the /bin/sh from some other system if you have.
Best wishes,

Ganesh.
Wim Rombauts
Honored Contributor

Re: /bin/sh not found

I am not familiar with specific changes about the filesystem organization between HP-UX 11i v2 and HP-UX 11i v3, but I think that you may be missing a symbolic link from /bin to /usr/bin.
Is that so ?
And what happens if you create this one (ln -s /usr/bin /bin).
I think that if the link is missing, creating it would certainly solve the issue, and maybe a few future issues also.
avizen9
Esteemed Contributor

Re: /bin/sh not found

first you should verify at /bin/ this file may exist but somehow the group/owner or permission has changed, will get this error. it should have below user /group permission.

-r-xr-xr-x 2 bin bin 491520 Dec 2 2002 sh

if this file doest exist you should identify same version of hpux OS system tar this file there and ftp over not working hpux system, and untar in /bin should be ok

let me know how it goes, thanks,
titi chen
Occasional Contributor

Re: /bin/sh not found

Thanks Ganesan,

Unfortunately i don't have any other system.

And your first suggestion means I should do the script editing each time I get a new script, event downloaded script from HP directed to /usr/bin/sh

Actually I was expecting 1 time and permanent action to solve this..


Regards,
Robert-Jan Goossens
Honored Contributor

Re: /bin/sh not found

Hi,

Run the tlinstall command

# tlinstall

Robert-Jan
titi chen
Occasional Contributor

Re: /bin/sh not found

Hi Wim,

The thing is no such /bin in my current HP UX 11.31 BOE. There's only /usr/bin, all sh, ksh, csh are located here.

And there' no such tlinstall command.


Other suggestion?

Thanks.

Roman Schmidt
Frequent Advisor

Re: /bin/sh not found

hello,

please create a symlink:

ln -s /usr/bin /bin


like this all scripts accessing /bin/sh are reidrected to /usr/bin/sh.
rariasn
Honored Contributor

Re: /bin/sh not found

Hi titi,

lrwxr-xr-t 1 root sys 8 Apr 10 2002 /bin -> /usr/bin

rgs
avizen9
Esteemed Contributor

Re: /bin/sh not found

attached here sh.tar for same version of OS incase if you falied with all suggested options,