'AWS ec2 import-instance error-No valid partitions. Not a valid volume.[Client error]
I am trying to import a SO VMDK file(OVA/OVF) of Ubuntu server 14.04 to AWS ,But facing the below error
even though the machine seems to have proper partitioning and volumes
This happens only in case of Ubuntu server, while Windows server machines are successfully imported.I am trying to import using the ec2-api-tools only.
Solution 1:[1]
I had similar problem with OVA images exported from VirtualBox. In my case converting it to raw image format worked. So if you are using VirtualBox, import the OVA to it, and then convert VDI storage drive to raw. For example:
VBoxManage clonehd "/mnt/b/VirtualBox VMs/ub.vdi" ./ub.img --format raw
Then you upload ub.img to S3, and use that in your containers.json file for aws ec2 import-image command. For example:
[
{
"Description": "My Server OVA",
"Format": "raw",
"Url": "s3://<your-s3-bucket>/ub.img"
}
]
The command:
aws ec2 import-image --description "My server VM" --disk-containers "file:///./containers.json"
and to monitor the import process:
aws ec2 describe-import-image-tasks --import-task-ids <import-id-from-previous-command>
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Marcin |


