Re: [systemd-devel] Factoring out initctl support

2016-04-26 Thread Felipe Sateler
On Tue, 26 Apr 2016 17:28:34 +0200, Daniel Mack wrote:

> Hi Michael,
> 
> On 04/15/2016 11:00 PM, Daniel Mack wrote:
>> On 04/15/2016 10:47 PM, Michael Biebl wrote:
> 
>> Including the built results of systemd-initctl into your .deb packet is
>> not a solution? Making that an extra package causes too much trouble, I
>> totally agree.
> 
> Did you further think about this idea, would that be a solution?

I'm not sure I understood your proposal correctly, but each .deb package 
is built from one source package. This implies that systemd-initctl 
source would have to be somehow imported into the debian systemd source, 
and then used to build the shipped binary (ie, not importing the binary 
artifacts alone).

-- 
Saludos,
Felipe Sateler

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


[systemd-devel] systemctl status etc attempts to load unit

2016-04-26 Thread Andrei Borzenkov
I was grown to believe that I need "systemctl daemon-reload" to make
systemd recognize new units, but apparently it is no more the case. Just
dropping unit definition in standard place and running "systemctl status
new-unit" is enough to trigger systemd into loading it.

It apparently is not affected by --no-reload flag and is true for any
systemctl command that takes unit name as argument.

Does my memory fail me and it has always been the case? I tentatively
tracked this to commit 718db96199eb307751264e4163555662c9a389fa.

Note that behavior is also inconsistent when taking patterns in account.
It means that

systemctl status foo

behaves differently from

systemctl status foo*

There is nothing in documentation or commit message regarding this
behavior. Is this change intentional?
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread george Karakou
Your answer was correct(and of course acceptable) in the way it helped 
me understand what the solution was. The stanza on Mantas mail: "systemd 
has no way to know that dispatcher is doing a background job by the time 
it finishes starting up" was a full explanation of the whole parallel 
question i had. So if i want to be exact, one answer 
completed/supplemented the other. Sorry for not making it clear


greetings, George

On 04/26/2016 06:01 PM, Michael Biebl wrote:

2016-04-26 16:49 GMT+02:00 george Karakou :

You were really close, the correct answer is provided by mantas. Anyway
driven from your thought i moved the script's execution to NetworkManager
and i am now at the point i wanted. Though i have added 2 and something
minutes to my startup process time.
Thanks.



Ordering after the dispatcher won't help.
The dispatcher is not part of the initial transaction (e.g. pulled in
by multi-user.target.wants).

I'm pretty sure my answer was correct, but thanks.




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


Re: [systemd-devel] Factoring out initctl support

2016-04-26 Thread Daniel Mack
Hi Michael,

On 04/15/2016 11:00 PM, Daniel Mack wrote:
> On 04/15/2016 10:47 PM, Michael Biebl wrote:

> Including the built results of systemd-initctl into your .deb packet is
> not a solution? Making that an extra package causes too much trouble, I
> totally agree.

Did you further think about this idea, would that be a solution?


Thanks,
Daniel

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


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Mantas Mikulėnas
On Tue, Apr 26, 2016 at 5:52 PM, Reindl Harald 
wrote:

>
>
> Am 26.04.2016 um 16:37 schrieb Mantas Mikulėnas:
>
>> On Tue, Apr 26, 2016 at 3:14 PM, george Karakou
>> > wrote:
>>
>> It's actually NetworkManager-dispatcher whose actual job is -if i am
>> not mistaken- to run some scripts after NetworkManager main process.
>> Though i have configured NetworkManager-wait-online too but
>> systemd's parallelizazion is unbeatable: services are started in
>> parallel and i see other services that i have ordered after
>> dispatcher finishing starting and dispatcher is still exec'ing my
>> scripts.
>>
>> Because systemd _does not know_ that the dispatcher daemon is doing
>> something in the background.
>>
>> You seem to be convinced that systemd is doing some trickery to
>> parallelize NM. Meanwhile it's the exact opposite
>>
>
> and what is the solution for such cases when it does and can not know but
> continues fire up parallel things which need proper ordering?
>
> or in other words how is "NetworkManager-wait-online" supposed to do the
> job it's name implies in case of a systemd environment?
>

Well, I actually expected for NetworkManager-wait-online to block until all
the "dispatcher" hooks finished...

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


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Michael Biebl
2016-04-26 16:49 GMT+02:00 george Karakou :
> You were really close, the correct answer is provided by mantas. Anyway
> driven from your thought i moved the script's execution to NetworkManager
> and i am now at the point i wanted. Though i have added 2 and something
> minutes to my startup process time.
> Thanks.
>
>
> 
> Ordering after the dispatcher won't help.
> The dispatcher is not part of the initial transaction (e.g. pulled in
> by multi-user.target.wants).

I'm pretty sure my answer was correct, but thanks.


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread george Karakou

You were really close, the correct answer is provided by mantas. Anyway driven 
from your thought i moved the script's execution to NetworkManager and i am now 
at the point i wanted. Though i have added 2 and something minutes to my 
startup process time.
Thanks.



Ordering after the dispatcher won't help.
The dispatcher is not part of the initial transaction (e.g. pulled in
by multi-user.target.wants).

2016-04-26 14:14 GMT+02:00 george Karakou:


It's actually NetworkManager-dispatcher whose actual job is -if i am not
mistaken- to run some scripts after NetworkManager main process. Though i
have configured NetworkManager-wait-online too but systemd's parallelizazion
is unbeatable: services are started in parallel and i see other services
that i have ordered after dispatcher finishing starting and dispatcher is
still exec'ing my scripts.

On 04/26/2016 01:00 PM, Mantas Mikulėnas wrote:

Well, this sounds like your service should have some equivalent to
NetworkManager's or systemd-networkd's "wait-until-online" tools.

For example, there's NetworkManager-wait-online.service which blocks until
NM has configured at least one connection fully, so other services can order
against it (usually via network-online.target).

(In fact, this sounds like you're talking about NetworkManager...)


On Tue, Apr 26, 2016, 12:42 george Karakou
wrote:

On 04/26/2016 09:35 AM, Andrei Borzenkov wrote:

On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
  wrote:

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually) scripts and
with the parallel nature of systemd init process it doesn't fully start up
before some other units i have starting after it. Meaning "After="
directives in [Unit] section don't fully fill my needs here.
Is there a workaround?

Is Type=oneshot an option?

I understand that this demand somewhat violates the
parallel principle of the systemd init daemon but can it somehow be
serialized?
Thanks for any advice.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


The service is of type dbus and i don't know if i want to break its
functionality(since its a system-service and registers a name on the bus).
But thanks.


On 04/26/2016 10:01 AM, Mantas Mikulėnas wrote:

On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
  wrote:

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually) scripts and
with the parallel nature of systemd init process it doesn't fully start up
before some other units i have starting after it. Meaning "After="
directives in [Unit] section don't fully fill my needs here.

No, that's*exactly*  the case for After= directives. To disable
parallelization for some parts of the boot process, you use Before= and
After= – that's it.

That said, if After=foo.service doesn't work properly, it usually means
foo.service is lying to systemd about when it has "finished starting". If
that's the case, you'd have exactly the same problems no matter what kind of
serialization you try to enable.

If your megascript starts multiple daemons, then maybe it should be split
into several independent .service units, one for each daemon? If that's not
acceptable, try changing it to Type=notify, and make it use `systemd-notify
READY=1` once it's done.

--
Mantas Mikulėnas

This service is vital for the networking part since it adds interfaces to
bridge, adds static arp entries and some other stuff and the point is to
have all this networking initialization in a central unit and then start
everything else, after the interfaces have been "upped". And since it is a
dbus service i don't know if i want to "break" it's functionality. Anyway i
don't see anything severely broken, like firewalls complaining of
non-existent interfaces after they have initialized, so i am aknowledging
this as not so high priority and i therefor thank you both.


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



-- Why is it that all of the instruments seeking intelligent life in the 
universe are pointed away from Earth?






On 04/26/2016 05:37 PM, Mantas Mikulėnas wrote:
On Tue, Apr 26, 2016 at 3:14 PM, george Karakou 
> wrote:


