Sync with Develop #7

Merged
chris merged 38 commits from develop into main 2025-01-08 16:44:32 -05:00
6 changed files with 32 additions and 7 deletions
Showing only changes of commit fa7f4d0e31 - Show all commits

25
bigboot-wip.yml Normal file
View File

@ -0,0 +1,25 @@
---
- name: Perform logical volume and boot parition resizing as needed
hosts: all
become: true
gather_facts: true
strategy: free
vars_files:
- bigboot_vars.yml
tasks:
- name: Cleanup from any previous executions
ansible.builtin.import_tasks: tasks/cleanup.yml
# - name: Shrink the logical volume to support /boot expansion
# ansible.builtin.import_role:
# name: infra.lvm_snapshots.shrink_lv
# vars:
# shrink_lv_devices:
# - device: "/dev/mapper/vgapplog-lvapplog"
# size: "52156661760"
# - name: Expand the /boot partition as requested
# ansible.builtin.import_role:
# name: infra.lvm_snapshots.bigboot

View File

@ -25,7 +25,7 @@
bigboot_execute_shrink_lv: "{{ bigboot_execute_shrink_lv }}"
bigboot_adjacent_lvm_device: "{{ bigboot_adjacent_lvm_device }}"
bigboot_lv_shrink_size: "{{ bigboot_lv_shrink_size | int }}"
bigboot_size: "{{ bigboot_size }}"
bigboot_partition_size: "{{ bigboot_partition_size }}"
bigboot_skip_rear_backup: "{{ bigboot_skip_rear | default('false') }}"
per_host: false
aggregate: false

View File

@ -17,6 +17,6 @@ collections:
version: 1.5.4
- name: infra.lvm_snapshots
version: 2.0.2
version: 2.1.0
...

View File

@ -19,7 +19,7 @@
- name: Capture required expansion space
ansible.builtin.set_fact:
bigboot_expansion_diff:
"{{ bigboot_size_target | human_to_bytes - bigboot_boot_partsize | human_to_bytes }}"
"{{ bigboot_partition_size | human_to_bytes - bigboot_boot_partsize | human_to_bytes }}"
- name: Convert size difference to MB
ansible.builtin.set_fact:
@ -27,7 +27,7 @@
- name: Set bigboot size 4k aligned
ansible.builtin.set_fact:
bigboot_size: "{{ bigboot_size_expansion_mb[:-2] | int | get_block_size_up }}"
bigboot_partition_size: "{{ bigboot_size_expansion_mb[:-2] | int | get_block_size_up }}"
- name: Validate if we need to expand boot
block:
@ -48,4 +48,4 @@
- name: Expansion of /boot required
ansible.builtin.debug:
msg: "Will need to expand /boot by an additional {{ bigboot_size }}."
msg: "Will need to expand /boot by an additional {{ bigboot_partition_size }}."

View File

@ -87,7 +87,7 @@
bigboot_lv_pe_size_in_mb:
"{{ bigboot_lv_vg_free_pe | regex_replace('i|\\s+|<', '') | human_to_bytes | human_readable(unit='M') }}"
- name: Verify if there's available PE or not and execute Shrink_LV
- name: Verify available PE for the volume group
block:
- name: Set flag for Shrink_LV execution
ansible.builtin.set_fact:

View File

@ -1,7 +1,7 @@
---
ansible_ssh_retries: 10
bigboot_size_target: 1G
bigboot_partition_size: 1.5G
bigboot_post_reboot_delay: 70
bigboot_reboot_timeout: 1800