2018-07-26 孙小北

s3cmd安装配置及下载中断续传问题

养浩然之气,做博学之人

s3cmd 是一款 Amazon S3 命令行工具。它不仅能上传、下载、同步,还能设置权限。

1 下载

官网:https://s3tools.org/s3cmd

下载安装包:https://s3tools.org/download

GitHub:https://github.com/s3tools/s3cmd/releases

本文安装包:https://github.com/s3tools/s3cmd/releases/download/v2.0.2/s3cmd-2.0.2.tar.gz

2 安装

tar -xvzf s3cmd-2.0.2.tar.gz
mv s3cmd-2.0.2/ /usr/local/s3cmd
ln -s /usr/local/s3cmd/s3cmd /usr/bin/s3cmd

3 配置

s3cmd --configure

配置,主要是 Access Key ID 和 Secret Access Key

#s3cmd --configure

Enter new values or accept defaults in brackets with Enter.
Refer to user manual for detailed description of all options.

Access key and Secret key are your identifiers for Amazon S3
Access Key: ACCESS_KEY
Secret Key: SECRET_ACCESS_KEY

Encryption password is used to protect your files from reading
by unauthorized persons while in transfer to S3
Encryption password:
Path to GPG program [/usr/bin/gpg]:

When using secure HTTPS protocol all communication with Amazon S3
servers is protected from 3rd party eavesdropping. This method is
slower than plain HTTP and can't be used if you're behind a proxy
Use HTTPS protocol [No]:

On some networks all internet access must go through a HTTP proxy.
Try setting it here if you can't connect to S3 directly
HTTP Proxy server name: 
HTTP Proxy server port [3128]: 

New settings:
  Access Key: ACCESS_KEY
  Secret Key: SECRET_ACCESS_KEY
  Encryption password:
  Path to GPG program: /usr/bin/gpg
  Use HTTPS protocol: False
  HTTP Proxy server name: 
  HTTP Proxy server port: 0

Test access with supplied credentials? [Y/n] n
Save settings? [y/N] y

需要填写:ACCESS_KEY,SECRET_ACCESS_KEY

Test access with supplied credentials? [Y/n] n
       Save settings? [y/N] y

4 下载文件

s3cmd get --recursive s3://yahoo-webscope/L30/

5 下载中断,继续下载

先进入中断文件所在文件夹,continue 继续下载

cd en
s3cmd get --continue s3://yahoo-webscope/L30/en/english-nov15.hash




编辑:孙小北

本文地址: https://www.xiaowangyun.com/wyblog/detail/?id=213

版权归属: www.xiaowangyun.com   转载时请以链接形式注明出处

0 条评论

快来评论

物以类聚

最新评论

2017-10-06

一辈子不长,只有珍惜了,才不至于后悔。

2017-10-06

懂得感恩,才能走得更远。

标签云

归档

取消

感谢您的支持,您的每一次打赏都是一次鼓励!

扫码支持
每一次支持,都是不懈的动力

打开支付宝扫一扫,即可进行扫码打赏哦