Skip to content

Commit

Permalink
feat: HCP - Support for booting DPM LPAR ans attaching as compute node (
Browse files Browse the repository at this point in the history
#372)

Support for booting DPM LPAR ans attaching as compute node
Network modes: OSA , RoCE
Storage: FCP DASD

Updated documentation

---------

Signed-off-by: root <[email protected]>
Co-authored-by: root <[email protected]>
  • Loading branch information
veera-damisetti and root authored Jan 20, 2025
1 parent 42370d1 commit 2edd3d5
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 5 deletions.
1 change: 1 addition & 0 deletions docs/set-variables-group-vars.md
Original file line number Diff line number Diff line change
Expand Up @@ -367,6 +367,7 @@
**hcp.data_plane.lpar.nodes.dasd.disk_id** | Disk id for dasd disk to be used for zVM node | 4404
**hcp.data_plane.lpar.nodes.lun** | Disk details of fcp disk to be used for zVM node | 0.0.4404
**hcp.data_plane.lpar.nodes.live_disk.disk_type** | Live disk type for booting LPAR | scsi
**hcp.data_plane.lpar.nodes.live_disk.uuid** | UUID for the live disk | 600507000000000000xxxx
**hcp.data_plane.lpar.nodes.live_disk.devicenr** | devicenr for the live disk | 8001
**hcp.data_plane.lpar.nodes.live_disk.lun** | lun id for the live disk | 40xxxxxxxxxxxxx
**hcp.data_plane.lpar.nodes.live_disk.wwpn** | wwpn for the live disk | 500507630xxxxxxx
Expand Down
13 changes: 9 additions & 4 deletions inventories/default/group_vars/hcp.yaml.template
Original file line number Diff line number Diff line change
Expand Up @@ -170,10 +170,15 @@ hcp:
# Live disk details
live_disk:
disk_type:
devicenr:
lun:
wwpn:
password:
password: ''

uuid: '' # Required only in case of DPM LPAR

# following paramaters are required only in case of classical LPAR
devicenr: ''
lun: ''
wwpn: ''




2 changes: 2 additions & 0 deletions roles/boot_LPAR/templates/boot_lpar.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ def list_of_strings(arg):

#live disk info
parser.add_argument("--livedisktype", type=str, help="Can be of type dasd or scsi", required=True, default='')
parser.add_argument("--livediskuuid", type=str, help="UUID for the live disk image")
parser.add_argument("--devicenr", type=str, help="deviceenr for the live disk image")
parser.add_argument("--netset_ip", type=str, help="network setup ip for the live image")
parser.add_argument("--netset_gateway", type=str)
Expand Down Expand Up @@ -62,6 +63,7 @@ def list_of_strings(arg):
lpar_parameters = {
"boot_params": {
"boot_method" : args.livedisktype.lower(),
"uuid" : args.livediskuuid,
"devicenr": args.devicenr,
'netsetup': {
"mac": None,
Expand Down
3 changes: 2 additions & 1 deletion roles/boot_LPAR_hcp/tasks/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
--initrd http://"{{ hcp.bastion_params.ip }}":8080/initrd.img \
--livedisktype "{{ hcp.data_plane.lpar.nodes[item].live_disk.disk_type }}" \
--devicenr "{{ hcp.data_plane.lpar.nodes[item].live_disk.devicenr }}" \
--livediskuuid "{{ hcp.data_plane.lpar.nodes[item].live_disk.uuid }}" \
--livedisklun "{{ hcp.data_plane.lpar.nodes[item].live_disk.lun }}" \
--livediskwwpn "{{ hcp.data_plane.lpar.nodes[item].live_disk.wwpn }}" \
--netset_ip "{{ hcp.data_plane.lpar.nodes[item].interface.ip }}" \
Expand All @@ -47,4 +48,4 @@
register: agent_name

- name: Approve agents
shell: oc -n {{ hcp.control_plane.hosted_cluster_name }}-agents patch agent {{ agent_name.stdout.split(' ')[0] }} -p '{"spec":{"approved":true,"hostname":"compute-{{ item }}.{{hcp.control_plane.hosted_cluster_name }}.{{ hcp.control_plane.basedomain }}"}}' --type merge
shell: oc -n {{ hcp.control_plane.hosted_cluster_name }}-agents patch agent {{ agent_name.stdout.split(' ')[0] }} -p '{"spec":{"approved":true,"hostname":"compute-{{ item }}.{{hcp.control_plane.hosted_cluster_name }}.{{ hcp.control_plane.basedomain }}"}}' --type merge

0 comments on commit 2edd3d5

Please sign in to comment.