It's actually NetworkManager-dispatcher whose actual job is -if i
am not mistaken- to run some scripts after NetworkManager main
process. Though i have configured NetworkManager-wait-online too
but systemd's parallelizazion is unbeatable: services are started
in parallel and i see other services that i have ordered after
 

Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Reindl Harald



Am 26.04.2016 um 16:37 schrieb Mantas Mikulėnas:

On Tue, Apr 26, 2016 at 3:14 PM, george Karakou
> wrote:

It's actually NetworkManager-dispatcher whose actual job is -if i am
not mistaken- to run some scripts after NetworkManager main process.
Though i have configured NetworkManager-wait-online too but
systemd's parallelizazion is unbeatable: services are started in
parallel and i see other services that i have ordered after
dispatcher finishing starting and dispatcher is still exec'ing my
scripts.

Because systemd _does not know_ that the dispatcher daemon is doing
something in the background.

You seem to be convinced that systemd is doing some trickery to
parallelize NM. Meanwhile it's the exact opposite


and what is the solution for such cases when it does and can not know 
but continues fire up parallel things which need proper ordering?


or in other words how is "NetworkManager-wait-online" supposed to do the 
job it's name implies in case of a systemd environment?




signature.asc
Description: OpenPGP digital signature
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Mantas Mikulėnas
On Tue, Apr 26, 2016 at 3:14 PM, george Karakou 
wrote:

> It's actually NetworkManager-dispatcher whose actual job is -if i am not
> mistaken- to run some scripts after NetworkManager main process. Though i
> have configured NetworkManager-wait-online too but systemd's
> parallelizazion is unbeatable: services are started in parallel and i see
> other services that i have ordered after dispatcher finishing starting and
> dispatcher is still exec'ing my scripts.
>

Because systemd _does not know_ that the dispatcher daemon is doing
something in the background.

You seem to be convinced that systemd is doing some trickery to parallelize
NM. Meanwhile it's the exact opposite.

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


Re: [systemd-devel] about systemd-system-update-generator

2016-04-26 Thread Lennart Poettering
On Tue, 26.04.16 19:05, samyan...@gmail.com (samyan...@gmail.com) wrote:

> Hi:

> The systemd-system-update-generator use the argv[2],but it runs very
> early at boot.  How to transfer the three parameters to it? I am
> trying implement the offline update by the advice of systemd.

Not sure I follow the question, but see the systemd.generator(5) man
page about details on how generators work.

It's systemd that invokes them at boot time and when "systemctl
daemon-reload" is issue. It passes three directories as arguments that
it creates on-demand.

Lennart

-- 
Lennart Poettering, Red Hat
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Michael Biebl
Ordering after the dispatcher won't help.
The dispatcher is not part of the initial transaction (e.g. pulled in
by multi-user.target.wants).

