summaryrefslogtreecommitdiff
path: root/rc/bin/cpurc
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2018-08-15 21:39:30 +0200
committercinap_lenrek <cinap_lenrek@felloff.net>2018-08-15 21:39:30 +0200
commitcd752a39f8b0b36378800740c0e5915beabfb56d (patch)
treeb1c2b1c531321704e49928e0771dac90badef186 /rc/bin/cpurc
parentab4c0a012f4b57e9a9a2c084097c919a40029380 (diff)
downloadplan9front-cd752a39f8b0b36378800740c0e5915beabfb56d.tar.xz
ipv6 autoconfiguration on ethernet
for ip autoconfiguration, setup ipv6 link local addresses and do SLAAC in parallel to DHCP.
Diffstat (limited to 'rc/bin/cpurc')
-rwxr-xr-xrc/bin/cpurc10
1 files changed, 7 insertions, 3 deletions
diff --git a/rc/bin/cpurc b/rc/bin/cpurc
index 404f494ff..f1d4dfd99 100755
--- a/rc/bin/cpurc
+++ b/rc/bin/cpurc
@@ -62,9 +62,13 @@ if(test -r /net/ipselftab){
addr=`{cat $ether/addr}
switch($addr){
case $addrs
- # try /lib/ndb first, then do dhcp
- ip/ipconfig -N ether $ether >[2]/dev/null \
- || ip/ipconfig -h $sysname ether $ether
+ # try /lib/ndb first, then do dhcp/slaac
+ ip/ipconfig -6 ether $ether
+ ip/ipconfig -N ether $ether >[2]/dev/null || @{
+ ip/ipconfig ether $ether ra6 recvra 1 &
+ ip/ipconfig -h $sysname ether $ether &
+ wait
+ }
}
}
}