Operating System - HP-UX
1833772 Members
2396 Online
110063 Solutions
New Discussion

Signing onto the package or the node

 
Ronald Schwartz_1
Frequent Advisor

Signing onto the package or the node

Our SG environment has a staging database on the alternate node. The users environment needs to be set up based on where they are connecting, node or package. Is there a way to trace the users to the package abosed to those signed onto the node? Executing hostname always shows the node name never the package.
Thanks in advance.
Ron
5 REPLIES 5
G. Vrijhoeven
Honored Contributor

Re: Signing onto the package or the node

Hi Ron,

Once a user is logged into the package hostname will always show the node ip-adress not the package. Our user policiy is users that only need to access one package get a package homedir. Users that access multiple package ( Oracle) get NFS home dirs.
May be this will help, or may be s.o. else knows an other workaround.

HTH,

Gideon
Rita C Workman
Honored Contributor

Re: Signing onto the package or the node

Well this ain't pretty....but....

you could do a netstat -an

of course this will show you everything, but if you knew the users IP you could grep for that, then you would see who is connected to the direct IP of the box and who is connected via the pkg address.

Anybody want to try and script for this ...

Rgrds,
Rita
Ronald Schwartz_1
Frequent Advisor

Re: Signing onto the package or the node

Well I did a little digging and testing and here is what I ended up writing a script. I get the pid that is signing on then use lsof to find out if the pid is signed onto the package. I will use this in the .profile to then go ahead and set the other parameters.

Thanks for your help.
Ron

Attached is a copy of the script.
Rita C Workman
Honored Contributor

Re: Signing onto the package or the node

Great job Ronald !
Only thing...you can't give your self points.

So I shall aware you 10 virtual points for solving it yourself !

Rgrds,
Rita
Ronald Schwartz_1
Frequent Advisor

Re: Signing onto the package or the node

Thank you virtually much.