You are not logged in.
Hello everyone,
Last week, I upgraded my laptop from Devuan 4 to Devuan 5. However, next boot, I can see it starting DHCP and I have to wait for it. However, since it doesn't let other services run, this broke my whole wifi setup. (I use IWD with ifupdown, it runs ifupdown first and then iwd).
Is there a way to fix this?
Here is my /etc/network/interfaces file:
source /etc/network/interfaces.d/*
allow-hotplug wlan0
iface wlan0 inet dhcp
Best regards,
tf
Last edited by tf (2023-10-14 13:40:59)
Offline
You should also add as first line auto wlan0
Offline
You should also add as first line auto wlan0
That would make it wait till DHCP has finished which breaks my networking setup. allow-hotplug used to make sure it didn't wait for DHCP but that seems to no longer be the case.
Offline
I fixed this by using ifplugd and not using ifupdown's built-in allow-hotplug.
Offline
I fixed this by using ifplugd and not using ifupdown's built-in allow-hotplug.
Did you read where ifplugd come from?
apt show ifplugd
Package: ifplugd
Version: 0.28-19.5
Priority: optional
Section: net
Maintainer: Walter Franzini <walter.franzini@gmail.com>
Installed-Size: 222 kB
Depends: libc6 (>= 2.15), libdaemon0 (>= 0.10), debconf (>= 0.5) | debconf-2.0, lsb-base (>= 3.0-6)
Recommends: ifupdown (>= 0.6.4-4.2)
Suggests: wpasupplicant
Homepage: http://0pointer.de/lennart/projects/ifplugd/
Tag: hardware::laptop, implemented-in::c, interface::daemon,
network::configuration, protocol::ethernet, role::program,
scope::application, use::configuring, use::monitor
Download-Size: 65.5 kB
APT-Sources: http://deb.devuan.org/merged daedalus/main amd64 Packages
Description: configuration daemon for ethernet devices
😱
Offline
tf wrote:I fixed this by using ifplugd and not using ifupdown's built-in allow-hotplug.
Did you read where ifplugd come from?
apt show ifplugd Package: ifplugd Version: 0.28-19.5 Priority: optional Section: net Maintainer: Walter Franzini <walter.franzini@gmail.com> Installed-Size: 222 kB Depends: libc6 (>= 2.15), libdaemon0 (>= 0.10), debconf (>= 0.5) | debconf-2.0, lsb-base (>= 3.0-6) Recommends: ifupdown (>= 0.6.4-4.2) Suggests: wpasupplicant Homepage: http://0pointer.de/lennart/projects/ifplugd/ Tag: hardware::laptop, implemented-in::c, interface::daemon, network::configuration, protocol::ethernet, role::program, scope::application, use::configuring, use::monitor Download-Size: 65.5 kB APT-Sources: http://deb.devuan.org/merged daedalus/main amd64 Packages Description: configuration daemon for ethernet devices
😱
Ifplugd was the only workaround to my problem that I found that didn't involve using NetworkManager.
Last edited by tf (2023-10-21 15:24:30)
Offline
Replaced ifplugd with netplugd, also works.
Offline
Thank you!
Offline
I fixed this by using ifplugd and not using ifupdown's built-in allow-hotplug.
Can you explain a little bit better what you did?
Thanks!
Offline
tf wrote:I fixed this by using ifplugd and not using ifupdown's built-in allow-hotplug.
Can you explain a little bit better what you did?
Thanks!
Remove all allow-hotplug and auto lines (except for lo) from /etc/network/interfaces, like this:
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
iface eth0 inet dhcp
iface usb0 inet dhcp
iface wlan0 inet dhcp
Replace /etc/netplug/netplug with all of this:
#!/bin/sh
#
# netplug - policy agent for netplugd
#
# Copyright 2003 Key Research, Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License, version 2, as
# published by the Free Software Foundation. You are forbidden from
# redistributing or modifying it under the terms of any other license,
# including other versions of the GNU General Public License.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# General Public License for more details.
PATH=/usr/bin:/bin:/usr/sbin:/sbin
export PATH
dev="$1"
action="$2"
case "$action" in
in)
if [ -x /sbin/ifup ]; then
exec /sbin/ifup "$dev"
else
echo "Please teach me how to plug in an interface!" 1>&2
exit 1
fi
;;
out)
if [ -x /sbin/ifdown ]; then
# At least on Fedora Core 1, the call to ip addr flush infloops
# /sbin/ifdown $dev && exec /sbin/ip addr flush $dev
if ! [ -d "/sys/class/net/$dev/wireless" ]; then
exec /sbin/ifdown "$dev"
else
# Do the same thing as ifdown (kill dhcp process, etc.) without putting the interface down
# Putting the interface fully down will break IWD.
eval "$(ifdown -n -f "$dev" 2>&1 | tail -n +2 | tac | tail -n +4 | tac | tr '\n' ';' | head -c -1)" && \
echo > "/var/run/network/ifstate.$dev"
fi
else
echo "Please teach me how to unplug an interface!" 1>&2
exit 1
fi
;;
probe)
exec test -d "/sys/class/net/$dev" >/dev/null 2>&1
;;
*)
echo "I have been called with a funny action of '$action'!" 1>&2
exit 1
;;
esac
And replace /etc/netplug/netplugd.conf with this:
eth*
wlan*
usb*
Offline
Thank you!
Offline
Did you customize the default script?
My WiFi dongle is stuck in a endless loop with your script...
Last edited by Danielsan (2023-10-25 03:55:24)
Offline
Did you customize the default script?
My WiFi dongle is stuck in a endless loop with your script...
Are you using IWD?
Did you remove allow-hotplug?
Did you make sure not to use IWD's built-in DHCP client?
Did you modify /etc/netplug/netplug?
Offline
Are you using IWD?
Hi,
I don't use IWD only interfaces config file.
Did you remove allow-hotplug?
Both auto and allow-hotplug, should I restore auto instead?
Did you make sure not to use IWD's built-in DHCP client?
IWD is not installed!
Did you modify /etc/netplug/netplug?
Yes I did, using the configuration you shared!
I don't actually need the wifi I need it for the eth0, but I guess that if doesn't work is the same for the others, isn't it?
Thanks!
Offline
tf wrote:Are you using IWD?
Hi,
I don't use IWD only interfaces config file.Did you remove allow-hotplug?
Both auto and allow-hotplug, should I restore auto instead?
Did you make sure not to use IWD's built-in DHCP client?
IWD is not installed!
Did you modify /etc/netplug/netplug?
Yes I did, using the configuration you shared!
I don't actually need the wifi I need it for the eth0, but I guess that if doesn't work is the same for the others, isn't it?
Thanks!
This config is designed to specifically work with IWD. It should work like the original script if you are using ethernet (I made it detect if the interface is wireless or not.)
Offline
Please, please STOP FULL-POST QUOTING. Thank you.
Offline
Please, please STOP FULL-POST QUOTING. Thank you.
The Kempster,
It would probably help if you pointed to THIS POST so that you don't come off as so offensive when (cough-cough) requesting for people to please STOP FULL POST QUOTING...by explaining that an administrator has requested the same...instead of coming across as an angry man with an agenda of his own.
Offline
Thanks Amnesiac. Damn good point. I was attempting to find some humour in my post & failed completely.
Offline
This config is designed to specifically work with IWD. It should work like the original script if you are using ethernet (I made it detect if the interface is wireless or not.)
Needless to say that with the default script it doesn't work either.
Offline