X Server and Remote Access: Unterschied zwischen den Versionen

Aus Wiki - Jochen Hammann
Zur Navigation springen Zur Suche springen
(Die Seite wurde neu angelegt: „__TOC__ == Run application on local machine and show GUI on remote display == Die folgende Anleitung beschreibt, wie man eine Applikation auf dem Desktop la…“)
 
 
Zeile 76: Zeile 76:


Die folgenden Ausschnitte aus den Manual Pages beschreiben beide Kommandos näher.
Die folgenden Ausschnitte aus den Manual Pages beschreiben beide Kommandos näher.


<syntaxhighlight lang="text">
<syntaxhighlight lang="text">
Zeile 95: Zeile 96:
         authentication data to the server.
         authentication data to the server.
</syntaxhighlight>
</syntaxhighlight>


<syntaxhighlight lang="text">
<syntaxhighlight lang="text">
Zeile 118: Zeile 120:
         that.
         that.
</syntaxhighlight>
</syntaxhighlight>


== Xming - Kompletten Linux Desktop übertragen ==
== Xming - Kompletten Linux Desktop übertragen ==

Aktuelle Version vom 30. September 2016, 12:49 Uhr


Run application on local machine and show GUI on remote display

Die folgende Anleitung beschreibt, wie man eine Applikation auf dem Desktop laufen lassen kann und deren Display an einen Laptop sendet.

Siehe auch hier


Preparation

(you do this only once)

In your desktop install SSH server

sudo apt-get install openssh-server


From your laptop (X Server)

ssh -X username@desktop_pc_ip

In the terminal you get whatever you run will be on your desktop but displayed on your laptop. If you want to do the same while seated on your desktop (and send windows on your laptop) then go on.

On your terminal you run

echo $DISPLAY

This will show you something like:

localhost:10.0


From your desktop (X Client)

Open a terminal and run

DISPLAY=:10.0 firefox

This should send a firefox window on your laptop but running on your desktop. Make sure the number you put (e.g. 10.0) is the same as in the echo result

Dasselbe hätte man auch erzielen können, wenn man am Laptop in der ssh Console den Firefox (ohen die Angabe eines Display) gestartet hätte. Dann wäre jedoch alles vom Laptop aus initiiert worden, d.h. der Laptop hätte sich das Display geholt. In der Beschreibung hatte der Desktop das Display gesendet.


Xming - X Server ohne SSH und X11 Forwarding

Siehe auch hier

Will man Xming ohne SHH und X11 Forwarding verwenden, so muss der X Client (Host Name bzw. IP Adresse) in der Xn.hosts Datei von Xming spezifiziert sein. Wobei n für die Nummer des Display-Nummer des Xming X Server steht. Dies entspricht dem xhost Befehl eines Linux OS.

Zudem muss darauf geachtet werden, dass in der Windows Firewall der entsprechende Port (aktuell unbekannt, evtl. 6000 und/oder 6001) geöffnet ist, bzw. die Firewall zu Testzwecken deaktiviert ist.

Dann kann unter Linux mit folgenden Befehlen die Ausgabe auf Xming (Windows) umgeleitet werden.

export DISPLAY=<HostName/IP XServer>:<DisplayNummer>.0
xcalc &


Linux - X Server ohne SSH und X11 Forwarding

Will man von einem Linux zu einem anderen das Display eines X Client übtragen, so könnten auf dem X Server folgende Befehle wichtig sein:

  • xhost
  • xauth

Die folgenden Ausschnitte aus den Manual Pages beschreiben beide Kommandos näher.


xhost

    NAME
         xhost - server access control program for X
    SYNOPSIS
         /usr/bin/xhost [[+-]name ...]
    DESCRIPTION
         The  xhost  program  is used to add and delete host names or
         user names to the list allowed to make connections to the  X
         server.   In  the case of hosts, this provides a rudimentary
         form of privacy control and security.  It is only sufficient
         for  a  workstation  (single  user) environment, although it
         does limit the worst  abuses.   Environments  which  require
         more  sophisticated measures should implement the user-based
         mechanism or use the hooks in the protocol for passing other
         authentication data to the server.


xauth

    NAME
         xauth - X authority file utility
    SYNOPSIS
         /usr/bin/xauth  [ -f authfile ] [ -vqibn ] [ command arg ...
         ]
    DESCRIPTION
         The xauth program is used to edit and display the authoriza-
         tion  information  used in connecting to the X server.  This
         program is usually used  to  extract  authorization  records
         from  one  machine  and  merge them in on another (as is the
         case when using remote logins or granting  access  to  other
         users).   Commands (described below) may be entered interac-
         tively, on the xauth command line, or in scripts.  Note that
         this  program  does not contact the X server except when the
         generate command is used.  Normally xauth  is  not  used  to
         create the authority file entry in the first place; the pro-
         gram that starts the X server (often  xdm  or  startx)  does
         that.

Xming - Kompletten Linux Desktop übertragen

Will man mit Xming einen kompletten Linux Desktop darstellen, so geht das mit dem Standard Ubuntu Display Manager LightDM nicht - bzw. damit habe ich es nicht hinbekommen. Anstelle von LightDM sollte der MATE Display Manager verwendet werden. Evtl. funktionieren auch die Display Manager LXDE oder Xfce.

Diese Display Manager können unter Ubuntu hinzu installiert werden.

Tests wurden mit MATE durchgeführt. Diese stellten den MATE Desktop in Xming dar. Zuvor wurde MATE auf ein Ubuntu 15.04 OS nach dieser Anleitung hinzu installiert. Die Tests verwendeten XLaunch mit den Einstellungen:

  • One Window, Display number = 0
  • Open session via XDMCP
  • Search for hosts (broadcast)

Beim Ubuntu Login muss dann MATE als Display Manager ausgewählt werden.


X2Go - Kompletten Linux Desktop übertragen

Will man mit X2Go einen kompletten Linux Desktop darstellen, so geht das mit dem Standard Ubuntu Display Manager LightDM nicht - bzw. damit habe ich es nicht hinbekommen. Anstelle von LightDM sollte der MATE Display Manager verwendet werden. Evtl. funktionieren auch die Display Manager LXDE oder Xfce.

Diese Display Manager können unter Ubuntu hinzu installiert werden.

Tests wurden mit MATE durchgeführt. Diese stellten den MATE Desktop via X2Go dar. Zuvor wurde MATE auf ein Ubuntu 15.04 OS nach dieser Anleitung hinzu installiert. Beim Ubuntu Login muss dann MATE als Display Manager ausgewählt werden.