AzCopy-模式中间的通配符? [英] AzCopy - Wildcards In Middle Of Pattern?

查看:75
本文介绍了AzCopy-模式中间的通配符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

场景:-位于Azure存储中的备份-包含超过100,000个文件夹的文件夹-每个文件夹的内部都有以下格式的文件:MM-DD-YYYY_randomnumber.wav.gz

Scenario: -Backups located in Azure storage -Folder containing >100,000 folders -Inside of each folder is a file in the following format: MM-DD-YYYY_randomnumber.wav.gz

我们需要从两个月内提取所有文件(未知数量,大概30,000-40,000).

We need to pull all files from two months (unknown number, likely 30,000-40,000).

看起来像AzCopy是我们需要完成的工具.

Looks like AzCopy is the utility we need to accomplish this.

以下命令是我想像的那样工作的方式,但无法做到这一点:

The following command is how I'd imagine it would work, but am unable to get it to do so:

AzCopy /Source:https://path.to.files/path/to/files /Dest:C:\test /SourceKey:key /Pattern:11-*-2016_*.wav.gz /S

以下内容将获取父文件夹(其名称与其中的文件相同,只是没有.wav.gz扩展名),这不是理想的选择,但可行.但是,这会抓取多年的文件:

The following grabs the parent folder (it's named the same as the files within them, just without the .wav.gz extension), which wouldn't be ideal, but would be workable. However, this would grab files from multiple years:

AzCopy /Source:https://path.to.files/path/to/files /Dest:C:\test /SourceKey:key /Pattern:11 /S

我已经阅读了文档,其中提到通配符可以在某些情况下使用,但在其他情况下不能使用,但是我不确定它的含义.

I've read the documentation, and it mentions wildcards can be used in some circumstances but not others, but I'm not entirely sure what it's meaning.

谢谢!

推荐答案

我知道这个问题已经提出很长时间了,但是azcopy中现在有一个--include-pattern标志,可让您创建更具体的通配符模式就像原始帖子中建议的那样.

I know this question has been long since asked, but there is now a --include-pattern flag in azcopy that will allow you to create more specific wildcard patterns like the one suggested in the original post.

这篇关于AzCopy-模式中间的通配符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