qemu_disk_create
Creates a fresh QEMU disk image (qcow2 or raw) at a specified path and size, so a virtual machine can boot into it without relying on a pre-existing disk file.
Instructions
Create a fresh disk image via qemu-img create, ready for qemu_boot's disk param.
qemu_boot never creates a disk image itself - disk must already
point at an existing file. This closes that gap: create one here,
then boot straight into it.
size looks like qemu-img's own size grammar: a number optionally suffixed with k/K/M/G/T/P/E, e.g. "10G" or "512M". format must be "qcow2" (default - needed for qemu_snapshot_save/qemu_snapshot_load) or "raw" - qemu_boot's disk_format() auto-detection only tells these two apart, so any other qemu-img format would silently be treated as raw. Fails if path already exists, rather than overwriting it.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"path": "<path>",
"size": "<size>"
},
"name": "qemu_disk_create"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | ||
| size | Yes | ||
| format | No | qcow2 |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |