【问题标题】:ec2-automate-backup error in describe volumes描述卷中的 ec2-automate-backup 错误
【发布时间】:2015-09-23 00:10:39
【问题描述】:

我在尝试运行 ec2-automate-backup-awscli.sh 时遇到错误。我看到https://github.com/colinbjohnson/aws-missing-tools/issues/88 描述了一个类似的问题,但我正在使用cron-primer.sh.aws 文件并且仍然收到此错误。这是我得到的输出。

ec2-user:~/scripts/ec2-automate-backup$ ./ec2-automate-backup-awscli.sh -v "vol-07e1a916" -c ./cron-primer.sh

A client error (InvalidVolume.NotFound) occurred when calling the DescribeVolumes operation: The volume 'vol-07e1a916' does not exist.
An error occurred when running ec2-describe-volumes. The error returned is below:
<nothing here>

但是当我运行 aws ec2 describe-volumes 时,我可以看到音量。

ec2-user:~/scripts/ec2-automate-backup$  aws ec2 describe-volumes
{
    "Volumes": [
        {
            "AvailabilityZone": "us-west-2a", 
            "Attachments": [
                {
                    "AttachTime": "2015-02-25T01:34:00.000Z", 
                    "InstanceId": "i-da56b1d7", 
                    "VolumeId": "vol-07e1a916", 
                    "State": "attached", 
                    "DeleteOnTermination": false, 
                    "Device": "/dev/xvda"
                }
            ], 
            "Tags": [
                {
                    "Value": "true", 
                    "Key": "Backup-Daily"
                }
            ], 
            "Encrypted": false, 
            "VolumeType": "gp2", 
            "VolumeId": "vol-07e1a916", 
            "State": "in-use", 
            "Iops": 24, 
            "SnapshotId": "snap-f518b274", 
            "CreateTime": "2015-02-25T01:34:00.281Z", 
            "Size": 8
        }
    ]
}

【问题讨论】:

  • 您解决了这个问题吗?我目前遇到了同样的问题。
  • @AaronDobbing 刚刚发布了答案

标签: amazon-web-services amazon-ec2 ec2-api-tools


【解决方案1】:

我通过在命令行中明确设置区域解决了这个问题。

ec2-user:~/scripts/ec2-automate-backup$ ./ec2-automate-backup-awscli.sh -v "vol-07e1a916" -c ./cron-primer.sh -r "us-west-2"

【讨论】:

  • 多么奇怪 - 我在 .aws 文件中明确设置了区域。但是这行得通 - 谢谢!
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2017-03-16
相关资源
最近更新 更多