3 ms·
Does socket activation also stop the service after a while? In my experience dbus autostart services are always a huge mess, making it unpredictable what will b
by mid-kid 3y ago
Does socket activation also stop the service after a while? In my experience dbus autostart services are always a huge mess, making it unpredictable what will be running after a while of using the computer, and they never stop themselves either.
I generally prefer either stopping/starting a service on demand or just keeping it always on, to ensure predictability and prevent buildup of never-stopped services.
- theamk 3y agoWhen you set Accept=yes (new process per connection), then service naturally stops once connection closes. But that approach has relatively high per-connection overhead, so it cannot be used in a lot of cases. Still pretty useful for stuff like x11vnc. For Accept=no, there is no auto-stop. I think it's because once service is activated, systemd no longer has reliable information about socket and thus cannot tell if the service is idle or not. But what socket/dbus activation does is it enables services to exit on idle. And some services actually do it - systemd-timedated being one example. Any time I enter "timedatectl" I see it start and then exit.