Operating System - HP-UX
1834130 Members
3228 Online
110064 Solutions
New Discussion

problems with maintenance/single user mode

 
David Lewis_1
Advisor

problems with maintenance/single user mode

I have just re-installed an A180 class server with HP-UX 11 32 bit, September 2002 release. However, when I attempt to go to maintenace mode or single user mode the server hangs. The server will boot to run level 3 with no problems. Any ideas?
7 REPLIES 7
John Palmer
Honored Contributor

Re: problems with maintenance/single user mode

How exactly are you trying to get into single user/maintenance mode?

Also what's in the AUTO file on your boot disk?
Run lifcp /dev/dsk/c?d?t?:AUTO -

It's possible that your AUTO file is actually booting from a different disk altogether (though unlikely).

The output from
setboot
lvlnboot -v

would also be useful.

Regards,
John
Bill Hassell
Honored Contributor

Re: problems with maintenance/single user mode

How are you getting to single user mode? Unlike other flavors of Unix, init will never get you there (despite the man page for init and option s/S). In HP-UX, init s or S simply tells init to look att inittab and stop anything that it owns that is not in inittab with an s level.

In the good old days (prior to version 9), shutdown 0 (no -h or -r option) would get you to true single user mode very quickly, bypassing hardware selftests. But somewhere during 9.x and ever since, shutdown became dependent on networking (which makes no sense at all since shutdown usually occurs for abnormal reasons) and can hang. shutdown 0, when it gets you to a shell prompt, will occasionally leave /usr and /var mounted--which is not true single user mode. In true single user mode, NOTHING is mounted (except / and /stand) and there are no processes running except memory management (no networking, no user daemons, etc)

So to get to true single user mode, you must reboot the computer (shutdown -r 0 or if nothing is running, reboot -q), then interrupt the boot process so you can interact with the processor ROMs. Answer YES to boot from primary, and YES to interact with ISL (initial system loader). When you get the ISL prompt, type: hpux -is
and you'll get to true single user mode.

There is a possibility that you have something customized in /etc/profile and/or root's .profile which is causing the hang because the 'something' is broken in single user mode. Or you may have changed root's shell in /etc/passwd. DON'T CHANGE root's SHELL. It must always be /sbin/sh (search the ITRC forums for numerous warnings and the details)


Bill Hassell, sysadmin
David Lewis_1
Advisor

Re: problems with maintenance/single user mode

The problem with the server hanging is when I try to boot to single user / maintenance mode via ISL. After interupting the boot sequence and interacting with ISL I've tried two things 1) hpux -is 2) hpux -lm. Both attempts leave the server hanging, generally once it gets to displaying how much memory is in the system. I have checked the AUTO file and I'm booting off of the correct disk also lvlnboot and setboot look ok. Any ideas?
Carlos Fernandez Riera
Honored Contributor

Re: problems with maintenance/single user mode

If any disk of boot disks ahave become unavailable the correct sintax to boot is:

hpux -lq -is

Any other combination , such as hpux -is -lq, will cause a reboot. based on my experience.

unsupported

Re: problems with maintenance/single user mode

What is roots shell in /etc/passwd? It *must* be /sbin/sh

HTH

Duncan

I am an HPE Employee
Accept or Kudo
Dietmar Konermann
Honored Contributor

Re: problems with maintenance/single user mode

Looks like your system gets stuck exactly at that point where init(1M) takes control.

Pls check the configuration of the console device. They should look like:


# ll /dev/console /dev/sys*
crw--w--w- 1 root tty 0 0x000000 Jan 29 17:56 /dev/console
crw--w--w- 2 bin bin 0 0x000000 Feb 15 2001 /dev/syscon
crw--w--w- 2 bin bin 0 0x000000 Feb 15 2001 /dev/systty

Then remove the file /etc/ioctl.syscon, before trying the next reboot.

Best regards...
Dietmar.
"Logic is the beginning of wisdom; not the end." -- Spock (Star Trek VI: The Undiscovered Country)
David Lewis_1
Advisor

Re: problems with maintenance/single user mode

It looks as though I had a corrupt ioctl.syscon file. Copied file out and re-booted then booted into maintenance mode with no problems. Thanks all for your help.