Repository navigation
Description
Summary
On Fedora (SELinux enforcing), opening Devsy Desktop makes setroubleshootd burn 50–90% CPU for as long as the app runs. The cause is not Devsy's container management itself but Devsy leaking ~25 open file descriptors (no close-on-exec) into every child process it spawns. Its periodic workspace-status agents run podman, and podman's pasta --version probe inherits those fds; pasta then walks/reads all of them at startup, generating a storm of SELinux denials that setroubleshootd analyzes one by one.
Environment
- Devsy Desktop AppImage v1.26.0 (
devsy --version), provider: podman (rootless), endpointunix:///run/user/1000/podman/podman.sock - Fedora 44 (Atomic, kernel 7.2.14-200.fc44.x86_64), SELinux enforcing/targeted
- podman 5.8.9, pasta 0^20261002.gcba3570-1.fc44, setroubleshoot-server 3.3.36-3.fc44
- 1 running dev-container (
--network=host— pasta serves no network role here; it is spawned purely by podman's version probe)
Impact (measured)
- ~16,000 SELinux AVC denials in 15 minutes while Devsy is open; ~25–47 per pasta spawn. 100% of them from
comm="pasta"/comm="pasta.avx2". setroubleshootdat 50–90% CPU; closing Devsy returns CPU to normal. This is the user-visible symptom.- Status agents hot-loop
podman info: ~22 process spawns/sec observed (1,543 podman spawns in a 70s window with the GUI idle in tray), in waves of 5 paralleldevsy internal agent workspace statusevery ~13s. That is significant CPU overhead by itself, independent of SELinux.
Root-cause chain (all verified live)
- Devsy's Electron main process holds open: AppImage FUSE-mount files (
/tmp/.mount_devsy.*/icudtl.dat,app.asar,*.pak,v8_context_snapshot.bin), Chromium caches under~/.config/devsy-desktop/(GPUCache, DawnGraphiteCache, spellcheck.bdic), and/dev/dri/renderD128. None areO_CLOEXEC. - Every child spawned by Devsy inherits that fd table. Fingerprint match: 25/27 of the paths denied to
pastaare exactly the fds open in the Electron main process. - Waves of
devsy workspace status <ws>(5 workspaces) spawn every ~13s → each spawns nesteddevsy internal agent workspace status→ hot loop ofpodman info. podman inforunspasta --version. pasta (passt) scans/reads its inherited fds at startup even in--versionmode and walks their paths (getattron every path component, probe reads) — including through the AppImage FUSE mounts.pasta_tmay not readfusefs_t,config_home_tordri_device_t→ tens of AVCs per spawn →setroubleshootdmelts down.
The leak also propagates transitively: anything launched from a process with leaked fds (another Electron AppImage, an editor connected via devsy workspace ssh) passes its own fds down to Devsy's children, widening the denial set.
Minimal repro
# Terminal 1 — watch denials while Devsy Desktop is open:
journalctl -t audit -f | grep 'comm="pasta"'
sudo top # setroubleshootd CPU climbs within a minute
# Isolated pasta repro (no Devsy needed):
exec 9</some/AppImage/mount/icudtl.dat # any FUSE-mounted file, no CLOEXEC
pasta --version # → AVC on that fd's pathSuggested fixes
- Sanitize inherited fds in the Go binary at startup (highest value, one call): as the first thing
devsydoes before spawning anything —or equivalent#include <linux/close_range.h> close_range(3, ~0ULL, CLOSE_RANGE_CLOEXEC); // Linux ≥ 5.11
fcntl(FD_CLOEXEC)loop. This kills the whole leak-propagation chain (podman, pasta, everything downstream) regardless of how Electron opens its files. A Go shim viasyscall.CloseRange/rawunix.CloseRangeworks too. - Throttle the status agents: exponential backoff + caching instead of re-running
podman info10–22×/sec per agent; or subscribe topodman system eventsinstead of polling. Waves of 5 parallel CLI invocations every 13s are also avoidable with a single batched call. - Possibly related trigger: our dev-container has been looping
waiting for devsy agent to be availablein its init for hours; the aggressive retry loop may be a symptom of that never-reaching-ready state.
Workaround applied locally
A small SELinux local module allowing pasta_t read/getattr probes on fusefs_t, config_home_t, dri_device_t silences the storm (verified: 1,543 podman spawns with the GUI open → 0 AVCs, setroubleshootd stays asleep). Happy to share it — but the fd leak and the hot loop are the actual defects, and every rootless-podman user on an SELinux distro hits some variant of this with any fd-leaking GUI app.
Activity
coderabbitai commentedon Nov 4, 2026
📝 Issue Planner
Check the box below or use the
@coderabbitai plancommand to generate an implementation plan and prompts that you can use with your favorite coding assistant.🧪 Issue enrichment is currently in open beta.
You can configure auto-planning by selecting labels in the issue_enrichment configuration.
To disable automatic issue enrichment, add the following to your
.coderabbit.yaml:💬 Have feedback or questions? Drop into our discord!
[-]Leaked file descriptors to child processes cause pasta(1) SELinux AVC storm and setroubleshootd CPU burn (Fedora, rootless podman)[/-][+][Bug] Leaked file descriptors to child processes cause pasta(1) SELinux AVC storm and setroubleshootd CPU burn (Fedora, rootless podman)[/+]