Skip to main content

qhost

View host status, resources, and load information in the cluster.


Options

Supported Options

OptionRequires ValueRange/ValuePurposeMain Differences
(default)NoNoneShow basic status and resource info for all hosts.No difference
-FOptionalResource list (comma-separated)Show all or selected resource attributes (25 total).m_topology and m_topology_inuse are dummy "NONE".
-hYesHost list (comma-separated)Show only specified hosts; supports * wildcard.No difference
-jNoNoneShow job info running on hosts.Only running jobs; master column is dummy "MASTER".
-lYesResource expressionShow hosts that satisfy resource requirements.Supports arch=, num_proc=, mem_total=, mem_free=.
-cbNoNoneShow core binding columns (default behavior).NSOC/NCOR/NTHR columns shown by default.
-ncbNoNoneSuppress core binding columns (NSOC, NCOR, NTHR).No difference
-qNoNoneShow queue instances on hosts.Queue type is dummy "BIP"; reserved slots are dummy 0.
-uYesUser nameShow only hosts running jobs for the user.No difference
-xmlNoNoneOutput in XML.XML schema differs slightly from native SGE.
-helpNoNoneShow help.Detailed help implemented.

Default Output Fields

FieldDescriptionMain Differences
HOSTNAMEHost nameFirst line is global and all fields are -.
ARCHHost architecture (e.g. lx-amd64)Offline nodes show -.
NCPUCPU countOffline nodes show -.
NSOCSocket countOffline nodes show - (hidden with -ncb).
NCORCores per socketOffline nodes show - (hidden with -ncb).
NTHRThreads per coreOffline nodes show - (hidden with -ncb).
LOADAverage loadTwo decimals; offline nodes show -.
MEMTOTTotal memoryWith unit (G/M); offline nodes show -.
MEMUSEUsed memoryWith unit (G/M); offline nodes show -.
SWAPTOTotal swapNo unit; offline nodes show -.
SWAPUSUsed swapNo unit; offline nodes show -.

Resource Attributes for -F

Supports 25 resource attributes with hl: (host level) prefix:

ResourceDescriptionFormatMain Differences
archHost architectureStringNone
num_procCPU countFloat (6 decimals)None
mem_totalTotal memoryWith unit GNone
swap_totalTotal swapNo unitNone
virtual_totalTotal virtual memory (mem + swap)With unit GNone
m_topologyCPU topology stringStringDummy "NONE"
m_socketSocket countFloat (6 decimals)None
m_coreCore countFloat (6 decimals)None
m_threadThread countFloat (6 decimals)None
load_avgAverage loadFloat (6 decimals)None
load_shortShort load (15s)Float (6 decimals)From fsched r15s
load_mediumMedium load (1m)Float (6 decimals)From fsched r1m
load_longLong load (15m)Float (6 decimals)From fsched r15m
mem_freeFree memoryWith unit GNone
swap_freeFree swapNo unitNone
virtual_freeFree virtual memoryWith unit GNone
mem_usedUsed memoryWith unit GNone
swap_usedUsed swapNo unitNone
virtual_usedUsed virtual memoryWith unit GNone
cpuCPU utilization (%)Float (6 decimals)Calculated from load/ncpu
m_topology_inuseCPU topology in useStringDummy "NONE"
np_load_avgNormalized average loadFloat (6 decimals)load/ncpu
np_load_shortNormalized short loadFloat (6 decimals)r15s/ncpu
np_load_mediumNormalized medium loadFloat (6 decimals)r1m/ncpu
np_load_longNormalized long loadFloat (6 decimals)r15m/ncpu

Output for -j

Shows jobs running on each host under the host line:

FieldDescriptionMain Differences
job-IDJob IDNone
priorJob priority (0–1)None
nameJob nameNone
userJob ownerNone
stateJob stateOnly running jobs (r)
submit/start atSubmit/Start timeFormatted output
queueQueue@hostFormat: queue@host
masterMaster/Slave indicatorDummy "MASTER"
ja-task-IDArray task IDEmpty for non-array jobs

Output for -q

Shows queue instances under each host line:

FieldDescriptionMain Differences
queuenameQueue nameNone
qtypeQueue typeDummy "BIP"
used/reserved/totalUsed/Reserved/Total slotsreserved is dummy 0
statesQueue state codeMapped from node states

Queue state codes:

  • (empty) - normal
  • a - alarm (node DOWN/DRAIN/FAIL)
  • u - unavailable (node unavailable)
  • d - disabled (node DRAIN)
  • E - error (node error state)

Examples

Example 1: Show basic info for all hosts

qhost

Sample output:

HOSTNAME                ARCH         NCPU NSOC NCOR NTHR  LOAD  MEMTOT  MEMUSE  SWAPTO  SWAPUS
----------------------------------------------------------------------------------------------
global - - - - - - - - - -
node01 lx-amd64 16 2 8 1 2.35 31.3G 12.5G 8192 1024
node02 lx-amd64 32 2 16 1 4.20 62.5G 28.3G 16384 2048

Example 2: Show resource attributes for a host

qhost -h node01 -F mem_total,num_proc,load_avg

Sample output:

HOSTNAME                ARCH         NCPU NSOC NCOR NTHR  LOAD  MEMTOT  MEMUSE  SWAPTO  SWAPUS
----------------------------------------------------------------------------------------------
global - - - - - - - - - -
node01 lx-amd64 16 2 8 1 2.35 31.3G 12.5G 8192 1024
hl:mem_total=31.300000G
hl:num_proc=16.000000
hl:load_avg=2.350000

Example 3: Show jobs running on hosts

qhost -j

Sample output:

HOSTNAME                ARCH         NCPU NSOC NCOR NTHR  LOAD  MEMTOT  MEMUSE  SWAPTO  SWAPUS
----------------------------------------------------------------------------------------------
global - - - - - - - - - -
node01 lx-amd64 16 2 8 1 2.35 31.3G 12.5G 8192 1024
12345 0.50 test_job alice r 01/15/2024 10:30:00 compute@node01 MASTER
12346 0.45 analysis bob r 01/15/2024 11:00:00 compute@node01 MASTER

Example 4: Filter hosts by resources

qhost -l arch=lx-amd64,num_proc=16

Effect: Show hosts with architecture lx-amd64 and 16 CPUs.

Example 5: Show queue instances

qhost -q

Sample output:

HOSTNAME                ARCH         NCPU NSOC NCOR NTHR  LOAD  MEMTOT  MEMUSE  SWAPTO  SWAPUS
----------------------------------------------------------------------------------------------
global - - - - - - - - - -
node01 lx-amd64 16 2 8 1 2.35 31.3G 12.5G 8192 1024
compute BIP 4/0/16

Example 6: Suppress core binding columns

qhost -ncb

Sample output:

HOSTNAME                ARCH         NCPU  LOAD  MEMTOT  MEMUSE  SWAPTO  SWAPUS
----------------------------------------------------------------------------------
global - - - - - - -
node01 lx-amd64 16 2.35 31.3G 12.5G 8192 1024

Example 7: Filter hosts by user jobs

qhost -u alice -j

Effect: Show only hosts running jobs for user alice, with job details.

Example 8: Filter hosts by wildcard

qhost -h "node*"

Effect: Show all hosts that start with node.

Example 9: XML output

qhost -xml

Effect: Output host info in XML for programmatic parsing.