PowerVC

PowerVC

Connect, learn, share, and engage with IBM Power.

 View Only
Expand all | Collapse all

PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

  • 1.  PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Thu March 16, 2023 01:00 PM

    When running the  powervc-opsmgr inventory -c "name"

    I get an error i am unable to resolve: I am using my userid that has sudo permissions. I tried as sudo command from my user login and also tried from sudo to root. At this time our linux team is not happy to give me root password to install. I am unsure what is incorrect in the intial setup that is causing ssh key errors. I have generated Keys and they are in the default locations. It seems like the keys need to be put in some config file for the powervc-opsmgr inventory script to find.

    ERROR details:

                            PowerVC Inventory - "name"                       |
    +--------------------------------------------------------------------------------+
            Cluster Name              : "name"
            Cluster ID                : f90e55a1-be2c-4c28-a274-e76e987f4fe7
            Install Method            : legacy
            Edition                   : private_cloud
            Firewall Config           : False
            Login User                : "mysudouserid"
            Sudo User                 : True
            Virtual IP                : "linux ip address"
            Hosts                     : "name"
    +--------------------------------------------------------------------------------+
    |                  *** End of PowerVC Inventory - "name" ***                  |
    +--------------------------------------------------------------------------------+

    Establishing passwordless connection

    PLAY [{{ playbook_task_names.configure_ssh_keys }}] ****************************

    TASK [Gathering Facts] *********************************************************
    Thursday 16 March 2023  11:55:08 -0500 (0:00:00.065)       0:00:00.065 ********
    fatal: [name]: FAILED! => {"msg": "Missing sudo password"}

    NO MORE HOSTS LEFT *************************************************************

    PLAY RECAP *********************************************************************
    "name"                  : ok=0    changed=0    unreachable=0    failed=1    skipped=0    rescued=0    ignored=0

    Thursday 16 March 2023  11:55:09 -0500 (0:00:01.172)       0:00:01.238 ********
    ===============================================================================
    Gathering Facts --------------------------------------------------------- 1.17s
    SSH Key exchange failed at, 2023-03-16 11:55:10.
     Refer to
     /opt/ibm/powervc-opsmgr/ansible/artifacts/powervc-opsmgr_"name"_ssh_key_xchg_20230316_115508/stdout
     for more details.



    ------------------------------
    Karen Van Gogh
    Jack Henry and Associates
    kvangogh@jackhenry.com
    ------------------------------


  • 2.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Fri March 17, 2023 06:36 AM

    Hi, have you configured the sudoers correctly:

    https://www.ibm.com/docs/en/powervc/2.1.0?topic=environment-configure-sudo-user



    ------------------------------
    Stuart Cunliffe
    ------------------------------



  • 3.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Fri March 17, 2023 08:44 AM

    Yes the login i use has sudo and sudo works fine. The sudo userid being used i even tried setting up with passwordless and that had the same results. 

    The inventory scripts seems to be hanging up trying to log onto the virtual using my login id and password it says password is missing ( it is not missing) Then it has a problem trying to setup passwordless login.

    Is the script trying to do something with root login? our company policy is to not allow root login on Linux virtuals all user logins have to sudo to root.  



    ------------------------------
    Karen Van Gogh
    Jack Henry and Associates
    kvangogh@jackhenry.com
    ------------------------------



  • 4.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Tue March 21, 2023 03:45 PM

    In the previous versions of the Later versions of PowerVC using Ops Mgr it was a requirement that you can ssh root@servername into the Linux server that the powerVC software was being installed on. As stated company Policy is no root ssh all users mush ssh as their userid then sudo to root. When running the command powervc-opsmgr inventory -c "name"

    I put in my userid and my password however it errors out as if its not using my userid or my password and trying to use root.

    I have a case open with IBM support on this but have had no response for  5 days to the exact same question. 

    Is Ansible trying to ssh root@servername back to the linux virtual i am doing all this setup on?



    ------------------------------
    Karen Van Gogh
    Jack Henry and Associates
    kvangogh@jackhenry.com
    ------------------------------



  • 5.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Fri March 24, 2023 09:31 AM

    Hi Karen,

    sorry about the late response

    PowerVC doesn't use root as a login id if its not specified while creating the inventory.

    can you please share the version of PowerVC you're trying with.

    and please try again after adding the following line at the end of /etc/sudoers 

    mysudouserid ALL=(ALL) NOPASSWD: ALL



    ------------------------------
    Nimesh Krishnani
    ------------------------------



  • 6.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Fri March 24, 2023 01:19 PM

    Thank you for the tip i finally got one of the Linux admins to work with me (I am not on the team that does Linux admin so i do not mess with their configuration)

    Our setup is a little more enterprise linux standardized and they do not just use /etc/sudoers.

    I was able to create the necessary file for my userid in the proper directory path and then the command worked fine.

    Thank you this got us to the right team and then right setup.

     

    Karen Van Gogh |  Sys/Ntwk Admstr,Advsry | Corporate Systems – POWER Systems Administration | Jack Henry & Associates, Inc.®

    8985 Balboa Ave  | San Diego CA 92123 | Ph. 619-682-3325 |internal extension  x763325 | CELL: 619-318-0416 |  kvangogh@jackhenry.com

     






  • 7.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Thu March 23, 2023 03:35 PM

    any clue IBM on how to stop the powervc ops manager from trying to ssh as root back into the single node server i am installing on??????



    ------------------------------
    Karen Van Gogh
    Jack Henry and Associates
    kvangogh@jackhenry.com
    ------------------------------



  • 8.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Fri March 24, 2023 01:16 PM

    We figured it out with a little help from IBM. Our sudoers setup is not all done in /etc/sudoers we were able to create the proper file for my id and was able to get the inventory command to run 



    ------------------------------
    Karen Van Gogh
    Jack Henry and Associates
    kvangogh@jackhenry.com
    ------------------------------



  • 9.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Sun March 10, 2024 02:21 PM

    I am encountering this same issue.
    We do not put accounts into /etc/sudoers, we create files in /etc/sudoers.d with accounts for sudo access.
    Can you share what was done to get this working?



    ------------------------------
    Demian Phillips
    ------------------------------



  • 10.  RE: PowerVC inventory setup script run error SSH Key exchange failed at, 2023-03-16 11:26:22

    Posted Sun March 10, 2024 03:51 PM

    Message 5 is the fix...
    Wish we didn't have to give it blanket nopassword for all commands and have it in the man sudoers file.



    ------------------------------
    Demian Phillips
    ------------------------------