CentOS安装使用vnc进行远程桌面登录
以下介绍在CentOS 7下安装vncserver并使用vnc-viewer进行登录(使用root权限):
1、运行命令yum install tigervnc-server安装vncserver;
2、运行命令yum install vnc安装vnc;//感觉不安装也可以,安装一下也很快,不要在意这些细节
3、运行命令yum groupinstall "X Window System"安装X-Window;//之前安装发现经常无法启动vncserver,后面通过网上查资料介绍可以安装X-Window解决这个 问题
4、安装中文字符以解决界面中文乱码的问题:yum install dejavu-lgc-sans-fonts、yum groupinstall "Fonts" -y
5、禁用防火墙,如果已经禁用防火墙可以跳过这一步:systemctl stop firewalld.service、systemctl disable firewalld.service
6、配置vncserver:
拷贝创建一个新的配置文件,以开启1号窗口为例,如果需要开启多个则创建多个配置文件即可:
[root@localhost ~]# cp /lib/systemd/system/vncserver@.service /lib/systemd/system/vncserver@:1.service
修改配置文件内容
[root@localhost ~]# vi /lib/systemd/system/vncserver@:1.service
# The vncserver service unit file
#
# Quick HowTo:
# 1. Copy this file to /etc/systemd/system/vncserver@.service
# 2. Replace <USER> with the actual user name and edit vncserver
# parameters appropriately
# ("User=<USER>" and "/home/<USER>/.vnc/%H%i.pid")
# 3. Run `systemctl daemon-reload`
# 4. Run `systemctl enable vncserver@:<display>.service`
#
# DO NOT RUN THIS SERVICE if your local area network is
# untrusted! For a secure way of using VNC, you should
# limit connections to the local host and then tunnel from
# the machine you want to view VNC on (host A) to the machine
# whose VNC output you want to view (host B)
#
# [user@hostA ~]$ ssh -v -C -L 590N:localhost:590M hostB
#
# this will open a connection on port 590N of your hostA to hostB's port 590M
# (in fact, it ssh-connects to hostB and then connects to localhost (on hostB).
# See the ssh man page for details on port forwarding)
#
# You can then point a VNC client on hostA at vncdisplay N of localhost and with
# the help of ssh, you end up seeing what hostB makes available on port 590M
#
# Use "-nolisten tcp" to prevent X connections to your VNC server via TCP.
#
# Use "-localhost" to prevent remote VNC clients connecting except when
# doing so through a secure tunnel. See the "-via" option in the
# `man vncviewer' manual page.
[Unit]
Description=Remote desktop service (VNC)
After=syslog.target network.target
[Service]
Type=forking
User=root
# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=-/usr/bin/vncserver -kill %i
ExecStart=/usr/bin/vncserver %i
PIDFile=/root/.vnc/%H%i.pid
ExecStop=-/usr/bin/vncserver -kill %i
[Install]
WantedBy=multi-user.target
7、运行命令systemctl daemon-reload更新systemctl;
8、运行命令vncpasswd root设置vncserver的密码;
9、运行命令systemctl start vncserver@:1.service(可以运行systemctl enable vncserver@:1.service命令设置为默认启动服务);//启动不了则重启一下系统或则查看启动日志
10、重启系统后使用VNC-Viewer连接:192.168.10.100:1,输入设置的密码即可登录。
CentOS安装使用vnc进行远程桌面登录的更多相关文章
- (总结)CentOS Linux下VNC Server远程桌面配置详解
一.安装相应桌面环境与vnc服务端和客户端: # yum groupinstall "GNOME Desktop Environment"(CentOS 5.x安装GNOME桌面环 ...
- CentOS Linux下VNC Server远程桌面配置详解
http://www.ha97.com/4634.html PS:偶以前基本不用Linux的远程图形桌面,前几天有开发的同事配置CentOS的vnc有问题,找我解决,就顺便记录总结一下,这个总结是比较 ...
- VNC CentOS Linux下VNC Server远程桌面配置详解
VNC概述 VNC (Virtual Network Console)是虚拟网络控制台的缩写.VNC 是一款优秀的远程控制工具软件,由著名的 AT&T 的欧洲研究实验室开发的.VNC 是在基于 ...
- CentOS 6使用VNC配置远程桌面
首先,配置vncservers(注意,rootW为1,普通用户按2,3以此类推) [root@hadoop1001 hadoop]# vi /etc/sysconfig/vncservers # VN ...
- CentOS6.5下VNC Server远程桌面配置详解
参考文献: (总结)CentOS Linux下VNC Server远程桌面配置详解 远程桌面连接工具VNC——license Key 我的下载地址为 太平洋下载 VNC连接黑屏的问题 centos 6 ...
- CentOS 6.8 安装TigerVNC 实现 Linux 远程桌面并安装火狐浏览器
CentOS 6.8 安装TigerVNC 实现 Linux 远程桌面并安装火狐浏览器 vnc客户端地址:https://files.cnblogs.com/files/MYSQLZOUQI/vnc- ...
- Kali 2017.3开启VNC远程桌面登录
通过启用屏幕共享来开启远程桌面登录,开启后需要关闭encryption,否则会出现无法连接的情况.关闭encryption可以使用系统配置工具dconf来完成.所以先安装dconf-editor. 更 ...
- centos7 通过kvm+vnc 实现远程桌面虚拟化和创建windows、Linux虚拟机
感谢朋友支持本博客.欢迎共同探讨交流,因为能力和时间有限.错误之处在所难免,欢迎指正! 假设转载.请保留作者信息. 博客地址:http://blog.csdn.net/qq_21398167 原博文地 ...
- Azure VM对远程桌面登录的支持-示例
我们在开发Windows Azure的应用程序,虽然在大部分的情况下都可以使用Azure Emulator模拟器来模拟在云端计算节点(Azure VM)的执行结果,但是并不能100%模拟真正在Azur ...
随机推荐
- POJ 3104 Drying (二分+精度)
题目链接:click here~~ [题目大意]: 题意:有一些衣服,每件衣服有一定水量,有一个烘干机,每次能够烘一件衣服,每分钟能够烘掉k单位水. 每件衣服没分钟能够自己主动蒸发掉一单位水, 用烘干 ...
- Eclipse添加Qt插件
此文件仅为步骤操作作一个记录,以便以后方便查阅. 1.操作大体参考这个网站:http://blog.csdn.net/defonds/article/details/5013412 2.我的运行环境: ...
- Python安装、配置图文详解
原文地址:http://weixiaolu.iteye.com/blog/1617440 目录: 一. Python简介 二. 安装python 1. 在windows下安装 2. 在Linux下安装 ...
- win7下IIS7.0虚拟目录不存在的问题
问题:在IIS7.0下选中虚拟目录,右边浏览应用程序下,自动打开浏览器找开虚拟目录下的网站,但过一会什么都没有改变,再一次右边浏览应用程序,就提示 “虚拟目录不存在”. 解决方法:右键网站或下面的虚拟 ...
- 【转载】OAuth的机制原理讲解及开发流程
1.OAuth的简述 OAuth(Open Authorization,开放授权)是为用户资源的授权定义了一个安全.开放及简单的标准,第三方无需知道用户的账号及密码,就可获取到用户的授权信息,并且这是 ...
- bzoj 4318: OSU!【期望dp】
思路有点眼熟啊,就是设l1记录长为x的极长全1串贡献x的答案,l2记录长为x的极长全1串贡献x^2的答案,f记录真正的答案 转移的话根据n-(n-1)=1,n^2-(n-1)^2=2n-1,n^3-( ...
- PowerShell+NetApi 批处理执行程序
基于CMD 编写批处理程序很反人类,此篇文章介绍利用Power Shell脚本(借鉴明经net版主雪山飞狐的脚本改造而成)处理之前的Bat+scr的过程(https://www.cnblogs.com ...
- Java之简单的四则运算
简单的四则运算 请你编写程序实现能处理两个数的+.-.*./.%的表达式程序.数据的输入/输出全部使用标准输入/输出,输入数据的第一行为你需要计算表达式的个数,从第2行开始,每一行为你计算的一个表达式 ...
- Neighbor House LightOJ - 1047
Neighbor House LightOJ - 1047 #include<cstdio> #include<cstring> #include<algorithm&g ...
- Fools and Roads CodeForces - 191C
Fools and Roads CodeForces - 191C 题意:给出一棵n个节点的树,还有树上的k条简单路径(用路径的两个端点u和v表示),对于树上每一条边,求出其被多少条简单路径经过. 方 ...