Operating System - HP-UX
1756552 Members
2913 Online
108848 Solutions
New Discussion юеВ

HP 11 Not booting no /sbin/sh

 
Joe Humphries
Occasional Advisor

HP 11 Not booting no /sbin/sh

Help...

Booting normally gets to CDE logon screen, then you cannot login.. (sh doesn't appear to work)

So I rebooted in single mode

IPL>boot -is ....

and it cannot find /sbin/sh

So, I booted of the HP bootdisk, did recovery, and chroot_lvm disk to mount the boot disk under /ROOT, I can then see my FS, and guess what /sbin exists and so does sh etc.. obviously /usr etc is not mounted...

So it appears to be then sbin hasn't been modified since 1999!! yet the system doesn't start.. Any ideas...
14 REPLIES 14
Patrick Wallek
Honored Contributor

Re: HP 11 Not booting no /sbin/sh

What are the permissions on the /sbin directory and on the /sbin/sh file?

They should be:

# ll -d /sbin
dr-xr-xr-x 13 bin bin 3072 Oct 4 14:56 /sbin

# ll /sbin/sh
-r-xr-xr-x 1 bin bin 401408 Nov 3 2000 /sbin/sh
Joe Humphries
Occasional Advisor

Re: HP 11 Not booting no /sbin/sh

They are correct..

Thats whats weird..
Patrick Wallek
Honored Contributor

Re: HP 11 Not booting no /sbin/sh

I assume you passwd entry for root is correct? It is using the /sbin/sh shell?

Have you tried running a 'pwck' to see if there are any problems with root's entry in the passwd file?
Roger Baptiste
Honored Contributor

Re: HP 11 Not booting no /sbin/sh

Joe,

Since you are able to
boot the box and get till
the CDE prompt,but could
not login, the problem could
be with the shell entry in
the /etc/password file.
Have a loot at it and make
sure they are correct.
Also, try logging with different user id to see
whether it works.
Check the size of the /sbin/sh
file to see whether it got changed.

HTH
raj
Take it easy.
Joe Humphries
Occasional Advisor

Re: HP 11 Not booting no /sbin/sh

yes the passwd is correct.. no I haven;t tryed a pwck..

it looks like the sh in /sbin/ is correct as I can run it from the recovery console..

I have looked at the passwd file and it seems correct.

When running in single user mode it doesn't start which kind of indicates the passwd is not the problem..

it just keeps looping round the screen. the only error message is:

/etc/profile[133]: ksh: not found

yet that also exists.. I seems to have some read problems on the root mount..

p.s cheers for the help so far lads...

James Beamish-White
Trusted Contributor

Re: HP 11 Not booting no /sbin/sh

Hiya,

I have had a problem like this before. If the root sheel is ksh, the system WILL NOT BOOT. I dunno why. So a simple attempt to make things easier by making the root shell ksh can stuff your system up. Try changing the root shell to /sbin/sh and see what happens :-)

James
GARDENOFEDEN> create light
James Beamish-White
Trusted Contributor

Re: HP 11 Not booting no /sbin/sh

Ooops, reread the posting and noticed my reply isn't quite correct. Check the root .profile and the /etc/profile to see if it tries to start ksh. If the profile is trying to run ksh, while /usr isn't mounted due to beig in single user mode, that might be the problem.

James
GARDENOFEDEN> create light
Roger Baptiste
Honored Contributor

Re: HP 11 Not booting no /sbin/sh

Joe,

Seems that you are using
ksh either for your root account or in a startup
script in the profile.

If so, change the shell
to point to /sbin/sh !
Also edit the /etc/profile
file and see what the 133 line
is referring to.
Better yet, do
cp /etc/profile /etc/profile.orig
cp /usr/newconfig/etc/profile /etc/profile
and start the system .

(for this you would need to
mount /usr manually in the
single user mode).

In all likelihood, you
are accesing the wrong shell
somewhere in your startup
scripts or user id.

-Raj
Take it easy.
Sanjay_6
Honored Contributor

Re: HP 11 Not booting no /sbin/sh

Hi Joe,

this might help.

quote //

if you do a sum on /sbin/sh, you will find your other machine different data (files) on it. The easiest way to correct this situation is to ftp /sbin/sh from your other machine the problem machine. Then, everything should work fine.

//unquote

hope this helps.

thanks