您的位置:首页 > 运维架构 > Linux

远程连接linux服务器 & 传送文件 ——VNC & ssh/winSCP

2017-03-11 19:27 411 查看
windows系统服务器的远程连接比较好弄,那么linux呢? 最后搜到了VNC。

step 1install vnc

$ sudo apt-get install vnc4server

step 2set passward

$ vncpasswd

step 3
start vncserver on your linux server

$ vncserver :2

When connecting this linux server,you will need the VNC server address "IP+::5902".  For example, "192.168.3.5::5902".

The terminal shows "Starting applications specified in /home/king/.vnc/xstartup"  

if you type the line again before you kill it.  "A VNC server is already running as :2" will show in your terminal.

if you wanna close it, just type $ vncserver -kill :2



Big Problem: After installing VNC viewer and connecting the linux server via my laptop, unfortunately, i can only see one  terminal in the VNC viewer interface.

How to get the user-friendly graphical inteface in my VNC server.

This page supports one useful solution.  == LINK== 

Step 4install gnome and revise /.vnc/xstartup

$ apt-get install gnome-panel



Bingo!



======================================================================================

考虑到 vnc 不支持windows与linux 服务器之间传送文件,只能别求它法。

具体参考链接:http://jingyan.baidu.com/article/9c69d48fb9fd7b13c8024e6b.html

“ssh是一种安全协议,主要用于给远程登录会话数据进行加密,保证数据传输的安全,现在介绍一下如何在Ubuntu 14.04上安装和配置ssh”

1. linux上安装ssh  "sudo apt-get install openssh-server"

2. linux 上检查是否启动ssh服务,“打开"终端窗口",输入"sudo
ps -e |grep ssh"-->回车-->有sshd,说明ssh服务已经启动,如果没有启动,输入"sudo service ssh start"-->回车-->ssh服务就会启动。”

3. 使用gedit修改配置文件"/etc/ssh/sshd_config"

打开"终端窗口",输入"sudo gedit /etc/ssh/sshd_config"-->回车-->把配置文件中的"PermitRootLogin without-password"加一个"#"号,把它注释掉-->再增加一句"PermitRootLogin yes"-->保存,修改成功

4. 在window电脑端,利用winscp连接就好了。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: