hashicorp / hashicorp/nomad

[request] sighup refreshing node capabilities/capacity

Open
#4,438 4 comments 2 reactions 0 assignees View on GitHub
theme/client theme/client-restart theme/config type/enhancement
Dominant language
Go
Stars
17k
Forks
2.1k
Avg merge
1d 9h
Merged PRs (30d)
105

Description

### Nomad version
```
Nomad v0.8.3 (c85483da3471f4bd3a7c3de112e95f551071769f)
```

### Operating system and Environment details

CentOS 7.5.1804

### Issue

I recently added memory and cpu to a virtual machine running the nomad client. I had to restart the agent before nomad would see the new capacity (memory, cpu, disk). That's fine, but it'd be cool if the nomad daemon would refresh node capacity on a SIGHUP (or on the fly, that's cool too).

This may extend to other bits like the drivers and such. But when doing operations work reloading is easier to sell than restarting the agent.

### Reproduction steps

```
# note output of:
$ nomad node status -self
...
Host Resource Utilization
CPU Memory Disk
1347/13194 MHz 1.6 GiB/16 GiB 1.0 GiB/4.0 GiB
...
# update the machine's disk or memory.
# send a sighup, (systemd reload, kill -s sighup, etc)
$ nomad node status -self
...
Host Resource Utilization
CPU Memory Disk
1347/13194 MHz 1.6 GiB/16 GiB 1.0 GiB/4.0 GiB
...
```

Notice the host capacity has not been updated.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the Nomad client agent's handling of SIGHUP and the code that reports host capacity to `nomad node status -self`. Reproduce the documented VM resource change and reload command, then verify that CPU, memory, and disk capacity refresh without restarting the agent.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
devops, infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.