myxce/src
Rongsong Shen 9369b87152
fix(worker): stop treating systemd's UINT64_MAX sentinel as real rusage data
collect_job_rusages() (xcecd_cgroups.c) reads CPUUsageNSec/MemoryCurrent/
MemorySwapCurrent/TasksCurrent via D-Bus and only checked whether the
round trip itself succeeded (r >= 0). systemd's own convention -- not
previously accounted for here -- is to report UINT64_MAX for a counter
that isn't actually being tracked yet, not an error and not zero.

For MemoryCurrent specifically, an unguarded sentinel read produced
(float)UINT64_MAX / (1024*1024) == 17592186044416.0 (2^44) as a single
job's "memory usage", which the scheduler's rusage reconciliation then
summed across every RUN job that hit the same condition -- a live replay
session showed exactly 19 * 2^44 = 334251534843904.0 ("used=304.00 TB")
for 19 affected jobs, matching to the bit.

Added sd_resource_counter_is_available() and gated all four property
reads on it. Applied uniformly (not just MemoryCurrent) since systemd
uses the identical convention for the other three counters. Left the
existing memory_rss MB wire unit alone (bug-1735's established
contract, also relied on by the controller's own display pipeline) --
changing it would need auditing that separate consumer, out of scope
here.

bug-1814.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RLSNJhNoULvVcUhXEFafQC
2026-09-15 11:21:55 +00:00
..
autoscaler remove extralib 2026-09-04 11:24:43 +08:00
configs fix(scheduler): live-verify bug-1790 with a real global mem limit 2026-09-08 08:49:17 +00:00
controller fix: repoint stale controller/xce_test path references to harness/xce_test 2026-09-14 11:49:01 +00:00
docs feat(eliminate-frontend-makefile): task 3.3 - update live documentation (11 files) 2026-09-03 14:22:54 +00:00
frontend fix(apiserver): fix job control union discriminant, add human-readable job ID support (gitea#45) 2026-09-07 08:31:54 +00:00
harness fix(harness): reset getopt_long via optind=0 to stop cross-command corruption 2026-09-14 23:16:11 +00:00
include fix(scheduler): downgrade routine EEXIST resync log, dedup hash_string 2026-09-15 02:46:52 +00:00
lib fix(lib): stop cbuf_put/get orphaning their mutex on cancellation, hanging vtaskmgr_fini 2026-09-15 04:13:53 +00:00
nixSupport remove extralib 2026-09-04 11:24:43 +08:00
scheduler refactor(scheduler): defer job-array expansion off the vtask thread pool 2026-09-15 09:01:47 +00:00
schema feat(worker-rejoin-resync): task 6.1 - trigger reconciliation on rejoin 2026-09-01 19:43:18 +00:00
tools feat(xce-build): default --jobs to a live-computed value when omitted 2026-09-15 09:19:55 +00:00
worker fix(worker): stop treating systemd's UINT64_MAX sentinel as real rusage data 2026-09-15 11:21:55 +00:00
xceadmin build: make Go and Python builds fully offline (hermetic Nix build) 2026-09-03 12:38:49 +08:00
flake.lock remove extralib 2026-09-04 11:24:43 +08:00
flake.nix remove extralib 2026-09-04 11:24:43 +08:00
meson.build feat(xce-harness-component): relocate xce_test into standalone harness component 2026-09-14 05:08:15 +00:00
meson.options feat(dirty-content-fingerprint): add dirty_fingerprint meson option and C define 2026-08-21 03:54:37 +00:00