app-misc/screen hard coded /var/run/screen in ebuild file, which is not compatible with sys-apps/systemd. systemd will re-create the whole /var/run directory every reboot, so /var/run/screen need to be manually created and chmod to 777. Reproducible: Always Steps to Reproduce: 1.emerge systemd and replace sysvint 2.reboot 3.run screen
Michał, As the systemd guy, will you please post the optimal solution for this bug here? Then it will be reviewed for inclusion. Thanks.
AFAICS Fedora still uses the standard socket dir. How about using /var/lib? That seems quite correct.
Created attachment 276339 [details] tmpfiles.d configuration for screen The solution with systemd is to use a configuration file /etc/tmpfiles.d/screen.conf. systemd will take care of creating and cleaning the directories defined in there, see "man tmpfiles.d" if you have systemd installed (screen is in fact the example at the end of that manpage).
I guess I shall add systemd_dotmpfilesd() function to the eclass. Henry, maybe are you aware if screen upstream is interested in integrating that file? I'm not sure if even systemd upstream knows how to handle installing them in packages...
(In reply to comment #4) > I guess I shall add systemd_dotmpfilesd() function to the eclass. Yeah, that's a good idea. It should install to /usr/lib/tmpfiles.d/, so they can be overridden in /etc/tmpfiles.d/ by the administrator. > > Henry, maybe are you aware if screen upstream is interested in integrating that > file? I'm not sure if even systemd upstream knows how to handle installing them > in packages... I have no idea about screen upstream. Installing tmpfiles is not a problem. systemd installs two of them itself, so we can just copy... :-) Making a patch won't be entirely trivial, however, because the path can be changed at ./configure time (as is done in the screen ebuild).
(In reply to comment #5) > (In reply to comment #4) > > I guess I shall add systemd_dotmpfilesd() function to the eclass. > > Yeah, that's a good idea. It should install to /usr/lib/tmpfiles.d/, so they > can be overridden in /etc/tmpfiles.d/ by the administrator. ...and done. > > > > Henry, maybe are you aware if screen upstream is interested in integrating that > > file? I'm not sure if even systemd upstream knows how to handle installing them > > in packages... > > I have no idea about screen upstream. Installing tmpfiles is not a problem. > systemd installs two of them itself, so we can just copy... :-) Making a patch > won't be entirely trivial, however, because the path can be changed at > ./configure time (as is done in the screen ebuild). It's basically using sed like devs need to do for unit files.
(In reply to comment #1) > Michał, As the systemd guy, will you please post the optimal solution for this > bug here? Then it will be reviewed for inclusion. Thanks. Well, anyway, as we see it, an optimal solution is to use the tmpfiles.d file as described by Henry. If you'd like to install it along with screen, we'd be happy to provide a patch for you. I'd suggest also considering using /run instead of /var/run; seems like the former directory is slowly replacing the latter one lately.
*** This bug has been marked as a duplicate of bug 333821 ***