gp_toolkit Administrative Schema: The Greenplum Database includes the gp_toolkit schema, which collects system information through log files and operating system commands. You can run a query against the gp_toolkit to quickly view free disk space. Results are shown in bytes.
[gpadmin@mdw ~]$ psql -d zwcdb -U zhongwc -h 192.168.1.23 -W
Password for user zhongwc:
psql (8.2.15)
Type "help" for help.
zwcdb=# select dfhostname, dfspace,dfdevice from gp_toolkit.gp_disk_free order by dfhostname;
dfhostname | dfspace | dfdevice
------------+----------+------------
sdw1 | 51692604 | /dev/sdb1
sdw2 | 51692588 | /dev/sdb1
(2 rows)
[gpadmin@mdw config]$ gpssh -f seg_hosts df -TH
[sdw1] Filesystem Type Size Used Avail Use% Mounted on
[sdw1] /dev/mapper/VolGroup00-LogVol00
[sdw1] ext3 54G 3.7G 47G 8% /
[sdw1] /dev/sda1 ext3 104M 14M 85M 14% /boot
[sdw1] tmpfs tmpfs 1.1G 0 1.1G 0% /dev/shm
[sdw1] /dev/sdb1 xfs 54G 727M 53G 2% /data
[sdw2] Filesystem Type Size Used Avail Use% Mounted on
[sdw2] /dev/mapper/VolGroup00-LogVol00
[sdw2] ext3 54G 3.7G 47G 8% /
[sdw2] /dev/sda1 ext3 104M 14M 85M 14% /boot
[sdw2] tmpfs tmpfs 1.1G 0 1.1G 0% /dev/shm
[sdw2] /dev/sdb1 xfs 54G 727M 53G 2% /data
查看本栏目更多精彩内容:http://www.bianceng.cnhttp://www.bianceng.cn/database/storage/