Agent: system SQLite (glibc fix) + fail-soft store + PATH on linux/macOS #13

Merged
gsadmin merged 2 commits from dev into main 2026-08-10 17:56:08 +00:00
Owner

Two agent fixes for Linux/macOS deployment.

System SQLite + fail-soft (glibc fix)
The portable agent bundled SQLitePCLRaw's e_sqlite3 native (built for glibc
2.33+), so it crash-looped at startup on Ubuntu 20.04 / Debian 11 (glibc 2.31)
with DllNotFoundException: GLIBC_2.33 not found. Linux/macOS now bind the host's
own libsqlite3 (Microsoft.Data.Sqlite.Core + SQLitePCLRaw.bundle_sqlite3); no
bundled native ships. JobHistoryStore fails soft: if SQLite cannot initialize it
falls back to in-memory idempotency instead of taking the service down. Windows
keeps the bundled e_sqlite3.

executer-agent on PATH (linux/macOS)
install/initialize symlink the binary into /usr/local/bin so executer-agent
and which executer-agent work from any shell (mirrors the Windows MSI PATH
entry); remove deletes it. Best-effort and safe: never clobbers a non-symlink,
never fails the install.

Agent builds on both TFMs; all 60 agent tests pass; the Linux publish carries no
sqlite native and uses provider.sqlite3.

Two agent fixes for Linux/macOS deployment. **System SQLite + fail-soft (glibc fix)** The portable agent bundled SQLitePCLRaw's e_sqlite3 native (built for glibc 2.33+), so it crash-looped at startup on Ubuntu 20.04 / Debian 11 (glibc 2.31) with DllNotFoundException: GLIBC_2.33 not found. Linux/macOS now bind the host's own libsqlite3 (Microsoft.Data.Sqlite.Core + SQLitePCLRaw.bundle_sqlite3); no bundled native ships. JobHistoryStore fails soft: if SQLite cannot initialize it falls back to in-memory idempotency instead of taking the service down. Windows keeps the bundled e_sqlite3. **executer-agent on PATH (linux/macOS)** install/initialize symlink the binary into /usr/local/bin so `executer-agent` and `which executer-agent` work from any shell (mirrors the Windows MSI PATH entry); remove deletes it. Best-effort and safe: never clobbers a non-symlink, never fails the install. Agent builds on both TFMs; all 60 agent tests pass; the Linux publish carries no sqlite native and uses provider.sqlite3.
gsadmin added 2 commits 2026-08-10 17:56:05 +00:00
The portable agent bundled SQLitePCLRaw's e_sqlite3 native, which is built
against glibc 2.33+ and so refused to load on Ubuntu 20.04 / Debian 11
(glibc 2.31) — the agent crash-looped at startup on
Microsoft.Data.Sqlite.SqliteConnection's type initializer
(DllNotFoundException: GLIBC_2.33 not found).

- linux/macOS (net10.0): reference Microsoft.Data.Sqlite.Core +
  SQLitePCLRaw.bundle_sqlite3, binding the host's own libsqlite3 instead of a
  bundled native. No glibc floor; the published agent no longer ships
  libe_sqlite3.so. Windows/server keep the bundled e_sqlite3 (no glibc floor
  there).
- JobHistoryStore now fails soft: if SQLite cannot initialize (missing/
  incompatible native, unwritable path) it logs a warning and falls back to
  in-memory idempotency instead of taking the service down. Idempotency then
  holds within the process lifetime but not across restarts.

Agent builds on both TFMs; the linux publish carries no sqlite native and uses
provider.sqlite3; all 60 agent tests pass (DownloadCacheTests now exercise the
system-sqlite path).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Windows adds the install dir to PATH via the MSI, but the unix installer only
dropped the binary at /opt/executer/agent, so `executer-agent` / `which
executer-agent` did not work without the full path. `install`/`initialize` now
symlink the binary into /usr/local/bin (on the default PATH on both linux and
macOS, and writable unlike /usr/bin under macOS SIP); `remove` deletes it.
Best-effort: it never replaces a non-symlink already there and never fails the
install, and uninstall only removes a symlink pointing at our own install.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
gsadmin merged commit f442060b2d into main 2026-08-10 17:56:08 +00:00
Sign in to join this conversation.