000-221 · Question #54
An AIX LPAR has virtual disks presented by a VIO Server and the administrator would like to determine the size of hdisk0. Which command will show this information?
The correct answer is D. getconf. The getconf command on AIX can query the DISK_SIZE configuration variable for a device, reliably returning the size of virtual disks such as those presented by a VIO Server.
Question
An AIX LPAR has virtual disks presented by a VIO Server and the administrator would like to determine the size of hdisk0. Which command will show this information?
Options
- AIsdev
- BIquervpv
- CIsattr
- Dgetconf
- EIscfq
How the community answered
(62 responses)- A13% (8)
- B2% (1)
- C2% (1)
- D79% (49)
- E5% (3)
Why each option
The getconf command on AIX can query the DISK_SIZE configuration variable for a device, reliably returning the size of virtual disks such as those presented by a VIO Server.
lsdev lists configured devices and their status but does not report device capacity or size attributes.
lquerypv queries LVM physical volume metadata and is not the standard command for reporting raw disk capacity on a virtual disk.
lsattr -El hdisk0 can show the size_in_mb ODM attribute, but this attribute may not be populated for virtual disks presented by a VIO Server, making it unreliable in this context.
The getconf command with the DISK_SIZE parameter (e.g., getconf DISK_SIZE /dev/hdisk0) queries the device directly for its size in megabytes, making it reliable for virtual SCSI disks exposed by a VIO Server. Unlike lsattr, getconf reads actual device geometry rather than relying on ODM attributes that may not be fully populated for virtual disks.
lscfg displays hardware configuration and vital product data but does not report disk capacity in a directly usable form.
Concept tested: AIX getconf command for virtual disk capacity
Source: https://www.ibm.com/docs/en/aix/7.3?topic=g-getconf-command
Topics
Community Discussion
No community discussion yet for this question.