Operating System - HP-UX
1745793 Members
3666 Online
108722 Solutions
New Discussion

UNIX95 not fully working in a system container

 
malc_p
Occasional Advisor

UNIX95 not fully working in a system container

Hi all

Here's an interesting one...

 

We're running 11.11 system containers under an 11.31 Itanium host, and have successfuly converted our system to run on it; but one thing (among several...) that isn't working the same is using UNIX95 to get a hierarchical 'ps' listing, i,e,

 

UNIX95= ps -xHfu<user>

 

gives us no output (where 'ps -xfu<user>' does but with no hierarchy shown)

 

We can use it on the host, no problem, but we do some process management on the containers that it came in very useful for before we virtualised, and now it doesn't work. Any ideas please?

Thanks

11 REPLIES 11
Dennis Handly
Acclaimed Contributor

Re: UNIX95= ps not fully working in a system container

>UNIX95= ps -xHfu <user>

 

Do you have an alias for ps(1)?  Try:

UNIX95= \ps -xHfu <user>

malc_p
Occasional Advisor

Re: UNIX95= ps not fully working in a system container

No, ps is /usr/bin/ps (I also checked using the fully qualified pathname and get the same result) so not an alias; all we get is:

 

dba:>UNIX95= ps -Hxfudba                            
UID        PID  PPID  C    STIME TTY          TIME CMD                         
dba:>

 

...whereas 'ps-xfudba' gives a whole slew of processes (as expected)

 

NB we're running ksh; we get the same result in Bourne shell

 

 

Dennis Handly
Acclaimed Contributor

Re: UNIX95= ps not fully working in a system container

>UNIX95= ps -Hxfudba                            

Have you tried tusc on it?

 

>we get the same result in Bourne shell

 

There shouldn't be any Bourne shells, did you mean Posix?  /usr/bin/sh is Posix.

malc_p
Occasional Advisor

Re: UNIX95= ps not fully working in a system container

No, I meant in /bin/sh, which is Bourne.

 

It seems all the XPG4-only options fail, not just H.

 

 

Patrick Wallek
Honored Contributor

Re: UNIX95= ps not fully working in a system container

>>No, I meant in /bin/sh, which is Bourne.

 

Actually, it's not.  /bin/sh and /sbin/sh are POSIX shells, NOT bourne shells.

 

From 'man sh':

 

 Remarks
      The POSIX .2 standard requires that, on a POSIX-compliant system,
      executing the command sh activates the POSIX shell (located in file
      /usr/bin/sh on HP-UX systems), and executing the command man sh
      produces an on-line manual entry that displays the syntax of the POSIX
      shell command-line.

 

If I recall correctly the Bourne shell is actually in /usr/old/bin/sh.

 

 

 

 

 

 

Dennis Handly
Acclaimed Contributor

Re: UNIX95= ps not fully working in a system container

>If I recall correctly the Bourne shell is actually in /usr/old/bin/sh.

 

Yes it's there for 11.11.  For 11.31, I don't see it there or in /usr/old/usr/bin/.

 

And "UNIX95= ps -Hxfu <user>" works fine on my 11.11 system.

malc_p
Occasional Advisor

Re: UNIX95= ps not fully working in a system container

Whatever! Bourne, shmourne.

 

The issue remains that ps -H (with UNIX95 set) worked fine on our old system on an HP9000 running 11.11 and now we're virtualised, ps -H doesn't work any more.

 

Any clues as to why/where I can look please?

 

Thanks

Dennis Handly
Acclaimed Contributor

Re: UNIX95= ps not fully working in a system container

>Any clues as to why/where I can look please?

 

Well, you can try HPSC.

But tusc is your friend.  I suppose I could take my 11.11 ps(1) and run on 11.31 and see what happens.

Bill Hassell
Honored Contributor

Re: UNIX95 not fully working in a system container

I can confirm that on an Itanium box, running a container with 11.11 and another running 10.20, both fail to report -H correctly.

 

On 11.11:

 

# UNIX95=1 ps -eH
  PID TTY          TIME CMD
25675 ?           00:00 autofskd_12

# ps -e
  PID TTY          TIME CMD
25661 ?           00:00 nfsmapid
25791 ?           00:00 httpd
28612 ?           00:00 sshd:
25488 ?           00:00 srp_init
25681 ?           00:00 inetd
25725 ?           00:00 cron
25655 ?           00:00 nfs4cbd
25587 ?           00:00 sshd
28614 pts/0       00:00 -sh
25792 ?           00:00 httpd
25597 ?           00:00 rpcbind
25721 ?           00:00 lpsched
25812 ?           00:02 prngd
25793 ?           00:00 httpd
25760 ?           00:04 nmbd
25728 ?           00:00 swagentd
25789 ?           00:02 httpd
25576 ?           00:00 syslogd
25763 ?           00:00 smbd
25675 ?           00:00 autofskd_12
25788 ?           00:00 smbd
25628 ?           00:00 rpc.statd
25634 ?           00:00 rpc.lockd
25673 ?           00:06 automountd
28930 pts/0       00:00 ps

 

 

On 10.20:

# UNIX95=1 ps -eH
  PID TTY          TIME CMD
 5981 ?        00:00:00 nfssrp_kdaemon
 5994 ?        00:00:00 autofskd_13

# ps -e
  PID TTY          TIME CMD
 5951 ?        00:00:00 rpc.lockd
 5998 ?        00:00:00 inetd
 5945 ?        00:00:00 rpc.statd
 6054 ?        00:00:00 sh
28945 pts/ta   00:00:00 -sh
 5978 ?        00:00:00 nfsmapid
29022 pts/ta   00:00:00 ps
 7737 ?        00:00:00 sshd
 6043 ?        00:00:00 cron
 5981 ?        00:00:00 nfssrp_kdaemon
 5972 ?        00:00:00 nfs4cbd
 5932 ?        00:00:00 rpcbind
 5992 ?        00:00:05 automountd
 5920 ?        00:00:00 syslogd
 5850 ?        00:00:00 srp_init
 5994 ?        00:00:00 autofskd_13
 6306 ?        00:00:00 dtlogin
 6015 ?        00:00:00 sendmail:
 6046 ?        00:00:00 swagentd
28944 pts/ta   00:00:00 telnetd

 

Looks like a feature -- haven't tried 11.23 in a container yet.

 

 



Bill Hassell, sysadmin