centos6安装图形界面并远程连接

1. 安装图形化界面
# yum groupinstall -y "Desktop" "Desktop Platform" "Desktop Platform Development"  "Fonts"  "General Purpose Desktop"  "Graphical Administration Tools"  "Graphics Creation Tools"  "Input Methods"  "X Window System"  "Chinese Support [zh]" "Internet Browser"
# yum install xorg-x11* -y
 
 
2. 安装与配置 VNC 服务器
# yum install vnc *vnc-server* -y
####修改VNCServer主配置文件 
# vim /etc/sysconfig/vncservers 
####复制最后两行并去掉行首注释符,然后修改为 
VNCSERVERS="1:root"
VNCSERVERARGS[1]="-geometry 1024x768"
####设置vnc连接密码
# vncpasswd                                #输入两次相同的密码
####启动服务
# /etc/init.d/vncserver start
Starting VNC server: 1:root xauth: file /root/.Xauthority does not exist
New 'niaoyun47507:1 (root)' desktop is niaoyun47507:1
Creating default startup script /root/.vnc/xstartup
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/niaoyun47507:1.log
                                                           [ OK ]
# vim /root/.vnc/xstartup
####将最后一行改为
gnome & 
#### 防火墙添加相关规则 
# vim /etc/sysconfig/iptables
-A INPUT -m state --state NEW -m tcp -p tcp --dport 5901 -j ACCEPT  #添加
# service iptables restart
 
3.使用vnc客户端连接服务器
然后使用realvnc,http://www.realvnc.com/
输入“IP:1”
再输入密码即可
vnc默认端口是5900+vnc端口数字

转载于:https://www.cnblogs.com/senduy/p/5665418.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值