IBM Support

Debugging VIOS padmin commands

How To


Summary

Gets lots of information about what goes on behind the covers to aid debugging and correction

Objective

Nigels Banner

Steps

Recently I was running the "lsmap -l" command and it output error messages that were less then useless at the end of the output:

Command did not complete.
"Determine if backing device is a PV or LV or optical." was last subcommand run.
Command did not complete.
Determining device type failed. Command did not complete.
"Determine if backing device is a PV or LV or optical." was last subcommand run.
Command did not complete.
Determining device type failed. Command did not complete.
"Determine if backing device is a PV or LV or optical." was last subcommand run.
Command did not complete.

Absolutely no clues on what command was issuing the warning nor which of the resources had the problem as the error is always the last few lines.

Then fellow ATS member Gareth Coates reminded me about the debugging option that he includes in his IBM Technical University session "Tips and Tricks of the POWER M??????s".  One of the hundred or so tips was how to switch on VIOS padmin user command debugging so you can see the commands that the padmin user is actually running.  I am not sure I should share this with everybody but he covers this in public sessions so I guess it is OK!!  Only use this when you have a error message problem you need to investigate.

At the padmin user prompt type in:

export CLI_DEBUG=33

Don't ask me why 33! Its just magic!

Now when you run a padmin user command it shows you the underlying AIX commands used.

In my case, I was upgrading VIOS to 2.2.2.2 (more in a different blog) and unloaded the virtual optical media  from the LPARs using the .iso images to boot Red Hat, SUSE Linux and beta AIX versions but had forgotten to also remove the vtopt1, vtopt2 devices (it is in the Release notes but I skipped that part).

Anyway, running the lsmap -all command now outputs the AIX commands it is using, for example:

AIX: "lsdev -C -l vhost5 -F "physloc""
AIX: "lsdev -p vhost5 -F "name" | wc -l -c"
AIX: "lsdev -p vhost5 -F "name""

So I run these commands as the root user  (lsmap -all generates this set of command for every resource so there are dozens) one at a time and find the one with the problem. In my case, I realise "oops! I should have removed those vtoptN devices!"  Once deleted (for example:  rmdev -dev vtopt2) lsmap -all then work without warnings and I can continue with the VIOS upgrade.

I hope this blog helps you investigate problem padmin commands and thank you Gareth, cheers, Nigel

Additional Information


Other places to find Nigel Griffiths IBM (retired)

Document Location

Worldwide

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG10","label":"AIX"},"Component":"","Platform":[{"code":"PF002","label":"AIX"}],"Version":"All Versions","Edition":"","Line of Business":{"code":"LOB08","label":"Cognitive Systems"}},{"Business Unit":{"code":"BU054","label":"Systems w\/TPS"},"Product":{"code":"HW1W1","label":"Power -\u003EPowerLinux"},"Component":"","Platform":[{"code":"PF016","label":"Linux"}],"Version":"All Versions","Edition":"","Line of Business":{"code":"","label":""}},{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Component":"","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"All Versions","Edition":"","Line of Business":{"code":"LOB57","label":"Power"}}]

Document Information

Modified date:
03 July 2023

UID

ibm11117551