2016-04-26 14:14 GMT+02:00 george Karakou :
> It's actually NetworkManager-dispatcher whose actual job is -if i am not
> mistaken- to run some scripts after NetworkManager main process. Though i
> have configured NetworkManager-wait-online too but systemd's parallelizazion
> is unbeatable: services are started in parallel and i see other services
> that i have ordered after dispatcher finishing starting and dispatcher is
> still exec'ing my scripts.
>
> On 04/26/2016 01:00 PM, Mantas Mikulėnas wrote:
>
> Well, this sounds like your service should have some equivalent to
> NetworkManager's or systemd-networkd's "wait-until-online" tools.
>
> For example, there's NetworkManager-wait-online.service which blocks until
> NM has configured at least one connection fully, so other services can order
> against it (usually via network-online.target).
>
> (In fact, this sounds like you're talking about NetworkManager...)
>
>
> On Tue, Apr 26, 2016, 12:42 george Karakou 
> wrote:
>>
>>
>> On 04/26/2016 09:35 AM, Andrei Borzenkov wrote:
>>
>> On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
>>  wrote:
>>
>> Hi list, how are you all? I hope everyone is doing well.
>> I have a long starting unit that executes some(many actually) scripts and
>> with the parallel nature of systemd init process it doesn't fully start up
>> before some other units i have starting after it. Meaning "After="
>> directives in [Unit] section don't fully fill my needs here.
>> Is there a workaround?
>>
>> Is Type=oneshot an option?
>>
>> I understand that this demand somewhat violates the
>> parallel principle of the systemd init daemon but can it somehow be
>> serialized?
>> Thanks for any advice.
>> ___
>> systemd-devel mailing list
>> systemd-devel@lists.freedesktop.org
>> https://lists.freedesktop.org/mailman/listinfo/systemd-devel
>>
>>
>> The service is of type dbus and i don't know if i want to break its
>> functionality(since its a system-service and registers a name on the bus).
>> But thanks.
>>
>>
>> On 04/26/2016 10:01 AM, Mantas Mikulėnas wrote:
>>
>> On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
>>  wrote:
>>>
>>> Hi list, how are you all? I hope everyone is doing well.
>>> I have a long starting unit that executes some(many actually) scripts and
>>> with the parallel nature of systemd init process it doesn't fully start up
>>> before some other units i have starting after it. Meaning "After="
>>> directives in [Unit] section don't fully fill my needs here.
>>
>>
>> No, that's *exactly* the case for After= directives. To disable
>> parallelization for some parts of the boot process, you use Before= and
>> After= – that's it.
>>
>> That said, if After=foo.service doesn't work properly, it usually means
>> foo.service is lying to systemd about when it has "finished starting". If
>> that's the case, you'd have exactly the same problems no matter what kind of
>> serialization you try to enable.
>>
>> If your megascript starts multiple daemons, then maybe it should be split
>> into several independent .service units, one for each daemon? If that's not
>> acceptable, try changing it to Type=notify, and make it use `systemd-notify
>> READY=1` once it's done.
>>
>> --
>> Mantas Mikulėnas 
>>
>> This service is vital for the networking part since it adds interfaces to
>> bridge, adds static arp entries and some other stuff and the point is to
>> have all this networking initialization in a central unit and then start
>> everything else, after the interfaces have been "upped". And since it is a
>> dbus service i don't know if i want to "break" it's functionality. Anyway i
>> don't see anything severely broken, like firewalls complaining of
>> non-existent interfaces after they have initialized, so i am aknowledging
>> this as not so high priority and i therefor thank you both.
>
>
>
> ___
> systemd-devel mailing list
> systemd-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/systemd-devel
>



-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread george Karakou
It's actually NetworkManager-dispatcher whose actual job is -if i am not 
mistaken- to run some scripts after NetworkManager main process. Though 
i have configured NetworkManager-wait-online too but systemd's 
parallelizazion is unbeatable: services are started in parallel and i 
see other services that i have ordered after dispatcher finishing 
starting and dispatcher is still exec'ing my scripts.


On 04/26/2016 01:00 PM, Mantas Mikulėnas wrote:


Well, this sounds like your service should have some equivalent to 
NetworkManager's or systemd-networkd's "wait-until-online" tools.


For example, there's NetworkManager-wait-online.service which blocks 
until NM has configured at least one connection fully, so other 
services can order against it (usually via network-online.target).


(In fact, this sounds like you're talking about NetworkManager...)


On Tue, Apr 26, 2016, 12:42 george Karakou > wrote:



On 04/26/2016 09:35 AM, Andrei Borzenkov wrote:

On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
   wrote:

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually) scripts and
with the parallel nature of systemd init process it doesn't fully start up
before some other units i have starting after it. Meaning "After="
directives in [Unit] section don't fully fill my needs here.
Is there a workaround?

Is Type=oneshot an option?


I understand that this demand somewhat violates the
parallel principle of the systemd init daemon but can it somehow be
serialized?
Thanks for any advice.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org

https://lists.freedesktop.org/mailman/listinfo/systemd-devel


The service is of type dbus and i don't know if i want to break
its functionality(since its a system-service and registers a name
on the bus). But thanks.


On 04/26/2016 10:01 AM, Mantas Mikulėnas wrote:

On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
>
wrote:

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually)
scripts and with the parallel nature of systemd init process
it doesn't fully start up before some other units i have
starting after it. Meaning "After=" directives in [Unit]
section don't fully fill my needs here.


