Description: Some customers require Canaries within Alibaba Cloud. Whilst we don't officially support Alibaba Cloud, the following guide will have a Canary up and running in no-time.
Grabbing the VMX disks from your Canary Console
Step 1:
Log in to your Console.
Step 2:
Click the + icon and click Add Canary.
Step 3:
Click Add VMware Canary.
Step 4:
Click Download and then Click VMX to begin the download.
Converting VMDK Disks to QCOW2
We'll now need to convert your Canary's disks to QCOW2 for upload to Alibaba Cloud.
For this process we'll be converting the disks on an Ubuntu host.
Note: Reach out to support@canary.tools who can send over pre-converted disks to save a step.
Step 5: Install Qemu utils and Convert
sudo apt-get install qemu-utils
Unzip the archive containing your Canary disks.
$ unzip VirtualCanary_711e9fe1_Template_VMX.zip
Archive: VirtualCanary_711e9fe1_Template_VMX.zip
creating: VirtualCanary-711e9fe1-vmx/
inflating: VirtualCanary-711e9fe1-vmx/VirtualCanary-711e9fe1-disk2.vmdk
inflating: VirtualCanary-711e9fe1-vmx/VirtualCanary-711e9fe1-disk1.vmdk
inflating: VirtualCanary-711e9fe1-vmx/VirtualCanary-711e9fe1.vmx
inflating: VirtualCanary-711e9fe1-vmx/README.txt
Convert Disk2 from VMDK to QCOW2
qemu-img convert -p -f vmdk -O qcow2 VirtualCanary-abc123-disk1.vmdk VirtualCanary-abc123-disk1.qcow2 qemu-img convert -p -f vmdk -O qcow2 VirtualCanary-abc123-disk2.vmdk VirtualCanary-abc123-disk2.qcow2
Deploying a Canary VM to Alibaba Cloud
Step 6: Create and upload the QCOW2 images to an Object Storage Service (OSS) bucket
Head over to Object Storage Service and select "Buckets".
Here we'll create an OSS bucket with the default parameters to host our previously created qcow2 disk images.
Once you've created your bucket, "Upload" both of the previously converted images.
Step 7: Create a custom image from the disks uploaded to your OSS bucket above
Head over to Elastic Compute Service and select images, then click on the "import image" link.
Clicking on the "import button" lists some requirements. We've already completed steps 1-2, so we progress to Step 3 and click on "Authorize". This allows you to pull the disk images from the OSS bucket we created earlier. Now that we're authorized we can go ahead and enter the relevant parameters to configure the custom image.
The following parameters are required to be configured:
- OSS Object Address
- Grab the URL of disk1 from your OSS bucket
- Image Name
- The name you would like to call the image ("canary_os")
- Operating System
- Linux/Others Linux works here
- This can be left as the default x86_64
- System Disk Size (GiB)
- 10GB
- Image Format
- QCOW2
- Add Data Disk Image (Do not skip this step!)
- Add disk2 from the bucket as QCOW2 and use the minimum disk size of 5GB
Step 8: Create a Canary instance
Head over to Elastic Compute Service and select "Create instance".
Canaries are pretty light weight so all you will need here is an instance type that supports at least 1vCPU and 2GB memory.
Once the image type has been selected, specify your custom image and reduce your disks to the minimum size of 20GB.
Follow the wizard, Select "Next", "Preview" and finally click on "Create Instance".