Re: [systemd-devel] systemctl --user on RHEL -- is this a bad idea

2017-11-08 Thread Michael Chapman

On Thu, 9 Nov 2017, Jeff Solomon wrote:

Hi Michael,

Good to know. Do you count on lingering or on starting the user service on 
first login?


Well, both work, but the main reason I've made this change is so that I 
can enable lingering on users and run persistent user-specific services.

___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] systemctl --user on RHEL -- is this a bad idea

2017-11-08 Thread Jeff Solomon
Hi Michael,

Good to know. Do you count on lingering or on starting the user service on 
first login?

> On Nov 7, 2017, at 11:01 PM, Michael Chapman  wrote:
> 
>> On Wed, 8 Nov 2017, Jeff Solomon wrote:
>> Hi,
>> 
>> I would like to use a user service (systemctl --user) with systemd on RHEL7
>> where it has been deliberately removed.
>> 
>> I've communicated with the RH dev who made this change who reported that I
>> could restore the /lib/systemd/system/user@.service file and mostly
>> everything would work.
> 
> I've been dropping 0004-remove-user-.service.patch from RHEL's systemd 
> packages since RHEL 7.2, when Red Hat bumped systemd up from v208 to v219. I 
> haven't encountered any problems with this change.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] systemctl --user on RHEL -- is this a bad idea

2017-11-07 Thread Michael Chapman

On Wed, 8 Nov 2017, Jeff Solomon wrote:

Hi,

I would like to use a user service (systemctl --user) with systemd on RHEL7
where it has been deliberately removed.

I've communicated with the RH dev who made this change who reported that I
could restore the /lib/systemd/system/user@.service file and mostly
everything would work.


I've been dropping 0004-remove-user-.service.patch from RHEL's systemd 
packages since RHEL 7.2, when Red Hat bumped systemd up from v208 to v219. 
I haven't encountered any problems with this change.

___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


[systemd-devel] systemctl --user on RHEL -- is this a bad idea

2017-11-07 Thread Jeff Solomon
Hi,

I would like to use a user service (systemctl --user) with systemd on RHEL7
where it has been deliberately removed.

I've communicated with the RH dev who made this change who reported that I
could restore the /lib/systemd/system/user@.service file and mostly
everything would work.

I don't care about having the user service exist only when the user is
logged in, as I will enable lingering on the service and I want it to be
running from boot to shutdown.

I've found that I can run:

systemctl start user@foo

to start the foo user's service and that works, but on other systems
(Ubuntu) where user services are officially supported, the user service is
automatically started when I run:

  loginctl enable-linger foo

whereas on RHEL, running this command does not start the service.

I can imagine writing a tiny additional service on RHEL that will start the
user service using:

ExecStart=/usr/bin/systemctl start user@foo

but I'd rather make lingering officially work on RHEL to the extent that
that is possible.

Two questions:

1) Any idea how to make lingering work such that the user service is
started automatically on reboot

2) Is it a really dumb idea to try to make this work on RHEL7?

Thanks!

Jeff
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel