Starting systemd scope fails sometimes
I frequently see error messages in the journal about various autostart apps started by gnome-session, which systemd fails to put into a systemd scope. For example:
-
user-dirs-update-gtk
:Feb 24 13:14:16 amnesia systemd[5198]: app-gnome-user\x2ddirs\x2dupdate\x2dgtk-8709.scope: Couldn't move process 8709 to requested cgroup '/user.slice/user-10 00.slice/user@1000.service/app.slice/app-gnome-user\x2ddirs\x2dupdate\x2dgtk-8709.scope': No such process Feb 24 13:14:16 amnesia systemd[5198]: app-gnome-user\x2ddirs\x2dupdate\x2dgtk-8709.scope: Failed to add PIDs to scope's control group: No such process Feb 24 13:14:16 amnesia systemd[5198]: app-gnome-user\x2ddirs\x2dupdate\x2dgtk-8709.scope: Failed with result 'resources'. Feb 24 13:14:16 amnesia systemd[5198]: Failed to start app-gnome-user\x2ddirs\x2dupdate\x2dgtk-8709.scope - Application launched by gnome-session-binary.
-
gnome-keyring-pkcs11
:Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dpkcs11-7696.scope: Couldn't move process 7696 to requested cgroup '/user.slice/user-1000. slice/user@1000.service/app.slice/app-gnome-gnome\x2dkeyring\x2dpkcs11-7696.scope': No such process Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dpkcs11-7696.scope: Failed to add PIDs to scope's control group: No such process Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dpkcs11-7696.scope: Failed with result 'resources'. Feb 24 12:52:16 amnesia systemd[5198]: Failed to start app-gnome-gnome\x2dkeyring\x2dpkcs11-7696.scope - Application launched by gnome-session-binary.
-
gnome-keyring-secrets
:Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dsecrets-7694.scope: Couldn't move process 7694 to requested cgroup '/user.slice/user-1000 .slice/user@1000.service/app.slice/app-gnome-gnome\x2dkeyring\x2dsecrets-7694.scope': No such process Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dsecrets-7694.scope: Failed to add PIDs to scope's control group: No such process Feb 24 12:52:16 amnesia systemd[5198]: app-gnome-gnome\x2dkeyring\x2dsecrets-7694.scope: Failed with result 'resources'. Feb 24 12:52:16 amnesia systemd[5198]: Failed to start app-gnome-gnome\x2dkeyring\x2dsecrets-7694.scope - Application launched by gnome-session-binary. Feb 24 12:52:16 amnesia systemd[5198]: Started app-gnome-gnome\x2dkeyring\x2dssh-7695.scope - Application launched by gnome-session-binary.
-
ibus-mozc-gnome-initial-setup
:Feb 24 12:52:23 amnesia systemd[5198]: app-gnome-ibus\x2dmozc\x2dgnome\x2dinitial\x2dsetup-8306.scope: Couldn't move process 8306 to requested cgroup '/user.s lice/user-1000.slice/user@1000.service/app.slice/app-gnome-ibus\x2dmozc\x2dgnome\x2dinitial\x2dsetup-8306.scope': No such process Feb 24 12:52:23 amnesia systemd[5198]: app-gnome-ibus\x2dmozc\x2dgnome\x2dinitial\x2dsetup-8306.scope: Failed to add PIDs to scope's control group: No such pr ocess Feb 24 12:52:23 amnesia systemd[5198]: app-gnome-ibus\x2dmozc\x2dgnome\x2dinitial\x2dsetup-8306.scope: Failed with result 'resources'. Feb 24 12:52:23 amnesia systemd[5198]: Failed to start app-gnome-ibus\x2dmozc\x2dgnome\x2dinitial\x2dsetup-8306.scope - Application launched by gnome-session-binary.
Since the apps themselves don't print any error messages, I suspect that they actually run just fine and the reason for the error message is a race, i.e. that the process already exited when gnome-session tries to put it in systemd scope.
Is there any way to avoid those error messages to be printed?