hmc_create_lpar
Create a new logical partition on a managed system, defining processors, memory, and virtual slots. The LPAR is created powered off so you can configure storage and network before boot.
Instructions
Create a new LPAR on a managed system.
system_name_or_uuid: the target managed system — accepts either a
SystemName (e.g. "Server-9080-M9S-SN12345") or a UUID (find it
with hmc_systems). Memory values are in MiB. By default a
shared-processor partition is created; set dedicated=True for dedicated
CPUs (then procs are whole CPU counts). For shared partitions, procs are
processing units (may be fractional, e.g. 0.5) and vcpus are virtual
processor counts.
The partition is created powered off with a default profile; storage, network and boot settings still need to be configured (via the HMC UI or profile edits) before it can boot an OS. This creates a real partition — confirm name/system_name_or_uuid before calling.
Raises ValueError if a partition with the given name already exists on any managed system — names must be unique across the HMC.
partition_type must be one of: 'AIX/Linux', 'OS400', 'Virtual IO Server'.
os_type: target OS — aix, linux, or ibmi.
keylock: initial keylock position — normal, manual, or auto.
max_virtual_slots: maximum number of virtual I/O slots.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | ||
| keylock | No | ||
| os_type | No | ||
| uncapped | No | ||
| dedicated | No | ||
| max_procs | No | ||
| max_vcpus | No | ||
| min_procs | No | ||
| min_vcpus | No | ||
| max_memory | No | ||
| min_memory | No | ||
| partition_id | No | ||
| desired_procs | No | ||
| desired_vcpus | No | ||
| desired_memory | No | ||
| partition_type | No | AIX/Linux | |
| max_virtual_slots | No | ||
| system_name_or_uuid | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |