Lquerypv will simply read the data from the disk and display it in a format similar to octal dump (od). In the example below, we see the PVID written to the disk at location 80. You seem to be able to read anything that you point lquerypv at (I tried /etc/motd and read it just fine). This is great for reading the PVID of a logical volume on a vio server that is pretending to be a virtual disk on a client since you can’t see that information with lspv. Lquerypv is also a great command for figuring out where disk access issues are. If lquerypv returns any data, then you can read the disk and it isn’t a reserve issue. If it can’t read any data, and just hangs or returns nothing, then ABSOLUTELY NO OTHER AIX COMMAND WILL WORK. At this point you should stop looking at your filesystems or volume groups and logical volumes. The issue is that you simply can’t read the disks, and you need to either go to the vio server and see if there is a problem there or use lsattr -El hdisk0 to check the scsi reserve (on another system that might be sharing the disk). If you the issue is on your VIO server, or you have direct-attached SAN disks, then ask your SAN administrators to check their stuff. If, however queries against all of our disk hang, especially during an initial install, then maybe your client SAN software is messed up, you could try to remove it and use the MPIO version or just re-install it. The clearest sign of one disk with a reserve lock at the san level is when lquerypv returns nothing and lquerypv against other disks works fine.
# lspv hdisk0 00031691bced4a4e oraclevg active hdisk2 00cdeaeadfcd0ebc oraclevg active hdisk1 00031691bcd549a6 rootvg active # lquerypv -h /dev/hdisk0 00000000 C9C2D4C1 00000000 00000000 00000000 |................| 00000010 00000000 00000000 00000000 00000000 |................| 00000020 00000000 00000000 00000000 00000000 |................| 00000030 00000000 00000000 00000000 00000000 |................| 00000040 00000000 00000000 00000000 00000000 |................| 00000050 00000000 00000000 00000000 00000000 |................| 00000060 00000000 00000000 00000000 00000000 |................| 00000070 00000000 00000000 00000000 00000000 |................| 00000080 00031691 BCED4A4E 00000000 00000000 |......JN........| 00000090 00000000 00000000 00000000 00000000 |................| 000000A0 00000000 00000000 00000000 00000000 |................| 000000B0 00000000 00000000 00000000 00000000 |................| 000000C0 00000000 00000000 00000000 00000000 |................| 000000D0 00000000 00000000 00000000 00000000 |................| 000000E0 00000000 00000000 00000000 00000000 |................| 000000F0 00000000 00000000 00000000 00000000 |................| #
You missed an aspect. lquerypv -h /path/path/core 6b10 80 is a nice way to sometimes catch what was running when a core file is generated
Thanks for you input Maria. I haven’t worked in AIX over 5 years and I am getting a little rusty. Seems like lquerypv is probably pretty similar to octal dump (od).