SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Can you test it with a reboot?
I mean, set it to 'yes', then reboot and then see if it comes up OK... I suspect it will, in which case I don't think it's anything to worry about - I don't think (most) people are going to fuzz with that option too much; it'll be a case of turn it on and forget.
It was rebooted multiple times.
I see what the problem is. It's the same problem with interface already up, rc.wireless brings interface up.
Not sure what is the solution for this. Bring it down if it's up, just before it is brought up again? But it doesn't feel very "clean".
It was rebooted multiple times.
I see what the problem is. It's the same problem with interface already up, rc.wireless brings interface up.
Not sure what is the solution for this. Bring it down if it's up, just before it is brought up again? But it doesn't feel very "clean".
Are you using NetworkManager for your wireless? Or setting things up in wpa_supplicant.conf?
If you're using NetworkManager, setting the interface up in rc.inet1 isn't supported anyway - it should be up to NM to set up the interface correctly (and if it doesn't support the security enhancements, then that would seem to be an issue with NM...).
If it's the latter, we can just not leave the interface in an up state at the end of rc.wireless....
Are you using NetworkManager for your wireless? Or setting things up in wpa_supplicant.conf?
If you're using NetworkManager, setting the interface up in rc.inet1 isn't supported anyway - it should be up to NM to set up the interface correctly (and if it doesn't support the security enhancements, then that would seem to be an issue with NM...).
If it's the latter, we can just not leave the interface in an up state at the end of rc.wireless....
No, I'm not using NetworkManager on this laptop. I'm setting things up in wpa_supplicant.conf.
NetworkManager actually works without problem.
No, I'm not using NetworkManager on this laptop. I'm setting things up in wpa_supplicant.conf.
NetworkManager actually works without problem.
I've just added a new branch 'tadgy' to the slacknetsetup git repo - try using the rc.wireless from that and give it a test. Note: it's not the usual 'master' branch as I didn't want to push this to master until we know it fixes the problem.
I've just added a new branch 'tadgy' to the slacknetsetup git repo - try using the rc.wireless from that and give it a test. Note: it's not the usual 'master' branch as I didn't want to push this to master until we know it fixes the problem.
Fingers crossed!
Well, it seems wpa_supplicant or something still brings interface up.
But with patch bellow it works
Code:
diff --git a/rc.wireless b/rc.wireless
index 00df8c3..9eaf0fa 100644
--- a/rc.wireless
+++ b/rc.wireless
@@ -343,7 +343,7 @@ else
echo "$0: $IWCOMMAND essid \"$ESSID\"" | $LOGGER
$IWCOMMAND essid "$ESSID"
fi
- # Tadgy: don't leave interface up as this causes problems for SLAAC in rc.inet1
- $IFCOMMAND down
- sleep 3
fi
+# Tadgy: don't leave interface up as this causes problems for SLAAC in rc.inet1
+$IFCOMMAND down
+sleep 3
I was worried because there is comment "Bring interface up to avoid 'not ready' errors when calling iwconfig"
But iwconfig is never called after this, maybe it was in the past.
diff --git a/rc.wireless b/rc.wireless
index 00df8c3..9eaf0fa 100644
--- a/rc.wireless
+++ b/rc.wireless
@@ -343,7 +343,7 @@ else
echo "$0: $IWCOMMAND essid \"$ESSID\"" | $LOGGER
$IWCOMMAND essid "$ESSID"
fi
- # Tadgy: don't leave interface up as this causes problems for SLAAC in rc.inet1
- $IFCOMMAND down
- sleep 3
fi
+# Tadgy: don't leave interface up as this causes problems for SLAAC in rc.inet1
+$IFCOMMAND down
+sleep 3
I was worried because there is comment "Bring interface up to avoid 'not ready' errors when calling iwconfig"
But iwconfig is never called after this, maybe it was in the past.
That's weird. Where the take down was before only had an effect if the *very* old way of enabling wireless (in rc.wireless.conf) was used; and where I commented out the 'up' for the wpa_supplicant block should have kept it down.
Actually; can you test whether the interface will come up if you *just* configure IPv4 networking on the wifi?
I'm hoping that taking the interface down before control is returned to rc.inet1 doesn't effect bringing up other types of networking if SLAAC isn't used.
Actually; can you test whether the interface will come up if you *just* configure IPv4 networking on the wifi?
I'm hoping that taking the interface down before control is returned to rc.inet1 doesn't effect bringing up other types of networking if SLAAC isn't used.
I'm sure it will, because when SLAAC timeouts interface is brought down anyway. But I will test it.
Edit: Yes it works, DHCP and static configuration.
Could you try patch bellow?
I have similar problem, eventually, IP is assigned but it takes about 5 minutes.
Code:
--- rc.inet1.orig 2021-02-28 22:01:59.000000000 +0100
+++ rc.inet1 2021-03-06 08:00:03.081951586 +0100
@@ -323,6 +323,35 @@
debug_log "/sbin/ip address flush dev ${1}"
/sbin/ip address flush dev ${1}
IF_UP=0
+ if [ -e /proc/sys/net/ipv6 ] && [ "${USE_DHCP6[$i]}" != "yes" ] && [ "${USE_SLAAC[$i]}" = "yes" ]; then # configure via SLAAC
+ info_log "${1}: enabling SLAAC"
+ # Enable accepting of RA packets, unless explicitly configured not to:
+ if [ "${USE_RA[$i]}" = "no" ]; then
+ debug_log "${1}: ignoring IPv6 RA"
+ echo "0" >/proc/sys/net/ipv6/conf/${1}/accept_ra
+ else
+ debug_log "${1}: accepting IPv6 RA"
+ echo "1" >/proc/sys/net/ipv6/conf/${1}/accept_ra
+ fi
+ # Enable auto configuration of interfaces:
+ echo "1" >/proc/sys/net/ipv6/conf/${1}/autoconf
+ # Bring the interface up:
+ debug_log "/sbin/ip link set dev ${1} up"
+ /sbin/ip link set dev ${1} up
+ echo "${1}: waiting for router announcement"
+ for ((j = ${SLAAC_TIMEOUT[$i]:=15} * 2; j--;)); do # by default, wait a max of 15 seconds for the interface to configure
+ /sbin/ip -6 address show dynamic dev ${1} 2>/dev/null | grep -Ewq 'inet6' && { IF_UP=1; break; }
+ sleep 0.5
+ done
+ if ((IF_UP != 1)); then
+ echo "${1}: timed out"
+ info_log "${1}: failed to auto configure after ${SLAAC_TIMEOUT[$i]} seconds"
+ debug_log "/sbin/ip address flush dev ${1}"
+ /sbin/ip address flush dev ${1}
+ debug_log "/sbin/ip link set dev ${1} down"
+ /sbin/ip link set dev ${1} down
+ fi
+ fi
# Slackware historically favours dynamic configuration over fixed IP to configure interfaces, so keep that tradition:
if [ "${USE_DHCP[$i]}" = "yes" ] || { [ -e /proc/sys/net/ipv6 ] && [ "${USE_DHCP6[$i]}" = "yes" ]; }; then # use dhcpcd
info_log "${1}: starting dhcpcd"
@@ -365,35 +394,6 @@
debug_log "/sbin/ip address flush dev ${1}"
/sbin/ip address flush dev ${1}
debug_log "/sbin/ip link set dev ${1} down"
- /sbin/ip link set dev ${1} down
- fi
- fi
- if [ -e /proc/sys/net/ipv6 ] && [ "${USE_DHCP6[$i]}" != "yes" ] && [ "${USE_SLAAC[$i]}" = "yes" ]; then # configure via SLAAC
- info_log "${1}: enabling SLAAC"
- # Enable accepting of RA packets, unless explicitly configured not to:
- if [ "${USE_RA[$i]}" = "no" ]; then
- debug_log "${1}: ignoring IPv6 RA"
- echo "0" >/proc/sys/net/ipv6/conf/${1}/accept_ra
- else
- debug_log "${1}: accepting IPv6 RA"
- echo "1" >/proc/sys/net/ipv6/conf/${1}/accept_ra
- fi
- # Enable auto configuration of interfaces:
- echo "1" >/proc/sys/net/ipv6/conf/${1}/autoconf
- # Bring the interface up:
- debug_log "/sbin/ip link set dev ${1} up"
- /sbin/ip link set dev ${1} up
- echo "${1}: waiting for router announcement"
- for ((j = ${SLAAC_TIMEOUT[$i]:=15} * 2; j--;)); do # by default, wait a max of 15 seconds for the interface to configure
- /sbin/ip -6 address show dynamic dev ${1} 2>/dev/null | grep -Ewq 'inet6' && { IF_UP=1; break; }
- sleep 0.5
- done
- if ((IF_UP != 1)); then
- echo "${1}: timed out"
- info_log "${1}: failed to auto configure after ${SLAAC_TIMEOUT[$i]} seconds"
- debug_log "/sbin/ip address flush dev ${1}"
- /sbin/ip address flush dev ${1}
- debug_log "/sbin/ip link set dev ${1} down"
/sbin/ip link set dev ${1} down
fi
fi
I have not tried your patch. My issue turned out to be router problem and now Slack. My ipv4 is static so I don't see the same timeout issue you mentioned.
When I try to use a static IPv6 IP and gateway I get:
Code:
Error: egress device not specified
I've never seen that error before, so have no clue what the cause of your problem is
I'd be interested to know whether anyone else gets the same error when they set a static IPv6 gateway in the new rc.inet1.conf? Please post back your results - even if your configuration works correctly, so I can know if it's a one off or a more serious problem.
Quote:
Originally Posted by kaott
I can change line 618 in /etc/rc.d/rc.inet1 to:
Code:
/sbin/ip -6 route add default via ${GATEWAY6} dev eth0
The problem with changing the line to include the device is we'd have to assume which device the data should leave via. What happens if it's actually eth1 that leads to the default gateway?
Consider:
In this case, the gateway is reached via the eth1 device, not the primary interface of the host and your assumption that the interface to be used is eth0 would be wrong. Programmatically it would not be simple to try to determine which interface the gateway should be set for just using the gateway IP itself.
Quote:
Originally Posted by kaott
There are no problems when using a static IPv4 IP and gateway, not sure why the IPv6 requires adding the device name to the command.
I'm not sure why your set up seems to require that either
My testing didn't show up this problem, and I'm hoping that no other reports come in with a similar issue.
I know that doesn't help you a lot - sorry about that - but I don't know if this is something that could be easily fixed :/
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.