• Some users have recently had their accounts hijacked. It seems that the now defunct EVGA forums might have compromised your password there and seems many are using the same PW here. We would suggest you UPDATE YOUR PASSWORD and TURN ON 2FA for your account here to further secure it. None of the compromised accounts had 2FA turned on.
    Once you have enabled 2FA, your account will be updated soon to show a badge, letting other members know that you use 2FA to protect your account. This should be beneficial for everyone that uses FSFT.

How does X server work?

Red Squirrel

[H]F Junkie
Joined
Nov 29, 2009
Messages
9,217
I'm trying to troubleshoot an issue at work where an exceed .xs file fails to launch properly and as a result I want to learn more about how X server works so I can better troubleshoot this. Basically the XS file connects to a Telnet server (yes, telnet, I know!) and logs in to that server and then issues a command to load an X application, which then loads on my computer. Everything works up until the point that the X app is suppose to open on my computer.

This is how I think X works, correct me if I'm wrong:

1: A telnet or SSH connection is created to a server, on say, port 23.

2: Regular text communication occurs through this connection, but at the start some commands are issued to establish the X server environment such as the port of my X server. (a packet sniff seems to indicate this is not the case though)

3: When an X app is launched, the X client on the server will connect to my local X server on port 6000(default) and then launch the app.


I tested a working XS file with a packet sniffer and I do indeed get a bunch of traffic coming from the server to my local port 6000 to my X server. But the non working XS file I get nothing.

I spent most of the day troubleshooting my machine with help desk and got nowhere and starting to wonder if it's some weird X/firewall issue. If I SSH into my home server and launch a graphical app it also works properly. Ex: if I run xclock I get it on my work computer. So I know my local X server is working.

If anyone is actually familiar with exceed and can provide some tips I'd be happy as well. We're running Exceed 14 and the .XS file is using telnet. Can connect to the telnet server fine manually so I know it's not credential issue.
 
Haven't seen Exceed in a long time. :)

Anyway, the way that works is telnet -> sets the DISPLAY variable to your workstation's X server, ie: export DISPLAY=your.workstation.hostname.or.ip:0.0 ) then runs an X application whose window is sent over the network and DISPLAYED on your X server. All the processing occurs on the server.

ssh -X will send X over the ssh tunnel. So, yes, your X server is running.

Your issue is probably the display variable over telnet is not being set or being set improperly, which would explain why you're not seeing any traffic to your X server. It may also be a DNS issue if the server can't resolve your hostname (if it's using hostnames) or could be a firewall issue as well. I take it this server doesn't run ssh? Can you ssh -X server and run the X app that you want to run?

Hope that helps.
 
Last edited:
the X client uses the DISPLAY environment to determine where to connect to the X server. If you do a lot of this with SSH, you'll probably have things configured to automatically forward X11 protocol over the ssh connection (needs support on the ssh client as well as on the server side). If it's a one off, you might just need to do export DISPLAY=your.ip.address:0 before running xterm or whatever
 
Is this like a regular environment variable? So if I manually telnet (yes telnet, not ssh) to the server can I just use whatever syntax is used to set environment variables? Or is there more to it than that? I definitely did not see any such things in the packet sniff (I guess that's one good thing about them using telnet LOL). Though I suppose that may be set locally as this server is made for this purpose. I imagine with SSH it is tunneled through, while with telnet it's probably an actual separate connection? I could not telnet to my outside IP (the server is external) from the server so I wonder if they have some kind of weird redirection firewall setup. I will have to check what the environment variables are when I'm at work again.

Though if it's a config issue I can't see why my file does not work on my coworker's computer and my coworker's file does not work on mine.
 
Well this is interesting, I got it to work, sorta.

I was poking around on the unix server through telnet and found that while the DISPLAY variable was my computer name, if I did an nslookup on that hostname it was NOT my IP address. At first I never even considered that it would be resolving wrong so never tried. I did a local nslookup on my computer and that too is resolving wrong.

So I went back on the unix server and set the DISPLAY variable to my IP, and lo and behold, it works. When I type the command that launches the app, it opens on my PC.

Definitely going to have to make a doc on this one for future reference.
 
Back
Top