No, that's *exactly* the case for After= directives. To disable
parallelization for some parts of the boot process, you use
Before= and After= – that's it.

That said, if After=foo.service doesn't work properly, it usually
means foo.service is lying to systemd about when it has "finished
starting". If that's the case, you'd have exactly the same
problems no matter what kind of serialization you try to enable.

If your megascript starts multiple daemons, then maybe it should
be split into several independent .service units, one for each
daemon? If that's not acceptable, try changing it to Type=notify,
and make it use `systemd-notify READY=1` once it's done.

-- 
Mantas Mikulėnas >

This service is vital for the networking part since it adds
interfaces to bridge, adds static arp entries and some other stuff
and the point is to have all this networking initialization in a
central unit and then start everything else, after the interfaces
have been "upped". And since it is a dbus service i don't know if
i want to "break" it's functionality. Anyway i don't see anything
severely broken, like firewalls complaining of non-existent
interfaces after they have initialized, so i am aknowledging this
as not so high priority and i therefor thank you both.



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


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Mantas Mikulėnas
Well, this sounds like your service should have some equivalent to
NetworkManager's or systemd-networkd's "wait-until-online" tools.

For example, there's NetworkManager-wait-online.service which blocks until
NM has configured at least one connection fully, so other services can
order against it (usually via network-online.target).

(In fact, this sounds like you're talking about NetworkManager...)

On Tue, Apr 26, 2016, 12:42 george Karakou 
wrote:

>
> On 04/26/2016 09:35 AM, Andrei Borzenkov wrote:
>
> On Tue, Apr 26, 2016 at 9:27 AM, george Karakou 
>  wrote:
>
> Hi list, how are you all? I hope everyone is doing well.
> I have a long starting unit that executes some(many actually) scripts and
> with the parallel nature of systemd init process it doesn't fully start up
> before some other units i have starting after it. Meaning "After="
> directives in [Unit] section don't fully fill my needs here.
> Is there a workaround?
>
> Is Type=oneshot an option?
>
>
> I understand that this demand somewhat violates the
> parallel principle of the systemd init daemon but can it somehow be
> serialized?
> Thanks for any advice.
> ___
> systemd-devel mailing 
> listsystemd-devel@lists.freedesktop.orghttps://lists.freedesktop.org/mailman/listinfo/systemd-devel
>
>
> The service is of type dbus and i don't know if i want to break its
> functionality(since its a system-service and registers a name on the bus).
> But thanks.
>
>
> On 04/26/2016 10:01 AM, Mantas Mikulėnas wrote:
>
> On Tue, Apr 26, 2016 at 9:27 AM, george Karakou <
> mad-proffes...@hotmail.com> wrote:
>
>> Hi list, how are you all? I hope everyone is doing well.
>> I have a long starting unit that executes some(many actually) scripts and
>> with the parallel nature of systemd init process it doesn't fully start up
>> before some other units i have starting after it. Meaning "After="
>> directives in [Unit] section don't fully fill my needs here.
>>
>
> No, that's *exactly* the case for After= directives. To disable
> parallelization for some parts of the boot process, you use Before= and
> After= – that's it.
>
> That said, if After=foo.service doesn't work properly, it usually means
> foo.service is lying to systemd about when it has "finished starting". If
> that's the case, you'd have exactly the same problems no matter what kind
> of serialization you try to enable.
>
> If your megascript starts multiple daemons, then maybe it should be split
> into several independent .service units, one for each daemon? If that's not
> acceptable, try changing it to Type=notify, and make it use `systemd-notify
> READY=1` once it's done.
>
> --
> Mantas Mikulėnas 
>
> This service is vital for the networking part since it adds interfaces to
> bridge, adds static arp entries and some other stuff and the point is to
> have all this networking initialization in a central unit and then start
> everything else, after the interfaces have been "upped". And since it is a
> dbus service i don't know if i want to "break" it's functionality. Anyway i
> don't see anything severely broken, like firewalls complaining of
> non-existent interfaces after they have initialized, so i am aknowledging
> this as not so high priority and i therefor thank you both.
>
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread george Karakou


On 04/26/2016 09:35 AM, Andrei Borzenkov wrote:

On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
 wrote:

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually) scripts and
with the parallel nature of systemd init process it doesn't fully start up
before some other units i have starting after it. Meaning "After="
directives in [Unit] section don't fully fill my needs here.
Is there a workaround?

