Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to attach a volume to an instance using the cli:

ec2-attach-volume 'vol-id' -i `curl` -d /dev/sdh

But this fails with the message:

|            Code            |                   Message                   |
| InvalidInstanceID.NotFound | The instance ID 'i-myid' does not exist |

The instance id is actually the correct id for that instance so I am not sure what it is complaining about.

My ami is based off the jaunty image and is running in the same availability zone as my volume (eu-west-1a).

share|improve this question

1 Answer 1

up vote 3 down vote accepted

Because I was using the EU data centre I needed to specify the region:

ec2-attach-volume 'vol-id' -i curl -d /dev/sdh --region eu-west-1

Also I was using this tool http://www.timkay.com/aws/ which proxies calls to ec2-attach-volume. In doing that it also changes the way --region works. The correct syntax in this case is to use --region=eu

Hope this helps someone else!

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.