首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 其他教程 > 系统运维 >

s3cmd 凭借split分批实现文件同步备份

2013-03-26 
s3cmd 借助split分批实现文件同步备份一直都在使用s3cmd工具对服务器进行同步备份,可是最近却出了点小问题

s3cmd 借助split分批实现文件同步备份
一直都在使用s3cmd工具对服务器进行同步备份,可是最近却出了点小问题,查证之后,发现是服务器文件打包后越来越大,达到了7G左右,导致s3cmd无法将其上传至amazon云端;
解决办法就是需要将打包的档案借助split先进行切割,在进行上传;
命令大致如下:

~/demo$ s3cmd sync --dry-run --exclude '*.txt' --include 'dir2/*' ./  s3://my-bucket-name/exclude: dir1/file1-1.txtupload: ./dir2/file2-2.txt -> s3://my-bucket-name/dir2/file2-2.txt

4.2.2、从文件中载入排除或包含规则。(--exclude-from、--include-from)
    s3cmd sync  --exclude-from pictures.exclude ./  s3://my-bucket-name/

pictures.exclude 文件内容
# Hey, comments are allowed here ;-)
*.jpg
*.gif

4.2.3、排除或包含规则支持正则表达式

    --rexclude 、--rinclude、--rexclude-from、--rinclude-from


本文链接http://blog.csdn.net/shangxiaoxue/article/details/8715639

热点排行