Is Type=oneshot an option?


I understand that this demand somewhat violates the
parallel principle of the systemd init daemon but can it somehow be
serialized?
Thanks for any advice.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


The service is of type dbus and i don't know if i want to break its 
functionality(since its a system-service and registers a name on the 
bus). But thanks.


On 04/26/2016 10:01 AM, Mantas Mikulėnas wrote:
On Tue, Apr 26, 2016 at 9:27 AM, george Karakou 
> wrote:


Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually)
scripts and with the parallel nature of systemd init process it
doesn't fully start up before some other units i have starting
after it. Meaning "After=" directives in [Unit] section don't
fully fill my needs here.


No, that's *exactly* the case for After= directives. To disable 
parallelization for some parts of the boot process, you use Before= 
and After= – that's it.


That said, if After=foo.service doesn't work properly, it usually 
means foo.service is lying to systemd about when it has "finished 
starting". If that's the case, you'd have exactly the same problems no 
matter what kind of serialization you try to enable.


If your megascript starts multiple daemons, then maybe it should be 
split into several independent .service units, one for each daemon? If 
that's not acceptable, try changing it to Type=notify, and make it use 
`systemd-notify READY=1` once it's done.


--
Mantas Mikulėnas >
This service is vital for the networking part since it adds interfaces 
to bridge, adds static arp entries and some other stuff and the point is 
to have all this networking initialization in a central unit and then 
start everything else, after the interfaces have been "upped". And since 
it is a dbus service i don't know if i want to "break" it's 
functionality. Anyway i don't see anything severely broken, like 
firewalls complaining of non-existent interfaces after they have 
initialized, so i am aknowledging this as not so high priority and i 
therefor thank you both.
___
systemd-devel mailing list
systemd-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/systemd-devel


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Mantas Mikulėnas
On Tue, Apr 26, 2016 at 9:27 AM, george Karakou 
wrote:

> Hi list, how are you all? I hope everyone is doing well.
> I have a long starting unit that executes some(many actually) scripts and
> with the parallel nature of systemd init process it doesn't fully start up
> before some other units i have starting after it. Meaning "After="
> directives in [Unit] section don't fully fill my needs here.
>

No, that's *exactly* the case for After= directives. To disable
parallelization for some parts of the boot process, you use Before= and
After= – that's it.

That said, if After=foo.service doesn't work properly, it usually means
foo.service is lying to systemd about when it has "finished starting". If
that's the case, you'd have exactly the same problems no matter what kind
of serialization you try to enable.

If your megascript starts multiple daemons, then maybe it should be split
into several independent .service units, one for each daemon? If that's not
acceptable, try changing it to Type=notify, and make it use `systemd-notify
READY=1` once it's done.

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


Re: [systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread Andrei Borzenkov
On Tue, Apr 26, 2016 at 9:27 AM, george Karakou
 wrote:
> Hi list, how are you all? I hope everyone is doing well.
> I have a long starting unit that executes some(many actually) scripts and
> with the parallel nature of systemd init process it doesn't fully start up
> before some other units i have starting after it. Meaning "After="
> directives in [Unit] section don't fully fill my needs here.
> Is there a workaround?

Is Type=oneshot an option?

> I understand that this demand somewhat violates the
> parallel principle of the systemd init daemon but can it somehow be
> serialized?
> Thanks for any advice.
> ___
> 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


[systemd-devel] Require a systemd.unit to finish completely before other services(units) are started

2016-04-26 Thread george Karakou

Hi list, how are you all? I hope everyone is doing well.
I have a long starting unit that executes some(many actually) scripts 
and with the parallel nature of systemd init process it doesn't fully 
start up before some other units i have starting after it. Meaning 
"After=" directives in [Unit] section don't fully fill my needs here.
Is there a workaround? I understand that this demand somewhat violates 
the parallel principle of the systemd init daemon but can it somehow be 
serialized?

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