[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: external monitor and X



Jerome BENOIT wrote:
> 
> Bonjour,
> 
> we can login to an external computer and run X stuff from there,
> can we do the reverse ?
> I mean, can we open an X session on an external screen (via internet
> connction) ?

  yes, you can run an X application anywhere you want and display it
anywhere you want (as long as there is netwrok connection and you have
rights run application on given computer and display it on given X
server).

  run:

  that's no different than running any other application, you can e.g.
ssh into a machine and run the application, e.g. xterm

  display:

  specify display suing either setting of the DISPLAY environmental
variable:

  export DISPLAY=machine:n.m	# sh and derivatives
  setenv DISPLAY machine:n.m	# csh and derivatives
  xterm

  or use command line option (not all programs support this):

  xterm -display machine:n.m

  where

    machine is address of the machine (name or numeric IP)
    n is display number (usually 0 if only one X server is running)
    m is screen number (usually 0, can be omitted)

  to set be able to display on the given X server you can use various
methods:

  NOT GOOD! INSECURE! (good for testing only, standalone (non-networked)
machine):

  xhost +whereFrom

  whereFrom is the address of the machine where you run the program, see
man xhost

  better:

  xauth merge .Xauthority

  where xauth is run on machine where you run application but
.Xauthority is .Xauthority file from home directory of the user that
owns the X server

  another option is to use ssh port forwarding.

	erik



Reply to: