RHEL6.2配置Xmanager访问

先决条件: 系统已经安装,并且安装好了X-window,并且启动模式是5(图形方式)。Xmanager软件使用协议  XDMCP(X Display Manager Control Protocol)X显示监控协议。

1、打开XDMCP配置文件,并且指定端口177。与RHEL5.4配置有所不同,RHEL6.2没有/usr/share/gdm/defaults.conf 。

[root@lsfronta ~]# vi /etc/gdm/custom.conf 
# GDM configuration storage
[daemon]
[security]
AllowRemoteRoot=true
[xdmcp]
Enable=true
Port=177
[greeter]
[chooser]
[debug]

2、配置防火墙,或者关闭防火墙。

在防火墙上开启允许177端口的访问

#iptables -A INPUT -p udp  -m iprange --src-range 172.169.221.5-172.169.221.8 -d 172.169.221.15 --dport 177 -j ACCEPT
#iptables -A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT

我是直接关闭了防火墙
[root@lsfrontb ~]# service iptables status
Table: filter
Chain INPUT (policy ACCEPT)
num  target     prot opt source               destination         
1    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           state RELATED,ESTABLISHED 
2    ACCEPT     icmp --  0.0.0.0/0            0.0.0.0/0           
3    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           
4    ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           state NEW tcp dpt:22 
5    REJECT     all  --  0.0.0.0/0            0.0.0.0/0           reject-with icmp-host-prohibited 


Chain FORWARD (policy ACCEPT)
num  target     prot opt source               destination         
1    REJECT     all  --  0.0.0.0/0            0.0.0.0/0           reject-with icmp-host-prohibited 


Chain OUTPUT (policy ACCEPT)
num  target     prot opt source               destination         


[root@lsfrontb ~]# service iptables stop
iptables: Flushing firewall rules:                         [  OK  ]
iptables: Setting chains to policy ACCEPT: filter          [  OK  ]
iptables: Unloading modules:                               [  OK  ]
[root@lsfrontb ~]# chkconfig --level 2345 iptables off
[root@lsfrontb ~]# service iptables status
iptables: Firewall is not running.
3、查看XDM运行情况
查看177端口下的应用,查看177端口。
[root@lsfrontb ~]# ps -ef | grep xdm
root      3432  3278  0 19:31 pts/0    00:00:00 grep xdm
[root@lsfrontb ~]# lsof -i:177
[root@lsfrontb ~]# netstat -an| grep 177
unix  3      [ ]         STREAM     CONNECTED     17732  /var/run/acpid.socket
unix  3      [ ]         STREAM     CONNECTED     17731  
unix  3      [ ]         STREAM     CONNECTED     17726  @/var/run/hald/dbus-dnAeVpRPhb
unix  3      [ ]         STREAM     CONNECTED     17725  
unix  3      [ ]         STREAM     CONNECTED     17700  @/var/run/hald/dbus-dnAeVpRPhb 

4、重启系统

5、使用Xmanager Enterprise 4直接访问机器。

你可能感兴趣的:(Unix&Linux)