PDA

View Full Version : XDMCP setup problem



ganick
2nd February 2007, 02:42 PM
Hi all,

Trying to setup XDMCP on Fedora Core 6 box.
After googling around I found this step-by-step guide:

1. edit /etc/X11/xdm/xdm-config
Comment out the last line as indicated in the file.

2. edit /etc/X11/xdm/kdmrc
find the section [XDMCP]
change enabled=true

3. edit /etc/X11/gdm/gdm.conf
find the section [XDMCP]
change enabled=true

4. restart X.

But there is no gdm directory under /etc/X11. Where can this be ?
Where are the configuration files of gdm package ?

"rpm -qi gdm" gives me results the package is installed (gdm-2.16.0-10.fc6).
I am able to run "gdmsetup" but still no result.
"netstat -na | grep 177" no result. This means that gdm is not
up and running right?
How can I make it run ? Any ideas ?

Thanks in advance.

jcliburn
3rd February 2007, 05:14 AM
I wrote this for myself last summer. It may help.

This procedure assumes you're on a private LAN, 192.168.1.0/24. If you're not, adjust IP addresses accordingly.

If you have console access to the remote machine, skip to step 4. Steps 1-3 enable the remote machine to send an X window to your local machine, but you don't need that if you can sit down in front of the remote machine's console.

1. On the local machine, edit /etc/ssh/ssh_config and set ForwardX11 yes. Edit /etc/sysconfig/iptables and add the following two lines before the line that contains "reject-with icmp-host-prohibited".

-A RH-Firewall-1-INPUT -s 192.168.1.0/24 -p tcp -m tcp --dport 6000 -j ACCEPT

Save the file. Restart iptables.

2. On the remote machine, edit /etc/ssh/sshd_config and set X11Forwarding yes. Restart sshd. Logout of the remote machine.

3. ssh to the remote machine.

Begin: configure the remote machine for XDMCP.

4. On the remote machine, become root. Run gdmsetup. Select the Remote tab and choose "Same as Local". Click "Configure XDMCP" in lower right corner. Make sure that "Honor indirect requests" is UNchecked. Make sure "Listen on UDP port:" is set to 177. Click Close. Click Close. Edit /etc/sysconfig/iptables and add this line before the line that contains "reject-with icmp-host-prohibited".

-A RH-Firewall-1-INPUT -s 192.168.1.0/24 -p udp --dport 177 -j ACCEPT

Save the file. Restart iptables.

If you're sitting at the remote machine's console, execute init 3 from the command line. A text session appears. Press enter if it appears hung. Login as root. Execute init 5 from the command line. X starts. Press CTRL-ALT-F1. The text session reappears. Logout of the root session. Pres CTRL-ALT-F7 to return to X.

If you're sitting at the local machine and accessing the remote system through ssh, execute init 3 from the command line. Nothing unusual happens. Execute init 5 from the command line. Nothing unusual happens.

Whether you're at the console or not, execute the following command and verify that gdm-binary has opened port 177/udp.

[root@petrel ~]# netstat --inet -pnl | grep 177
udp 0 0 0.0.0.0:177 0.0.0.0:* 3474/gdm-binary

If so, XDMCP is now running on the remote host.

4. On the local machine, become root. Edit /etc/sysconfig/iptables and add the following line before the line that contains "reject-with icmp-host-prohibited".

-A RH-Firewall-1-INPUT -s 192.168.1.0/24 -p tcp -m tcp --dport 6001 -j ACCEPT

Save the file. Restart iptables. Return to a non-root shell. From the command line, kick off an X session connecting to the remote host's X server, sending the display to local display :1. Here's the command to do it.

Xorg :1 -ac -query REMOTE_HOST_IP_ADDR

A new X session will start. You can toggle between the sessions by pressing CTRL-ALT-F7 (for display 0, your original local session) and CTRL-ALT-F8 (for display 1, your new XDMCP-served remote session).