码迷,mamicode.com
首页 > 系统相关 > 详细

linux下跨服务器文件文件夹的复制

时间:2016-01-11 23:47:56      阅读:962      评论:0      收藏:0      [点我收藏+]

标签:

文件的复制:scp –P (端口号) ./authorized_keys berchina@hadoop002:/home/berchina

文件夹的复制:scp -r -P (端口号) /home/berchina/hadoop-2.2.0 berchina@hadoop002:/home/berchina/

 

 

注:

红色 字体是我敲击的命令

“#” 是注释语

 

[root@localhost server]# ftp 10.2.1.67     #登录服务器
Connected to 10.2.1.67.
220-FileZilla Server version 0.9.34 beta
220-written by Tim Kosse (Tim.Kosse@gmx.de)
220 Please visit http://sourceforge.net/projects/filezilla/
502 GSSAPI authentication not implemented
504 Auth type not supported
KERBEROS_V4 rejected as an authentication type
Name (10.2.1.67:root): s    #输入用户名
331 Password required for s
Password:                       #输入密码
230 Logged on
Remote system type is UNIX.
ftp> bin                 #bin 代表采用二进制的文件
200 Type set to I
ftp> hash              #显示传输进度 
Hash mark printing on (1024 bytes/hash mark).
ftp> ls                  #查看ftp目录下文件
227 Entering Passive Mode (10,2,1,67,206,237)
150 Connection accepted
drwxr-xr-x 1 ftp ftp              0 Dec 21 10:03 136
-r--r--r-- 1 ftp ftp           1934 Dec 31 16:39 22.tar
drwxr-xr-x 1 ftp ftp              0 Dec 21 10:03 centOs
#
226 Transfer OK

ftp> get 22.tar        #下载文件
local: 22.tar remote: 22.tar
200 Port command successful
150 Opening data channel for file transfer.
########################################################

########################################################

########################################################

################################################# 
226 Transfer OK
4432896 bytes received in 0.87 seconds (5e+03 Kbytes/s)
ftp> 。。。。。

 

下载的时候就会一直不停的打印“#”,一个“#”代表1024 bytes。

linux下跨服务器文件文件夹的复制

标签:

原文地址:http://www.cnblogs.com/gaving10/p/5122913.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!