hmc_provision_lpar
Provision a new LPAR end-to-end with a single call: create it, add network and vSCSI adapters, map disk storage, and power on, after validating preconditions.
Instructions
Provision a new LPAR end-to-end: create, add network adapter, add vSCSI adapter, map disk storage, and power on — in a single call.
Always validates preconditions first (name uniqueness, VLAN existence,
volume-group existence). Pass dry_run=True to run only the
precondition checks without creating anything; the result will show each
step as {"status": "dry_run"}.
On partial failure the completed steps are reported as "ok", the
failed step as "error", and remaining steps as "skipped".
No automatic rollback is performed — clean up manually with
hmc_delete_lpar / hmc_delete_adapter as appropriate.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Name for the new LPAR. Must be unique across the HMC. | |
| dry_run | No | When ``True``, run precondition checks only — no LPAR is created. | |
| vg_uuid | No | UUID of the VolumeGroup to validate. When supplied, the tool checks the VG exists on *vios_uuid* before proceeding. | |
| power_on | No | Submit a PowerOn job after provisioning (default ``True``). | |
| max_vcpus | No | ||
| vios_slot | Yes | Virtual slot number of the VIOS server adapter. | |
| vios_uuid | Yes | UUID of the VIOS that will host the vSCSI server adapter and the storage mapping. | |
| max_memory | No | ||
| min_memory | No | Memory bounds in MiB. Defaults: 256 / 4096 / 8192. | |
| port_vlan_id | Yes | PVID for the Virtual Ethernet network adapter (must match an existing VirtualNetwork on the system). | |
| storage_kind | No | ``"VirtualDisk"`` (default) or ``"PhysicalVolume"``. | VirtualDisk |
| storage_name | Yes | Name of the VirtualDisk (logical volume) or PhysicalVolume to map. | |
| desired_vcpus | No | Shared-processor virtual CPU counts. Defaults: 1 / 2. | |
| desired_memory | No | ||
| partition_type | No | Partition type: ``"AIX/Linux"`` (default), ``"OS400"``, or ``"Virtual IO Server"``. | AIX/Linux |
| vios_partition_id | Yes | Numeric partition ID of the VIOS (for the vSCSI pairing). | |
| system_name_or_uuid | Yes | Target managed system — either a SystemName or UUID. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||