tailscale/tsweb
Brad Fitzpatrick 0e79b322a9 tsweb/varz: add node_boot_time_seconds expvar
Export the machine's boot time (the btime line from Linux's
/proc/stat) as node_boot_time_seconds, named to match what
Prometheus's node exporter uses for the same value. Combined with
process_start_unix_time, this can be used to distinguish process
restarts from whole node restarts.

The value is parsed once per process lifetime, not per scrape, and
the metric is only published when a value is available, so non-Linux
systems don't export a bogus zero.

Updates tailscale/corp#44743

Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
Change-Id: I5f53186b97bb1482bd1a5387c0910b0ae26544ff
2026-07-10 08:47:59 -07:00
..
promvarz all: remove AUTHORS file and references to it 2026-01-23 15:49:45 -08:00
varz tsweb/varz: add node_boot_time_seconds expvar 2026-07-10 08:47:59 -07:00
debug_test.go tsweb: add TS_DEBUG_TRUSTED_CIDRS envknob to debug (#19283) 2026-04-08 18:47:52 -04:00
debug.go all: remove AUTHORS file and references to it 2026-01-23 15:49:45 -08:00
log.go all: remove AUTHORS file and references to it 2026-01-23 15:49:45 -08:00
pprof_default.go all: remove AUTHORS file and references to it 2026-01-23 15:49:45 -08:00
pprof_js.go all: remove AUTHORS file and references to it 2026-01-23 15:49:45 -08:00
request_id.go cmd/tailscale/cli: fix time in tailscale routecheck (#19956) 2026-06-01 16:12:08 -07:00
tsweb_test.go cmd/vet: add subtestnames analyzer; fix all existing violations 2026-04-05 15:52:51 -07:00
tsweb.go ipn/localapi,client/local: honour Retry-After on cert rate-limit (#20315) 2026-07-08 13:34:40 +01:00