import type { Metadata } from "next" import { Steps } from "@/components/ui/steps" export const metadata: Metadata = { title: "Import Disk Image to a VM | ProxMenux Documentation", description: "Learn how to import a disk image to a virtual machine in Proxmox VE.", } export default function ImportDiskImageVM() { return (

Import Disk Image to a VM

This script automates the process of importing disk images into Proxmox VE virtual machines (VMs). It simplifies the task of attaching pre-existing disk files to VMs without requiring manual configuration.

What Does This Script Do?

When executed, this script performs the following actions:

  1. Scans for compatible disk images (.img, .qcow2, .vmdk) in the /var/lib/vz/template/images/ directory
  2. Presents a list of available VMs for selection
  3. Allows you to choose one or multiple disk images for import
  4. Lets you select a storage volume in Proxmox for disk placement
  5. Offers options for interface type (SATA, SCSI, VirtIO, IDE) for each imported disk
  6. Provides optional settings like SSD emulation and bootable disk configuration
  7. Imports the selected disk images and attaches them to the chosen VM

Key Steps

Ensure that the disk images you want to import are placed in the /var/lib/vz/template/images/ directory.

Choose the VM where you want to import the disk image(s) from a list of available VMs.

Select the Proxmox storage volume where the imported disk(s) will be placed.

Choose one or more disk images to import from the list of compatible images found in the specified directory.

For each selected image:

  • Choose the interface type (SATA, SCSI, VirtIO, or IDE)
  • Optionally enable SSD emulation (for non-VirtIO interfaces)
  • Decide whether to make the disk bootable

The script will import each selected disk image, showing real-time progress updates.

After import, the script configures the disks in the VM and applies the chosen settings.

What to Expect

Important Notes

This script simplifies the process of importing disk images to VMs in Proxmox VE, making it easy to add pre-existing disks or migrate disks from other environments. It handles the technical details of import and configuration, allowing you to quickly add new storage to your VMs.

) }