I wrote couple of blogs about :
Checking the LPARs in a phyiscal machines from the HMC CLI
And Checking the connected physical machines to HMC using the CLI.
For the sake of the simplicity and to quickly get the desired information,I found a one-command line and (my friend Sakker,the owner of www.how-2-know.com ) edited it to make it visually easier to read and understand!
hscroot@myhmc:~>for m in $(lssyscfg -r sys -F name); do echo "......................";echo "Physical Machine ===> $m";echo "--------------" ; lssyscfg -r lpar -m $m -F name:state ; done
This command gives you the name of the Physical Machines and the name of the LPARs withing each one!