Linux – X11 forwarding through SSH

forwardinglinuxttyx11xorg

I have been playing around with X11 forwarding the past few hours and so far I've managed to forward my desktop pc's X Server to my laptop, using X11VNC as server and X2VNC as client. X2VNC uses Xinerama to provide a dual-screen-like behavior between my laptop and my desktop pc.

It's actually really great!

I know that most Linux systems run Xorg and desktop environments on TTY7.

Therefore I was thinking, is it in any way possible to have the VNC-tunnel tied to it's own TTY?

It would be great to be able to switch forth and back between two TTY's in order to choose which machine to manage. And I would like this approach more than using Xinerama or a GUI.

Best Answer

I guess this is not really an answer, but it might be a starting point.

I started a bunch of extra X servers using xinit like so;

xinit -- :1 tty3   
xinit -- :2    
xinit -- :3 tty5    
xinit -- :4

It looks like I can even start multiple gnome3 and xfce sessions on different virtual displays

startx -- :2  tty3   
startx -- :3  tty4

And now I can start stuff in those sessions by exporting the DISPLAY var export DISPLAY=:3 and then select it using the Ctrl-Alt-F2, F3 etc

However I have absolutely no idea what I am doing (am I switching DISPLAY, session, console, or tty?), its just pretty cool, as you say... ;-)

[tomh@workstation001 ~]$ export DISPLAY=:4
[tomh@workstation001 ~]$ google-chrome
Related Question