Re: [systemd-devel] Antw: Re: Antw: Re: Antw: Re: Re: "bad" status for genersated target; why?

2019-05-16 Thread Reindl Harald


Am 16.05.19 um 12:41 schrieb Ulrich Windl:
>> Please, this is just wasting everyone's time. Take the advice that
>> Reindl gave you: generators are an advanced tool that you don't need
>> when staring with systemd.
> 
> Yes systemd is for you developers, not for developers like me. Your're the
> geniuses, and I'm the fool... I'll stop this thread here, because it's also
> wasting MY time.

when you start using systemd and take the most complexest things as your
start before you even understand everything else around it and then
expect that you just have to write enough emails saving you all the
years from expierience others something goes wrong

generators AFAIK where implemented years after we used systemd in
production or at least the transition of /etc/fstab to a generated unit
was done at that time in point

So what is the preferred method when some package install adds new  unit
files? systemctl daemon-reload?
on sane distributions solved years ago like
https://bugzilla.redhat.com/show_bug.cgi?id=850355 and in the meatime a
ton of rpm scriptlets are replaced with file-triggers at least on Fedora


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

[systemd-devel] Antw: Re: Antw: Re: Antw: Re: Re: "bad" status for genersated target; why?

2019-05-16 Thread Ulrich Windl
>>> Zbigniew Jedrzejewski-Szmek  schrieb am 16.05.2019 um
12:13
in Nachricht <20190516101348.gn9...@in.waw.pl>:
> On Thu, May 16, 2019 at 12:04:28PM +0200, Ulrich Windl wrote:
>> >>> Lennart Poettering  schrieb am 16.05.2019 um
10:29
>> in
>> Nachricht <20190516082910.GA24042@gardel-login>:
>> > On Do, 16.05.19 08:55, Ulrich Windl (ulrich.wi...@rz.uni‑regensburg.de)
>> wrote:
>> > 
>> >> Hi!
>> >>
>> >> After having read the page again, it's not more clear than
>> >> before. Even I have some more questions:
>> >>
>> >> Why do generators receive three directory paths: Should the
>> >> generator decide where at those three paths to add a unit?
>> > 
>> > Yes.
>> > 
>> > This is explained in the documentation btw:
>> > https://www.freedesktop.org/software/systemd/man/systemd.generator.html 
>> > 
>> > Long story short: it's about unit file precedence.
>> 
>> Sorry I don't get it: So the idea is to have different generators,
depending
>> on the precedence?
> 
> Please, this is just wasting everyone's time. Take the advice that
> Reindl gave you: generators are an advanced tool that you don't need
> when staring with systemd.

Yes systemd is for you developers, not for developers like me. Your're the
geniuses, and I'm the fool... I'll stop this thread here, because it's also
wasting MY time.

> 
> Zbyszek



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

[systemd-devel] Antw: Re: Antw: Re: Antw: Re: Re: "bad" status for genersated target; why?

2019-05-15 Thread Ulrich Windl
>>> Trent Piepho  schrieb am 15.05.2019 um 18:54 in 
>>> Nachricht
<1557939250.4229.111.ca...@impinj.com>:
> On Wed, 2019-05-15 at 10:03 +, systemd-devel-
> requ...@lists.freedesktop.org wrote:
>> 
>> 
>> If you are looking for a generic converter of foreign stuff into
>> classic, persistent systemd unit files, then generators is not what
>> you should be using. Generators are life-cycle bound to systemd
>> release cycles, and their output ceases to exist on every reload
>> boundary, and when the system is offline. If we'd allow generated
>> units to be installed that clear life-cycle would be very much
>> blurred, as suddenly you'd have configuration that hooks them into the
>> system that is more persistant than the actual definitions of the
>> units themselves, and that's just borked...
>> 
>> I mean, if you want to persistently enable a unit that is converted
>> from something else, then please write your own converted, and write
>> something to /etc/systemd/system, there's no need whatsoever to bother
>> systemd itself with that, you shouldn't use generators for that.
>> 
> 
> As an embedded Linux developer, I think there is an interesting idea
> here.
> 
> There are no admins on an embedded system and everything must be done
> through some automatic piece of software.  As soon I see, "edit a file
> in /etc," I know there's a problem I'll need to find a solution for
> because the normal way isn't going to work.

There's an important point you faul to understand:
The file in /etc is there not because of the _frequency_ of change, but for 
_ease_ of configuration.
It's much easier to write one line of text than to create or adjust systemd 
unit files, not to talk about the link mess.

> 
> Embedded likes read-only root filesystems.  We also like it if software
> image we create is immutable.  So copying /etc out of a read-only
> filesystem into a writable one isn't really a solution to the problems
> posed by a read-only rootfs, as it largely defeats the purpose of
> making the rootfs read-only in the first place.
> 
> I want the device configuration to be transactional.  I want it to be
> safe from power cycles as it's updated.  There should be roll-backs to
> previous configs, exporting configuration, importing it, pushing
> changes to a fleet of devices, automatic migration forward and backward
> across software versions.
> 
> This is hard to do with a pile of text files in /etc all in different
> formats and parsed by different software.

It's all a matter of taste. Different things belong to different files. And any 
attempt to enforce one super process that does everything is simply wrong (and 
against the spirit of UNIX).

> 
> I think of all the ways one might configure services locally.  Edit
> environment files read by units, edit the service files, etc.

Well, you can, but you need not.

> 
> What if I dynamically generated service files?  There's a lot that
> could be done that way.
> 
> I can sort of dynamically enable units by starting them over dbus.  But
>  that really only works after most of the boot is done.  What if I want
> to dynamically alter the CapabilityBoundingSet based on what features
> of a service are enabled?
> ___
> systemd-devel mailing list
> systemd-devel@lists.freedesktop.org 
> https://lists.freedesktop.org/mailman/listinfo/systemd-devel 




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