feat: add iowait, TCP connection states, and file descriptor metrics

- cpu.iowait_percent: % of time CPU is waiting on disk I/O
- tcp: established/time_wait/close_wait/listen counts; max_time_wait
  system limit included on Linux for context
- file_descriptors: used vs max (Linux reads /proc/sys/fs/file-nr,
  macOS reads kern.openfiles / kern.maxfiles via sysctl)

These three metrics directly surface the most common causes of
unexplained PHP/Laravel timeouts at the system level.
This commit is contained in:
Joel Male
2026-02-25 15:35:43 +10:00
parent 1a0c3e072c
commit bd63686312
2 changed files with 112 additions and 1 deletions
+12
View File
@@ -21,6 +21,7 @@
},
"cpu": {
"percent": 34.5,
"iowait_percent": 4.2,
"per_core": [
42.1,
28.3,
@@ -74,6 +75,17 @@
"packets_sent_per_sec": 95.3,
"packets_recv_per_sec": 140.7
},
"tcp": {
"established": 42,
"time_wait": 18,
"close_wait": 3,
"listen": 8,
"max_time_wait": 32768
},
"file_descriptors": {
"used": 1248,
"max": 98304
},
"processes": [
{
"pid": 1234,