考试首页 | 考试用书 | 培训课程 | 模拟考场 | 考试论坛  
  当前位置:Linux认证 > 红帽认证 > 红帽认证辅导 > 文章内容
  

RHCE7认证学习笔记:压缩、归档和系统间的文件传输

来源:Linux社区 [ 2016年2月20日 ] 【

二、系统间的文件传输

    scp需要依赖于openssh-client:
    scp,本地或者远端的文件互相拷贝,拷贝目录加-r选项:
[root@linuxidc ~]# scp --help
usage: scp [-12346BCpqrv] [-c cipher] [-F ssh_config] [-i identity_file]
          [-l limit] [-o ssh_option] [-P port] [-S program]
          [[user@]host1:]file1 ... [[user@]host2:]file2

[root@linuxidc ~]# scp -r /tmp root@192.168.100.1:~/xx

    rsnc:

[root@linuxidc ~]# rsync --help
Usage: rsync [OPTION]... SRC [SRC]...

 DEST
  or  rsync [OPTION]... SRC [SRC]... [USER@]HOST:DEST
  or  rsync [OPTION]... SRC [SRC]... [USER@]HOST::DEST
  or  rsync [OPTION]... SRC [SRC]... rsync://[USER@]HOST[:PORT]/DEST
  or  rsync [OPTION]... [USER@]HOST:SRC [DEST]
  or  rsync [OPTION]... [USER@]HOST::SRC [DEST]
  or  rsync [OPTION]... rsync://[USER@]HOST[:PORT]/SRC [DEST]
The ':' usages connect via remote shell, while '::' & 'rsync://' usages connect
to an rsync daemon, and require SRC or DEST to start with a module name.

 Options
 -v, --verbose              increase verbosity
 -q, --quiet                suppress non-error messages
    --no-motd              suppress daemon-mode MOTD (see manpage caveat)
 -c, --checksum              skip based on checksum, not mod-time & size
 -a, --archive              archive mode; equals -rlptgoD (no -H,-A,-X)
    --no-OPTION            turn off an implied OPTION (e.g. --no-D)
 -r, --recursive            recurse into directories
 -R, --relative              use relative path names
    --no-implied-dirs      don't send implied dirs with --relative
 -b, --backup                make backups (see --suffix & --backup-dir)
    --backup-dir=DIR        make backups into hierarchy based in DIR
    --suffix=SUFFIX        set backup suffix (default ~ w/o --backup-dir)
 -u, --update                skip files that are newer on the receiver
    --inplace              update destination files in-place (SEE MAN PAGE)
    --append                append data onto shorter files
    --append-verify        like --append, but with old data in file checksum
 -d, --dirs                  transfer directories without recursing

    windows系统与linux系统间文件的拖拉直接传输,可以安装lrzsz.x86_64这个包
    Xshell终端可以直接输入rz命令,进行文件的传输

    linux拷贝到windows使用sz file

    Xshell直接按快捷键crtl+alt+F键调用xftp进行大文件传输;

首页 1 2 尾页
本文纠错】【告诉好友】【打印此文】【返回顶部
将考试网添加到收藏夹 | 每次上网自动访问考试网 | 复制本页地址,传给QQ/MSN上的好友 | 申请链接 | 意见留言 TOP
关于本站  网站声明  广告服务  联系方式  站内导航  考试论坛
Copyright © 2007-2013 中华考试网(Examw.com) All Rights Reserved