Automation with Power

 View Only
  • 1.  Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Posted 17 days ago

    Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Hi,

    I am currently using the ibm.power_aix.lvm_facts module to gather information about a particular logical volume (LV) and, inherently, the filesystem on it. This is part of a playbook I'm writing to increase filesystem space based on user-provided input.

    The general workflow is to retrieve the filesystem name, determine the corresponding LV and volume group (VG), and then use the data returned from ibm.power_aix.lvm_facts to get information like VG name, size, and free space. This works well for most use cases.

    However, I noticed that when gathering LV information, the module relies on lsvg -l <vgname>, which returns a limited set of properties. While this is sufficient for many cases, I'm specifically missing the MAX_LPS property that can be found when running lslv <lvname>.

    The info gathered from ibm.power_aix.lvm_facts for LVs is the output of lsvg -l <vgname>:

    "lvinfo": {
            "ansible_facts": {
                "LVM": {
                    "LVs": {
                        "lvname_lv": {
                            "LPs": "2",
                            "PPs": "2",
                            "PVs": "2",
                            "lv_state": "open/syncd",
                            "mount_point": "/fsname",
                            "type": "jfs2",
                            "vg": "vgname"
                        }
                    }
                }

    Currently, I use the shell module to fetch this additional property, but I was wondering if it's possible to enhance the ibm.power_aix.lvm_facts module to include the MAX_LPS field directly. This could be achieved by replacing lsvg -l <vgname> with lslv <lvname> when gathering LV information. The advantage of this is that it would provide a lot of additional useful fields (like MAX_LPS), including the fields above, without requiring extra steps in the playbook.

    The main reason for this request is that, when increasing a filesystem, it is essential to check if the MAX_LPS value for the LV needs to be adjusted. This check ensures that the requested additional space will not exceed the LV's MAX_LPS limit and if it does, then a chlv command could be run to increase this value. Being able to retrieve this directly from ibm.power_aix.lvm_facts would streamline the playbook, eliminating the need to rely on the shell module.

    I would greatly appreciate it if this feature could be considered for future versions of the ibm.power_aix.lvm_facts module.

    Thank you for your time and consideration.



    ------------------------------
    Lance Martincich
    ERP Systems Engineer
    City of Cape Town
    Cape Town
    +27832856514
    ------------------------------


  • 2.  RE: Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Posted 16 days ago

    @Nitish Mishra, an interesting request for the Ansible collection aix. 



    ------------------------------
    Niklas Vosskoetter
    Deputy Team Lead & System Engineer Unix and Cloud Service Power
    ------------------------------



  • 3.  RE: Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Posted 14 days ago

    Thanks for the idea Lance.
    We have implemented it and merged the code here: https://github.com/IBM/ansible-power-aix/pull/614
    You can verify if you want. The enhancement would be available in new release this week (v2.0.3).

    Thanks,

    Nitish



    ------------------------------
    Nitish Mishra
    ------------------------------



  • 4.  RE: Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Posted 13 days ago

    v2.0.3 is released now with this enhancement.



    ------------------------------
    Nitish Mishra
    ------------------------------



  • 5.  RE: Enhancement Request for ibm.power_aix.lvm_facts Module: Include MAX_LPS Information

    Posted 12 days ago

    Excellent.

    Thank you so much Nitish.

    I will download and modify my playbook accordingly.

    Much appreciated.

    Kind regards



    ------------------------------
    Lance Martincich
    ERP Systems Engineer
    City of Cape Town
    Cape Town
    +27832856514
    ------------------------------