You are not logged in.

#1 2019-08-21 12:32:12

insidetrip101
Member
Registered: 2019-08-18
Posts: 7

[SOLVED]Question Re: "dhcpcd - dhcpcd@.service causes slow startup"

No actual problem here, just trying to understand what's going on.

The page link is here

My question is why is it necessary to have a blank

ExecStart=

before placing the command to start up dhcpcd with your interface and other arguments?

I believe that the wiki is indeed correct, because I've tried to run this without it, but it fails to run. I just don't understand why I'd need 2 ExecStart calls with the first one being blank.

If someone could explain the logic to me it would be greatly appreciated!

Maybe we could update the wiki to provide a brief explanation as to why this is the case?

Last edited by insidetrip101 (2019-08-21 23:39:46)

Offline

#2 2019-08-21 12:37:52

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 23,447

Re: [SOLVED]Question Re: "dhcpcd - dhcpcd@.service causes slow startup"

Read the link passing you to the unit editing and then to  drop-in file information.

In general, it's to tell the parser (as ExecStart may be supplied multiple times) that it should ignore whatever comes before and just use the list that comes after the empty assignment. (Because it is a drop-in file and the other non overridden information is supplied from the original service file)

You shouldn't add this information to the section you linked to, as one is expected to follow links to further explanations if necessary.

Last edited by V1del (2019-08-21 12:56:05)

Offline

#3 2019-08-21 23:30:49

insidetrip101
Member
Registered: 2019-08-18
Posts: 7

Re: [SOLVED]Question Re: "dhcpcd - dhcpcd@.service causes slow startup"

I'm sorry, I don't see any links in that section.

Are you referring to the "See also" at the end of the page linking to the man pages? I didn't bother following those links, because I just skimmed the man pages in console and didn't find a satisfactory response (not to mention having read the systemctl man page in its entirety in the past).

But even still, what you're saying doesn't make sense to me. Why would I have a blank StartExec command as, by definition, these unit edits are overwriting what "comes before."

Part of what makes this confusing to me is that I've not seen this before. That could be because of a lack of experience, but that's why I'm making a post about it.

Edit: WHOOPS

There is a link to drop in file just like you said. I need to change my default visited link color. I totally over looked it because it blended in with the text. I'll go ahead and read that (but since I've visited it, I think I have already read it). I'll see if your augmentation to that link will help me understand.

Edit 2:

After reading this page again, I remember my confusion about the "type=oneshot" comment on here. But I'm begining to think that this is more of a question about Systemd and less about arch. Therefore, I'm going to mark this as solved and inquire about systemd elsewhere. Sorry if this went off topic.

Edit 3:

Kinda pointless at this point, but after reading this, it seems that I'm not the only one confused about why this is. . .

Last edited by insidetrip101 (2019-08-21 23:51:09)

Offline

#4 2019-08-21 23:54:50

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: [SOLVED]Question Re: "dhcpcd - dhcpcd@.service causes slow startup"

insidetrip101 wrote:

I'm begining to think that this is more of a question about Systemd and less about arch.

This is still an appropriate place to discuss it.

insidetrip101 wrote:

But even still, what you're saying doesn't make sense to me. Why would I have a blank StartExec command as, by definition, these unit edits are overwriting what "comes before."

It doesn't overwrite, it ammends.  ExecStart is different that most other entries in unit files: most other entries have a single value, so each time the entry is read it overwrites any previous setting for that entry whether than previous setting was in a different file or the same file.  ExecStart is not over written by new ExecStart entries (again, regardless of whether they are in the same file or a different file as is the case here), rather each new value is appended to a list.  The empty value is the mechanism to clear out the existing list.  Without the empty ExecStart line, the drop-in file would result in dhcpcd being started twice, once with the -w flag and once without.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

Board footer

Powered by FluxBB