pandorabox固件+PPPOE拨号+IPV6

pandorabox固件+PPPOE拨号+IPV6
Step1:刷Pandorabox固件。
Step2:使路由器连接上⽹络,⽤putty登陆路由器
Step3:在putty⾥⾯输⼊
opkg update && opkg install kmod-ipt-nat6
opkg install iputils-tracepath6
uci set network.globals.ula_prefix="$(uci get network.globals.ula_prefix | sed 's/^./d/')"
uci commit network
uci set dhcp.lan.ra_default='1'
uci commit dhcp
touch /etc/init.d/nat6
vi /etc/init.d/nat6
注:nat6中的内容如下
#!/bin/sh /etc/rcmon
# NAT6 init script for OpenWrt // Depends on package: kmod-ipt-nat6
START=55
# Options
# -------
# Use temporary addresses (IPv6 privacy extensions) for outgoing connections? Yes: 1 / No: 0
PRIVACY=1
# Maximum number of attempts before this script will stop in case no IPv6 route is available
# This limits the execution time of the IPv6 route lookup to (MAX_TRIES+1)*(MAX_TRIES/2) seconds. The default (15) equals 120 seconds. MAX_TRIES=15
# An initial delay (in seconds) helps to avoid looking for the IPv6 network too early. Ideally, the first probe is successful.
# This would be the case if the time passed between the system log messages "Probing IPv6 route" and "Setting up NAT6" is 1 second. DELAY=5
# Logical interface name of outbound IPv6 connection
# There should be no need to modify this, unless you changed the default network interface names
# Edit by Vincent: I never changed my default network interface names, but still I have to change the WAN6_NAME to "wan" instead of "wan6" WAN6_NAME="wan6"
# ---------------------------------------------------
# Options end here - no need to change anything below
boot() {
[ $DELAY -gt 0 ] && sleep $DELAY
logger -t NAT6 "Probing IPv6 route"
PPPOE 协议step4:
vim /f
到修改为:
f.default.forwarding=2
f.all.forwarding=2
f.default.accept_ra=2
f.all.accept_ra=2
step5:
vim /etc/config/dhcp
到修改为:
config dhcp lan
option interface lan
option start 100
option limit 150
option leasetime 12h
option dhcpv6 server
option ra server
option ra_management 1
option ra_default 1
step6:
uci set firewall.@rule["$(uci show firewall | grep 'Allow-ICMPv6-Forward' | cut -d'[' -f2 | cut -d']' -f1)"].enabled='0' uci commit firewall
step7:
vim /etc/firewall.user
插⼊:
ip6tables -t nat -I POSTROUTING -s $(uci get network.globals.ula_prefix) -j MASQUERADE step8:
reboot
注意每⼀⾏就是⼀个命令

本文发布于:2024-09-23 18:32:17,感谢您对本站的认可!

本文链接:https://www.17tex.com/tex/1/371374.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:路由器   拨号   找到
留言与评论(共有 0 条评论)
   
验证码:
Copyright ©2019-2024 Comsenz Inc.Powered by © 易纺专利技术学习网 豫ICP备2022007602号 豫公网安备41160202000603 站长QQ:729038198 关于我们 投诉建议