我在 CloudWatch 中有一些日志,每天我都会不断收到新日志。现在,我想将今天和昨天的日志存储在 Cloud Watch 本身中,但必须将 2 天前的日志移动到 S3。
我尝试通过以下链接使用 CLI:
http://docs.aws.amazon.com/cli/latest/reference/logs/create-export-task.html
在此链接中,提到了两个选项: -- from和--to
--from option only exports the logs after that time.
--to option does not export the logs after that time.
通过使用这些,我可以实现我的要求,但是,随着 --from 和 --to 选项值的变化,我必须每天输入命令。
那么,除了每天输入命令之外,是否有替代选项可以每天完成工作而无需我干预?