How does one setup XDM for remote X servers?
Description:
I would like to use XDM to provide X services to remote clients. How is this accomplished?
Solution:
Setting up the server side of things:
Edit the /etc/X11/kdm/Xaccess file to include one of the following (no quotes):
1."* CHOOSER BROADCAST"
This will set the server up as the machine that queries the network for other machines that can serve XDMCP
connections. This server will not actually be doing the serving of
XDMCP; it will only act as a proxy that finds other machines that can provide this service.
2."* CHOOSER %HOSTS"
This will do the same as the first option, but will only query the machines in a pre-defined list called
"%HOSTS". If this option is used, earlier in the Xaccess file you must have a definition of this list that looks
something like this:
%HOSTS host1 host2 host3 host4 host5 \
host6 host7 host8
(Note that there is nothing special about the name "HOSTS"; you can change it to "GEORGE" and precede it with a
"%" and it'll have the same affect, as long as "%GEORGE" is used in the "CHOOSER" line above.)
3."*"
This will open up the server to connections from any client on the network. No "chooser" menu will be assembled; if this machine receives a request from a client, it will simply start
an XDMCP session.
Note that in each of these cases, "*" could be replaced by an individual machine name or a wildcarded name spec (i.e. dhcp*.scosystems.com) if the scope of supported
machines needs to be limited.
Edit the /etc/X11/kdm/xdm-config file to include the following line:
DisplayManager*chooser: /usr/X11R6/bin/chooser
And change the 'Port' line too:
DisplayManager.requestPort: 177
Make sure KDM is running on the server after all of this is done. Restart the X system if necessary. Note that
all XDMCP capable servers that you would like to appear in the chooser menu for clients will have to have at
least a "*" line in its /etc/X11/kdm/Xaccess file. Only set up one server as a "chooser" (using the instructions
above), and have clients always query that one
"chooser" machine for a menu of XDMCP capable servers.
Setting up the client side (with X not currently running):
Start an X connection using one of the following commands:
1."X -indirect chooser_server"
This will query "chooser_server" for connections, and if everything is set up correctly on that server, the
client will see a chooser menu. Again, if a server is set up as a chooser,
it can not serve XDMCP services; all it will do is assemble a menu of machines and send it to a client that
starts X using the command above.
2."X -query server"
This will query "server" directly for an XDMCP session. Note that "server" should not be set up as a chooser
using the instructions listed earlier. Its Xaccess file should have a line
that permits access from the client, whether the line is nothing more than the client's full machine name, or
simply an "*" which opens the server to queries from any machine on
the network.
3."X -broadcast"
This will broadcast a plea for XDMCP connections over the entire network, and the first server that responds
will offer a login prompt to the client. It's possible that each time X is
started this way, a different server will end up providing the XDMCP services.
Multiple X displays
Finally, you can run multiple versions of X on different virtual terminals by specifying a number
corresponding to the next X console, starting with 1. For example, the following code would start
X on the first X console with the display provided by servername.
X :1 -query servername
And to start on the second X console:
X :2 -query secondservername
Please note that opening up multiple remote X displays in this way can generate a lot of traffic on your network and should be used with discretion.
|
SUPPORT LINKS
|