The idea and implementation path of this article:
1. Install the Virtual Box virtual software on the mac (Big Sur) computer
2. Download the mirror file from the official website, address: https://www.kali.org/get-kali/#kali-virtual-machines
kali-linux-2022.1-virtualbox-amd64
3. Install kali in the Virtual Box software under mac, as shown in the figure after completion:
4. Next, if you want to import the image in Tencent Cloud, you must enter the installed kali system and install cloud-init.
Document: https://cloud.tencent.com/document/product/213/12587
Here is the method of manually downloading the green version of the cloud-init package in the article .
Note: Before installation, it is recommended to manually create an account with root privileges, and configure the ssh self-startup, and you can log in with a password; once the virtual machine restarts, the cloud-init program will change the root password and cannot log in.
5. Shut down the virtual machine and perform the export operation:
The ova file is explained as follows:
OVA (Open Virtualization Appliance: Open Virtualization Appliance) is a single compressed file that contains all the files in the OVF file package, that is, a compression mode of OVF, with a suffix of .ova. OVF (Open Virtualization Format) is a folder that contains files that are necessary to define and deploy virtual machines. OVF generally contains three file types, namely .ovf file, .mf file, and .vmdk file.
.ovf is an XML descriptor that defines metadata information about the virtual machine, such as name, hardware requirements, and contains references to other files in the OVF package.
The .mf file is a collection of some file SHAs, the purpose is to prevent the image file from being illegally tampered with.
The .vmdk file contains virtual disk resources. The OVF package can contain multiple .vmdk files to create different disk images.
This article introduces the operation method of importing OVF and OVA files into the cloud platform.
7. Open the Tencent Cloud backend, and after uploading the vmdk in the object storage, copy the temporary link of its address for use in the next image import
8. Enter the image on the left side of the host management interface and import the image, as shown below:
If nothing else, the import can be successful. Using the successful mirror to create a new server, you can normally obtain the IP address and log in, even if it is successful.