linux sftp 和scp 运用
Linux scp命令:
Upload to remote :复制本地文件到远程
Part1:
Scp -P port local_file remote_user@remote_ip:remote_file
SCP -P port -r local_dir remote_user@remote_ip:remote_dir # local_dir must exist ,else will occur error
Part2:
Dowmload from remote 复制远程文件到本地
Scp -P port remoet_user@remote_ip:remote_file local_file
Scp -P port -r remote_user @remote_ip:remote_dir local_dir # localdir must exist
Sftp :
Part1:
Sftp remote_user@remote_ip
>> pwd:
>> ls -l remote_dir
>>lls -l
# get file from remote 远程获取文件
>> get remote_file local_file #localfile if exists in local linux will cover it by remote same name file
Eg:
sftp> get /usr/local/test002/2.txt /usr/local/test01/1.txt
Fetching /usr/local/test002/2.txt to /usr/local/test01/1.txt
/usr/local/test002/2.txt 100% 5 5.2KB/s 00:00
sftp> exit
Part2:
>> put local file from local 从本地上传到远程文件
>> put local_file remote_file 上传文件如果远程已存在会直接覆盖掉远程同名文件
Eg:
sftp> put /usr/local/test01/1.txt /usr/local/test002/2.txt
Uploading /usr/local/test01/1.txt to /usr/local/test002/2.txt
/usr/local/test01/1.txt 100% 5 6.3KB/s 00:00
linux sftp 和scp 运用的更多相关文章
- linux 的 sftp 和 scp
====================================== 作者: wxy0327(http://wxy0327.itpub.net) 发表于: 2006.12.07 13:19 分 ...
- linux - sftp, scp, rz, sz(文件传输命令)
1. sftp Secure Ftp 是一个基于SSH安全协议的文件传输管理工具.由于它是基于SSH的,会在传输过程中对用户的密码.数据等敏感信息进行加密,因此可以有效的防止用户信息在传输的过程中被窃 ...
- Telnet、FTP、SSH、SFTP、SCP
[Telnet]著名的终端访问协议,传统的网络服务程序,如FTP.POP和Telnet,其本质上都是不安全的:因为它们在网络上用明文传送数据.用户帐号和用户口令. [telnet命令]telnet h ...
- Linux 命令之 scp 命令详解
Linux 命令之 scp 命令详解 一.scp 简介 scp 命令用于不同主机之间复制文件和目录. scp 是 secure copy 的缩写,是 基于 ssh 协议进行安全的远程文件拷贝命令. s ...
- linux cp 和scp详解
linux之cp/scp命令+scp命令详解 名称:cp 使用权限:所有使用者 使用方式: cp [options] source dest cp [options] source... dire ...
- 【转】linux之cp/scp命令+scp命令详解
linux之cp/scp命令+scp命令详解 名称:cp 使用权限:所有使用者 使用方式: cp [options] source dest cp [options] source... dire ...
- linux 上传scp 压缩tar命令
1.Linux 上传scp 1)上传文件与文件夹 scp file weblogic@xx.xxx.xxx.xxx:~/songjd/ scp -r filefolder weblogic@xxx.x ...
- linux下用scp命令在两个服务器之间传输文件,利用php_scp函数进行文件传输
在linux下利用scp进行文件传输, 从服务器下载文件 scp username@servername:/path/filename /path/filename 上传本地文件到服务器 scp /p ...
- 在 Linux 下使用 scp 命令
将文件或文件夹从网络上的一个主机拷贝到另一个主机当中去. here:在 Linux 下使用 scp 命令 摘要: scp 是安全拷贝协议(Secure Copy Protocol)的缩写, scp 是 ...
随机推荐
- JDBC未知列
Exception in thread "main" com.mysql.jdbc.exceptions.jdbc4. MySQLSyntaxErrorException: Unk ...
- Centsos7 aria2
wget -N --no-check-certificate https://raw.githubusercontent.com/ToyoDAdoubi/doubi/master/aria2.sh & ...
- 服务器上搭建使用SSH账户登录的Git仓库
1.安装git yum install -y git 2.创建git仓库保存的目录 mkdir /data/git_repo 3.初始化空仓库 cd /data/git_repogit init -- ...
- 部署prerender服务器
// 安装 git sudo apt-get install git sudo apt-get install curl // 请先确认服务器是否安装了curl 如果已经安装跳过即可 // 安装 no ...
- centos7解压压缩zip文件
一.安装支持ZIP的工具 yum install -y unzip zip 二.解压zip文件 unzip 文件名.zip 二. 压缩一个zip文件 zip 文件名.zip 文件夹名称或文件名称
- visual env VS conda environment of python
1. There's two types of python environment in pycharm: virtualenv Environment conda environment For ...
- python面试的100题(6)
7.请反转字符串 "aStr"? print("aStr"[::-1]) python实现字符串反转 第一种:使用字符串切片 result = s[::-1] ...
- 图像滤波—opencv函数
函数原型 方框滤波 ,-), bool normalize = true, int borderType = BORDER_DEFAULT) 均值滤波 ,-), int borderType = ...
- 题解【洛谷P4588】[TJOI2018]数学计算
题目描述 小豆现在有一个数\(x\),初始值为\(1\).小豆有\(Q\)次操作,操作有两种类型: \(1\;m\):\(x=x\times m\)输出\(x\%mod\); \(2\;pos\):\ ...
- 【C语言】定义一个函数,求长方体的体积
#include<stdio.h> int volume(int a, int b,int c)/*定义函数*/ { int p; p = a * b * c; return p; } i ...