Announcement Banner
UNSOLVED

JoshPrice

updated

6 years ago

J

JoshPrice

6 Posts

0

1896

March 30th, 2021 06:00

Ansible modules for PowerMax require the PyU4V python library to be installed

Getting this error when running any playbook. PyU4V is installed and working fine. The playbooks work fine when ran against 'localhost', not when specifying the target host or inventory file, though they are the same node.

"msg": "Ansible modules for PowerMax require the PyU4V python library to be installed. Please install the library before using these modules."
}

  • FoolInTheRain

    2 Intern

    •

    123 Posts

    1550

    1

    Posted March 30th, 2021 07:00

    Can you run again using the -vvv option so there is a more verbose message/info?

  • JoshPrice

    6 Posts

    1541

    0

    Posted March 30th, 2021 08:00

    You convinced me to look though the complete error message again, which I had done dozens of times before, but not thoroughly enough. I resolved this with the ansible_python_interpreter host var for now. Thanks!

     

    [WARNING]: Platform linux on host mysehost is using the discovered Python interpreter at /usr/bin/python, but future installation of another Python interpreter could change the meaning of that path. See https://docs.ansible.com /ansible/2.10/reference_appendices/interpreter_discovery.html for more information.

  • 1424

    0

    Posted April 5th, 2021 12:00

    This the complete yml file, I'm not sure if I'm doing it correctly or not. could you please help me with this?
    ---
    - hosts : localhost
    name : Get the List Masking of the given array
    connection : local
    gather_facts : true
    vars :
    ansible_python_interpreter : /usr/bin/python3
    unispherehost : ' https://XXXX.com/'
    universion : '92'
    verifycert : false
    user : 'XXXX'
    password : 'XXXX'
    serial_no : 'XXXX'

    collections :
    - dellemc.powermax

    tasks :
    - name : List
    dellemc_powermax_gatherfacts :
    unispherehost : 'https://XXXXcom/'
    universion : '92'
    verifycert : false
    user : 'XXXX'
    password : 'XXXX'
    serial_no : 'XXXX'

    gather_subset :
    - mv


  • bmcfeeters

    1 Rookie

    •

    72 Posts

    1405

    2

    Posted April 5th, 2021 13:00

    Hi soc-storage,

    Best starting place would be to view the embedded examples in the docs by running
    ansible-doc dellemc.powermax.dellemc_powermax_gatherfacts

    Or viewing our samples and examples repo on github.
    https://github.com/dell/ansible-storage-automation/tree/master/powermax

    Here is a quick playbook which uses the gather facts module to show a list of masking views...

    #!/usr/bin/env ansible-playbook
    -  name :  Gather PowerMax Facts
       hosts :  localhost
       connection :  local
       gather_facts :  false

       collections :
        -   dellemc.powermax

       tasks :
        -  name :  Gather the masking view list
           dellemc_powermax_gatherfacts :
             serial_no :  "000000000000"
             unispherehost :  "yourhostname"
             user :  "username"
             password :  "password"
             universion :  "92"
             verifycert :  false
             gather_subset :
              -  mv
           register :  pmaxmvlist

        -  debug :  var=pmaxmvlist
  • 1385

    0

    Posted April 5th, 2021 20:00

    Thank you much!. It worked as expected.

    If possible could you please share the playbook for viewing the ansible documentation as well?

    Thanks in advance 

     

  • bmcfeeters

    1 Rookie

    •

    72 Posts

    1351

    1

    Posted April 6th, 2021 06:00

    To view the embedded examples in the documentation simply user the ansible-doc command followed by the module name like this.

    ansible-doc dellemc.powermax.dellemc_powermax_gatherfacts