- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Xwindow Problem - Can't open display: %s
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2014 04:36 AM
08-06-2014 04:36 AM
Hi All,
I'm facing an error while trying to get a HP-UX GUI using Xwindow. here are the details:
system : HPVM with HP-UX 11i v3
xclient : XMing
I've started the xfs deamon and set the display vairable as well
# ps -ef|grep -i x11
root 7100 1 0 04:03:58 ? 0:00 /usr/bin/X11/xfs -config /etc/X11/fs/config -port 7000 -daemon -quiet_if_addrinuse
# env|grep -i dis
DISPLAY=localhost:0.0
# xterm
xterm Xt error: Can't open display: %s
I don't what's wrong and how to fix it. Any help is really appreciaed.
Thanks,
Ashutosh Singh
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2014 06:01 AM
08-06-2014 06:01 AM
Re: Xwindow Problem - Can't open display: %s
Try "mobaxterm" (X over ssh), works perfectly. Google it!
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-06-2014 08:57 AM
08-06-2014 08:57 AM
Re: Xwindow Problem - Can't open display: %s
>DISPLAY=localhost:0.0
>Maybe the variable is wrong.
That would be my thought too. I would have thought that is the location of the DISPLAY ON the server, not the PC.
When I use putty and ssh and xming, I get a variable like: localhost:##:0
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-07-2014 04:31 AM - edited 08-08-2014 04:16 AM
08-07-2014 04:31 AM - edited 08-08-2014 04:16 AM
Re: Xwindow Problem - Can't open display: %s
>> DISPLAY=localhost:0.0
Unless you are using a display, mouse and keyboard connected to the computer, this is not a valid setting. If you use Linux a lot (where the KVM is part of the computer), it is easy to make this mistake. The DISPLAY variable is used to tell Xwindows where to route the graphics. Since you mentioned Xming (which works quite well), you are probably using a PC as your display device. Therefore, the setting for DISPLAY must point to your PC, not the localhost:0.0 on the HP-UX system.
To set the DISPLAY variable automatically, run this command:
export DISPLAY=$(who -muR | awk '{print $NF}'):0.0"
What this does is (from the HP-UX side) to identify your PC's connection and set that address as the DISPLAY variable.
Additionally, Xwindows is considered to be a network security risk so if your Xwindow data is flowing across routers, your company may block port 7000 which will prevent Xwindows from working except within a local subnet.
Also, Xwindows is only useful when displaying graphic images. If you are using it to login to HP-UX with xterm, that is a very cumbersome and network-intensive way to communicate. Download PuTTY and you'll eliminate all the issues with Xwindow connectivity.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-07-2014 04:53 AM
08-07-2014 04:53 AM
Re: Xwindow Problem - Can't open display: %s
As said, if you really need X, consider to tunnel via ssh.
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-07-2014 05:13 AM
08-07-2014 05:13 AM
Re: Xwindow Problem - Can't open display: %s
Thank you all for your valuable inputs.
I tried changing the display variable, but the problem presisted. I googled the problem and there were some directions reagrding the .Xauthority file being corrupt. I'm not sure what this file does and how to correct it. Maybe, if you guys have any ideas about the same, please let me know.
I'll try mobaxterm to see if it works for me.
And I know Xwindows is quite cumbersome, but I need to configure bastille in my environment and that can be only setup using GUI. So, I kind of need te GUI for the time being.
Thanks,
Ashutosh Singh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-07-2014 05:15 AM - edited 08-07-2014 05:26 AM
08-07-2014 05:15 AM - edited 08-07-2014 05:26 AM
SolutionYes, bastille need it ...
Run mobaxterm on your pc, do ssh (sessions icon upper left corner, or just type ssh from the shell) to the server and start bastille.
This is cygwin in a single executable file, cool.
Hope this helps!
Regards
Torsten.
__________________________________________________
There are only 10 types of people in the world -
those who understand binary, and those who don't.
__________________________________________________
No support by private messages. Please ask the forum!
If you feel this was helpful please click the KUDOS! thumb below!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-07-2014 11:57 AM
08-07-2014 11:57 AM
Re: Xwindow Problem - Can't open display: %s
>To set the DISPLAY variable automatically, run this command:
You have too many "$(":
export DISPLAY=$(who -muR | awk '{print $NF}'):0.0"
(You can edit your post by Post Options > Edit Reply.)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2014 04:16 AM - edited 08-08-2014 04:17 AM
08-08-2014 04:16 AM - edited 08-08-2014 04:17 AM
Re: Xwindow Problem - Can't open display: %s
>> You have too many "$(":
Yep. I fixed the line. Thanks.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-08-2014 03:14 PM
08-08-2014 03:14 PM
Re: Xwindow Problem - Can't open display: %s
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-20-2014 05:30 AM
08-20-2014 05:30 AM
Re: Xwindow Problem - Can't open display: %s
Though mobaxterm worked like a charm.
Thanks to all for your valuable inputs.