ec2-register --snapshot snap-abc123ab --kernel aki-2a42a043 --ramdisk ari-2c42a045 --description "my AMI with two ephemeral disks" --name my-AMI --architecture x86_64 --root-device-name /dev/sda1 -b '/dev/sdb1=ephemeral0' -b '/dev/sdc1=ephemeral1'
This works, but I don't want to have to maintain an AMI for each instance type if I want to maximize my ephemeral disk access. I tried setting this up programmatically during instance run, doing something like:
instanceType = 'm1.large'
instanceTypes = {"m1.small": {"/dev/sdb1": "ephemeral0"},
"m1.large": {"/dev/sdb1": "ephemeral0",
"/dev/sdc1": "ephemeral1"},
"m1.xlarge": {"/dev/sdb1": "ephemeral0",
"/dev/sdc1": "ephemeral1",
"/dev/sdd1": "ephemeral2",
"/dev/sde1": "ephemeral3"},
block_map = BlockDeviceMapping()
block_map.update(instanceTypes[instanceType])
Doing this, I run into an "'str' object has no attribute 'snapshot_id'" error because it seems like BlockDeviceMapping.build_list_params() assumes that each device listed is a an EBSBlockDeviceType object with the snapshot_id field. Am I understanding this correctly and this is just something that boto doesn't support at the moment?
Thanks,
Victor
--
You received this message because you are subscribed to the Google Groups "boto-users" group.
To post to this group, send email to boto-...@googlegroups.com.
To unsubscribe from this group, send email to boto-users+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/boto-users?hl=en.