D&C GLug - Home Page

[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]

Re: [LUG] Commandeering X

 

On Tue, 21 Jan 2014, Philip Hudson wrote:

Perhaps I should explain why X11 forwarding over ssh is not the solution I
want: I want specifically to use the target machine's display and speakers
for video playback using VLC, for presentation to others under remote
control.

I'm not 100% sure you can do that these days.

(Some of the remote control part, anyway)

If the remote PC is already running X (and a desktop manager), then you should be able to ssh in, set DISPLAY to :0.0 then run an application and have it run and display on that remote PC. (system permissions not withstanding - someone on the remote PC will need to do xhost + or something).

However at that point, the application is running on that remote PC but it's also taking mouse and keyboard input from the remote PC, not from your local PC which I think is what you're trying to achieve. (correct me if wrong)

I think this is due to current X reading directly from /dev/input and not some network resource.

The same holds true for starting a new X session on a remote PC - X is reading from /dev/input so will use that remote PCs directly connected mouse and keyboard for input, rather than take it from your local PC.

Test:

brain is a Linux laptop, yakko is my Linux desktop:


  gordon @ brain: ssh yakko
  ...

  gordon @ yakko: xterm
  xterm: Xt error: Can't open display: yakko:0.0
  gordon @ yakko: setenv DISPLAY :0.0
  gordon @ yakko: xterm

at this point an xterm popped up on yakkos screen, but to type into it, I had to move the mouse into its window and keyboard input came from the keyboard connected to yakko, not brain.

  gordon @ yakko: xhost
  access control enabled, only authorized clients can connect
  SI:localuser:gordon
  gordon @ yakko:

So if you have an application that works entirely from the command line (and I think you can make VLC go fullscreen & play a video that way) then it may do what you need, but if it needs keyboard/mouse input, then you may have more issues.

But if this is acceptable, then most X + desktops these days can auto-boot into being logged in with the desktop running without typing anything, so you could setup a blank/default desktop then ssh in and run full-screen applications that way.

Or I've gotten hold of the wrong end of the stick...

Gordon

--
The Mailing List for the Devon & Cornwall LUG
http://mailman.dclug.org.uk/listinfo/list
FAQ: http://www.dcglug.org.uk/listfaq