github.com/smintz/nomad@v0.8.3/website/source/docs/commands/node/status.html.md.erb (about) 1 --- 2 layout: "docs" 3 page_title: "Commands: node status" 4 sidebar_current: "docs-commands-node-status" 5 description: > 6 The node status command is used to display information about nodes. 7 --- 8 9 # Command: node status 10 11 The `node status` command is used to display information about client nodes. A 12 node must first be registered with the servers before it will be visible in this 13 output. 14 15 ## Usage 16 17 ``` 18 nomad node status [options] [node] 19 ``` 20 21 If no node ID is passed, then the command will enter "list mode" and dump a 22 high-level list of all known nodes. This list output contains less information 23 but is a good way to get a bird's-eye view of things. 24 25 If there is an exact match based on the provided node ID or prefix, then that 26 particular node will be queried, and detailed information will be displayed, 27 including resource usage statistics. Otherwise, a list of matching nodes and 28 information will be displayed. If running the command on a Nomad Client, the 29 -self flag is useful to quickly access the status of the local node. 30 31 ## General Options 32 33 <%= partial "docs/commands/_general_options" %> 34 35 ## Status Options 36 37 * `-self`: Query the status of the local node. 38 39 * `-stats`: Display detailed resource usage statistics. 40 41 * `-allocs`: When a specific node is not being queried, shows the number of 42 running allocations per node. 43 44 * `-short`: Display short output. Used only when querying a single node. 45 46 * `-verbose`: Show full information. 47 48 * `-json` : Output the node in its JSON format. 49 50 * `-t` : Format and display node using a Go template. 51 52 53 ## Examples 54 55 List view: 56 57 ``` 58 $ nomad node status 59 ID DC Name Class Drain Eligibility Status 60 a72dfba2 dc1 node1 <none> false eligible ready 61 1f3f03ea dc1 node2 <none> false eligible ready 62 ``` 63 64 List view, with running allocations: 65 66 ``` 67 $ nomad node status -allocs 68 ID DC Name Class Drain Eligibility Status Running Allocs 69 4d2ba53b dc1 node1 <none> false eligible ready 1 70 34dfba32 dc1 node2 <none> false eligible ready 3 71 ``` 72 73 Single-node view in short mode: 74 75 ``` 76 $ nomad node status -short 1f3f03ea 77 ID = c754da1f 78 Name = nomad 79 Class = <none> 80 DC = dc1 81 Drain = false 82 Status = ready 83 Uptime = 17h2m25s 84 85 Allocations 86 ID Eval ID Job ID Task Group Desired Status Client Status 87 0b8b9e37 8bf94335 example cache run running 88 ``` 89 90 Full output for a single node: 91 92 ``` 93 $ nomad node status 1f3f03ea 94 ID = c754da1f 95 Name = nomad-server01 96 Class = <none> 97 DC = dc1 98 Drain = false 99 Status = ready 100 Uptime = 17h42m50s 101 102 Drivers 103 Driver Detected Healthy 104 docker false false 105 exec true true 106 java true true 107 qemu true true 108 raw_exec true true 109 rkt true true 110 111 Node Events 112 Time Subsystem Message 113 2018-03-29T17:24:42Z Driver: docker Driver docker is not detected 114 2018-03-29T17:23:42Z Cluster Node Registered 115 116 Allocated Resources 117 CPU Memory Disk IOPS 118 500/2600 MHz 256 MiB/2.0 GiB 300 MiB/32 GiB 0/0 119 120 Allocation Resource Utilization 121 CPU Memory 122 430/2600 MHz 199 MiB/2.0 GiB 123 124 Host Resource Utilization 125 CPU Memory Disk 126 513/3000 MHz 551 MiB/2.4 GiB 4.2 GiB/52 GiB 127 128 Allocations 129 ID Eval ID Job ID Task Group Desired Status Client Status 130 7bff7214 b3a6b9d2 example cache run running 131 ``` 132 133 Using `-self` when on a Nomad Client: 134 135 ``` 136 $ nomad node status -self 137 ID = c754da1f 138 Name = nomad-client01 139 Class = <none> 140 DC = dc1 141 Drain = false 142 Status = ready 143 Uptime = 17h7m41s 144 145 Drivers 146 Driver Detected Healthy 147 docker false false 148 exec true true 149 java true true 150 qemu true true 151 raw_exec true true 152 rkt true true 153 154 Node Events 155 Time Subsystem Message 156 2018-03-29T17:24:42Z Driver: docker Driver docker is not detected 157 2018-03-29T17:23:42Z Cluster Node Registered 158 159 Allocated Resources 160 CPU Memory Disk IOPS 161 2500/2600 MHz 1.3 GiB/2.0 GiB 1.5 GiB/32 GiB 0/0 162 163 Allocation Resource Utilization 164 CPU Memory 165 2200/2600 MHz 1.7 GiB/2.0 GiB 166 167 Host Resource Utilization 168 CPU Memory Disk 169 2430/3000 MHz 1.8 GiB/2.4 GiB 6.5 GiB/40 GiB 170 171 Allocations 172 ID Eval ID Job ID Task Group Desired Status Client Status 173 0b8b9e37 8bf94335 example cache run running 174 b206088c 8bf94335 example cache run running 175 b82f58b6 8bf94335 example cache run running 176 ed3665f5 8bf94335 example cache run running 177 24cfd201 8bf94335 example cache run running 178 ``` 179 180 You will note that in the above examples, the **Allocations** output contains 181 columns labeled **Desired Status** and **Client status**. 182 183 Desired Status represents the goal of the scheduler on the allocation with 184 the following valid statuses: 185 186 - *run*: The allocation should run 187 - *stop*: The allocation should stop 188 189 Client Status represents the emergent state of the allocation and include 190 the following: 191 192 - *pending*: The allocation is pending and will be running 193 - *running*: The allocation is currently running 194 - *complete*: The allocation was running and completed successfully 195 - *failed*: The allocation was running and completed with a non-zero exit code 196 - *lost*: The node that was running the allocation has failed or has been partitioned 197 198 Using `-stats` to see detailed to resource usage information on the node: 199 200 ``` 201 $ nomad node status -stats c754da1f 202 ID = c754da1f 203 Name = nomad-client01 204 Class = <none> 205 DC = dc1 206 Drain = false 207 Status = ready 208 Uptime = 17h7m41s 209 210 Drivers 211 Driver Detected Healthy 212 docker false false 213 exec true true 214 java true true 215 qemu true true 216 raw_exec true true 217 rkt true true 218 219 Node Events 220 Time Subsystem Message 221 2018-03-29T17:24:42Z Driver: docker Driver docker is not detected 222 2018-03-29T17:23:42Z Cluster Node Registered 223 224 Allocated Resources 225 CPU Memory Disk IOPS 226 2500/2600 MHz 1.3 GiB/2.0 GiB 1.5 GiB/32 GiB 0/0 227 228 Allocation Resource Utilization 229 CPU Memory 230 2200/2600 MHz 1.7 GiB/2.0 GiB 231 232 Host Resource Utilization 233 CPU Memory Disk 234 2430/3000 MHz 1.8 GiB/2.4 GiB 3.9 GiB/40 GiB 235 236 CPU Stats 237 CPU = cpu0 238 User = 96.94% 239 System = 1.02% 240 Idle = 2.04% 241 242 CPU = cpu1 243 User = 97.92% 244 System = 2.08% 245 Idle = 0.00% 246 247 Memory Stats 248 Total = 2.4 GiB 249 Available = 612 MiB 250 Used = 1.8 GiB 251 Free = 312 MiB 252 253 Disk Stats 254 Device = /dev/mapper/ubuntu--14--vg-root 255 MountPoint = / 256 Size = 38 GiB 257 Used = 3.9 GiB 258 Available = 32 GiB 259 Used Percent = 10.31% 260 Inodes Percent = 3.85% 261 262 Device = /dev/sda1 263 MountPoint = /boot 264 Size = 235 MiB 265 Used = 45 MiB 266 Available = 178 MiB 267 Used Percent = 19.17% 268 Inodes Percent = 0.48% 269 270 Allocations 271 ID Eval ID Job ID Task Group Desired Status Client Status 272 0b8b9e37 8bf94335 example cache run running 273 b206088c 8bf94335 example cache run running 274 b82f58b6 8bf94335 example cache run running 275 ed3665f5 8bf94335 example cache run running 276 24cfd201 8bf94335 example cache run running 277 ``` 278 279 To view verbose information about the node: 280 281 ``` 282 $ nomad node status -verbose c754da1f 283 ID = c754da1f-6337-b86d-47dc-2ef4c71aca14 284 Name = nomad 285 Class = <none> 286 DC = dc1 287 Drain = false 288 Status = ready 289 Uptime = 17h7m41s 290 291 Drivers 292 Driver Detected Healthy Message Time 293 docker false false Driver docker is not detected 2018-03-29T17:24:42Z 294 exec true true <none> 2018-03-29T17:23:42Z 295 java true true <none> 2018-03-29T17:23:41Z 296 qemu true true <none> 2018-03-29T17:23:41Z 297 raw_exec true true <none> 2018-03-29T17:23:42Z 298 rkt true true <none> 2018-03-29T17:23:42Z 299 300 Node Events 301 Time Subsystem Message Details 302 2018-03-29T17:24:42Z Driver: docker Driver docker is not detected driver: docker, 303 2018-03-29T17:23:42Z Cluster Node Registered <none> 304 305 Allocated Resources 306 CPU Memory Disk IOPS 307 2500/2600 MHz 1.3 GiB/2.0 GiB 1.5 GiB/32 GiB 0/0 308 309 Allocation Resource Utilization 310 CPU Memory 311 2200/2600 MHz 1.7 GiB/2.0 GiB 312 313 Host Resource Utilization 314 CPU Memory Disk 315 230/3000 MHz 121 MiB/2.4 GiB 6.5 GiB/40 GiB 316 317 Allocations 318 ID Eval ID Job ID Task Group Desired Status Client Status 319 3d743cff-8d57-18c3-2260-a41d3f6c5204 2fb686da-b2b0-f8c2-5d57-2be5600435bd example cache run complete 320 321 Attributes 322 arch = amd64 323 cpu.frequency = 1300.000000 324 cpu.modelname = Intel(R) Core(TM) M-5Y71 CPU @ 1.20GHz 325 cpu.numcores = 2 326 cpu.totalcompute = 2600.000000 327 driver.docker = 1 328 driver.docker.version = 1.10.3 329 driver.exec = 1 330 driver.java = 1 331 driver.java.runtime = OpenJDK Runtime Environment (IcedTea 2.6.4) (7u95-2.6.4-0ubuntu0.14.04.2) 332 driver.java.version = 1.7.0_95 333 driver.java.vm = OpenJDK 64-Bit Server VM (build 24.95-b01, mixed mode) 334 driver.qemu = 1 335 driver.qemu.version = 2.0.0 336 driver.raw_exec = 1 337 driver.rkt = 1 338 driver.rkt.appc.version = 0.7.4 339 driver.rkt.version = 1.2.0 340 hostname = nomad 341 kernel.name = linux 342 kernel.version = 3.19.0-25-generic 343 memory.totalbytes = 2094473216 344 nomad.revision = '270da7a60ccbf39eeeadc4064a59ca06bf9ac6fc+CHANGES' 345 nomad.version = 0.3.2dev 346 os.name = ubuntu 347 os.version = 14.04 348 unique.cgroup.mountpoint = /sys/fs/cgroup 349 unique.network.ip-address = 127.0.0.1 350 unique.storage.bytesfree = 36044333056 351 unique.storage.bytestotal = 41092214784 352 unique.storage.volume = /dev/mapper/ubuntu--14--vg-root 353 ```