Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
"Some dhcpcd hooks are now examples"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Mon Jan 11, 2016 11:12 am    Post subject: "Some dhcpcd hooks are now examples" Reply with quote

https://gentoo.org/support/news-items/2016-01-08-some-dhcpcd-hooks-are-now-examples.html wrote:
Title: Some dhcpcd hooks are now examples
Author: William Hubbs <williamh@gentoo.org>
Content-Type: text/plain
Posted: 2016-01-08
Revision: 2
News-Item-Format: 1.0
Display-If-Installed: <=net-misc/dhcpcd-6.10.0

In dhcpcd-6.10.0, the following hooks are no longer installed in
/lib/dhcpcd/dhcpcd-hooks by default:

10-wpa_supplicant
15-timezone
29-lookup-hostname

These are now installed in /usr/share/dhcpcd/hooks, which is an example
directory.

If you were using these hooks before you upgrade to 6.10.0, you will
need to copy them back to the /lib/dhcpcd/dhcpcd-hooks directory after the
upgrade.

This news item recommends copying files manually into /lib/dhcpcd/dhcpcd-hooks?
After doing so it starts working again. But, couldn't this be done better automatically by using appropriate USE flags in the ebuild?
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Thu Jan 14, 2016 8:28 am    Post subject: Re: "Some dhcpcd hooks are now examples" Reply with quote

charles17 wrote:
This news item recommends copying files manually into /lib/dhcpcd/dhcpcd-hooks?
After doing so it starts working again. But, couldn't this be done better automatically by using appropriate USE flags in the ebuild?

USE flags that don't affect what is delivered, are frowned upon/banned by policy depending on whom you talk with, and whether they want to ignore the policy for situation X.

So in general, no; I'd check the upstream dhcpcd codebase if I were you.
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Thu Jan 14, 2016 6:19 pm    Post subject: Re: "Some dhcpcd hooks are now examples" Reply with quote

steveL wrote:
I'd check the upstream dhcpcd codebase if I were you.


We would find that the Gentoo ebuild and news item are just reflecing upstream at this point.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
steveL
Watchman
Watchman


Joined: 13 Sep 2006
Posts: 5153
Location: The Peanut Gallery

PostPosted: Sat Jan 16, 2016 1:46 pm    Post subject: Re: "Some dhcpcd hooks are now examples" Reply with quote

UberLord wrote:
We would find that the Gentoo ebuild and news item are just reflecing upstream at this point.

Cool, that's pretty much what I expected.
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Wed Mar 23, 2016 11:09 am    Post subject: Reply with quote

A slight update on this .... wpa_supplicant upstream just accepted my patch to allow interface matching
https://w1.fi/cgit/hostap/commit/?id=45e3fc72c61a61dbd1e2fc3fd9fd7bf853b9f5fe
https://w1.fi/cgit/hostap/commit/?id=2e997eece5776eca0a99d53893e343539f9f8eb2

So you can achieve the same functionality that the dhcpcd wpa_supplicant hook script provided like so

conf.d/wpa_supplicant
Code:
wpa_supplicant_args="-B -M -c/etc/wpa_supplicant/wpa_supplicant.conf"


and voila :)
You'll probably have to disable udev network naming rules though.

Of course, you'll either need to apply the above patches to your ebuild, or install a wpa_supplicant git snapshot yourself, or just wait for the next wpa_supplicant release.
Either way, you'll need to enable CONFIG_MATCH_IFACE support when building it.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Wed Mar 23, 2016 12:14 pm    Post subject: Reply with quote

Means with those patches applied, no more need to copy the example hooks but should have wpa_supplicant started as a service?
Then the wiki article needs to be adjusted for next release.

Without epatch_user support in the ebuild I'll prefer waiting for a next wpa_suplicant release.
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Wed Mar 23, 2016 1:02 pm    Post subject: Reply with quote

charles17 wrote:
Means with those patches applied, no more need to copy the example hooks but should have wpa_supplicant started as a service?


Exactly so.

Quote:
Then the wiki article needs to be adjusted for next release.

Without epatch_user support in the ebuild I'll prefer waiting for a next wpa_suplicant release.


I have no idea when that would be, and I would likely forget so I posted this here once the patches were accepted upstream.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Wed Mar 23, 2016 2:47 pm    Post subject: Reply with quote

Thanks for clarification and for all your brilliant work.
Would this change also affect dhcpcd-ui?
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Wed Mar 23, 2016 2:48 pm    Post subject: Reply with quote

No, dhcpcd-ui functions the same as before with this.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Sat Oct 08, 2016 6:39 am    Post subject: Reply with quote

UberLord wrote:
I have no idea when that would be, and I would likely forget so I posted this here once the patches were accepted upstream.
Are the changes included in wpa_supplicant-2.6?
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Sat Oct 08, 2016 1:59 pm    Post subject: Reply with quote

Yes

CONFIG_MATCH_IFACE=yes

is needed to build support in for it though, so the ebuild will probably need to be modified.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Mon Oct 10, 2016 5:43 pm    Post subject: Reply with quote

bug 596606

Will there be any need for running wpa_supplicant as a service then?
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Tue Oct 11, 2016 7:03 pm    Post subject: Reply with quote

Yes, it's now run as a service in the boot or default runlevel.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Mon Dec 19, 2016 3:24 pm    Post subject: Reply with quote

UberLord wrote:
CONFIG_MATCH_IFACE=yes

is needed to build support in for it though, so the ebuild will probably need to be modified.
Maybe I could start a pull request for this.
Should it be activated unconditionally or does it need an additional USE flag?
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Mon Dec 19, 2016 4:52 pm    Post subject: Reply with quote

There is no harm in pulling it in automatically.
There is no real need for a use flag.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
charles17
Advocate
Advocate


Joined: 02 Mar 2008
Posts: 3664

PostPosted: Fri Apr 14, 2017 10:10 am    Post subject: Reply with quote

Now in Gentoo main repository.
Back to top
View user's profile Send private message
dmpogo
Advocate
Advocate


Joined: 02 Sep 2004
Posts: 3267
Location: Canada

PostPosted: Sun Jul 02, 2017 10:52 pm    Post subject: Reply with quote

A stupid question, does one still need to run dhcpcd as an initi service ? I.e am I to not copying the hook, but running both dhcpcd and wpa_supplicant (with M option) as services ?
Back to top
View user's profile Send private message
UberLord
Retired Dev
Retired Dev


Joined: 18 Sep 2003
Posts: 6835
Location: Blighty

PostPosted: Mon Jul 03, 2017 12:50 am    Post subject: Reply with quote

You run both as a service.
_________________
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Back to top
View user's profile Send private message
dmpogo
Advocate
Advocate


Joined: 02 Sep 2004
Posts: 3267
Location: Canada

PostPosted: Fri Jul 07, 2017 3:42 pm    Post subject: Reply with quote

UberLord wrote:
You run both as a service.


Thx, works nicely !
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum