I want to run an X11 program on the SERVER and display the window on the CLIENT.I have a shell on the server to start with. (This is not an SSH shell, but some cluster computing software) The program must somehow be started from this shell.I have SSH access and direct access to the CLIENT,however I cannot SSH from the CLIENT to the SERVER.I want to run the program on the SERVER and open the window on the client. How do I do it?
Reverse X11 Forwarding without SSH on server
linux;ssh;x11;xorg
Reverse tunnel methodYou can SSH from A to B but you want to SSH from B to A?A generic solution is to create a reverse SSH tunnel. From SERVER:ssh -f -N -R 4222:localhost:22 CLIENTNow you can SSH to port 4222 on CLIENT and log into the server. Turn on X11 forwarding on that connection.ssh -p 4222 -X localhostManual setup methodAlternatively, you can set up X11 forwarding manually to the desired display. If you want to forward display :20 on CLIENT to display :0 on SERVER:ssh -L 6020:localhost:6000 CLIENTApplications can only use an X display if they show proper authorization. This takes the form of a cookie (randomly generated value that serves as a password). You need to retrieve the cookie value and run the command xauth add :20 MIT-MAGIC-COOKIE-1 . See Open a window on a remote X display (why Cannot open display)?. In your case, you can obtain the cookie value on SERVER by running the command xauth list in your X session.Once you've established the TCP forwarding and set the cookie value, set export DISPLAY=:20 and run your application.