Operating System - HP-UX
1753708 Members
4906 Online
108799 Solutions
New Discussion юеВ

Re: Set default X server display for SMH tools?

 
richtl
Advisor

Set default X server display for SMH tools?

I connect to SMH on all my HP-UX hosts from a web browser on a Linux desktop. Most of the SMH tools, such as "Tools┬╗ Accounts For Users And Groups┬╗ Users" require that I manually enter the X display value (e.g. 192.168.0.13:0.0) every time I access the tool. Is there a way to set the default value so I only need to do this once?

Thanks.
6 REPLIES 6
Dennis Handly
Acclaimed Contributor

Re: Set default X server display for SMH tools?

You could export DISPLAY in your .profile.
richtl
Advisor

Re: Set default X server display for SMH tools?

Thanks Dennis--good idea. I made the change and ran xclock to confirm it worked. Then connected to SMH to see if it sources my profile when I log in.

Unfortunately, it doesn't appear to. I'm still getting a strange IP address that I don't recognize as belonging to the system.
Steven Schweda
Honored Contributor

Re: Set default X server display for SMH tools?

I normally connect to my HP-UX systems
remotely (rsh), and my shell start-up stuff
automatically sets DISPLAY to point back to
my (VMS) workstation. If this didn't work
right, then all kings of things (like, say,
"gvim", or Web browsers (including SMH
itself)) wouldn't work right.

When I run SMH, it always ignores my DISPLAY
value, and uses something like the IP address
of the HP-UX system itself (+":0.0"),
instead. For a long time, I thought that
SMH itself was hanging every time I tried to
do one of those tasks which spawns a SAM-like
(X-Motif?) tool, because those were always
going to the wrong display, and no one was
home there. Eventually, I caught on, and
started manually setting the DISPLAY in the
box in the SMH form itself. Note: I can see
the browser window with SMH in it, but SMH
seems to guess (badly) about which display to
use, instead of simply inheriting the current
DISPLAY setting.

I was hoping that someone would provide a
good answer in this thread, because this
annoyance has been bothering me for a while.
Merely having DISPLAY set properly before
running SMH does _not_ seem to do the job.

Where _does_ SMH get that display value?
richtl
Advisor

Re: Set default X server display for SMH tools?

Hah! They've hardcoded the default X display value. All my servers are 192.168.0.13:0.0 as well. (I was wondering where my system was getting that IP from.)
Steven Schweda
Honored Contributor

Re: Set default X server display for SMH tools?

> Hah! They've hardcoded the default X
> display value. [...]

Perhaps, but why would they have hardcoded
_mine_ to "10.0.0.45:0.0"?

Around here, 10.0.0.45 is the HP-UX system
itself,and the "X/CLI Tool Launch" page in
SMH has "10.0.0.45:0.0" in its "Display" box.

dyi # uname -a
HP-UX dyi B.11.31 U ia64 4235313755 unlimited-user license

dyi # echo $DISPLAY
alp-l.antinode.info:0.0

dyi # nslookup alp-l.antinode.info
[...]
Trying DNS
Name: alp-l.antinode.info
Address: 10.0.0.9

Obviously (and it's even more obvious when
one is sitting in front of 10.0.0.9), the
Web browser made it back to the right
display, but SMH seems to ignore that DISPLAY
value.
richtl
Advisor

Re: Set default X server display for SMH tools?

Curious. I have no idea where the IP address is coming from for mine, but all of my servers show the same IP.