谷姐:我们都是谷歌迷
We are all Google fans

Online/OneProvider 服务器 Debian 10 系统配置/开启 IPv6

IPv6

发现Debian 10的系统,按照官方的教程用DHCP客户端获取IPv6地址,一直获取不到…

odhcp6c is a minimal DHCPv6 and RA-client for use in embedded Linux systems especially routers.

openwrt/odhcp6c

一、安装odhcp6c

echo "deb http://httpredir.debian.org/debian experimental main" >> /etc/apt/sources.list
apt-get update
apt-get install odhcp6c

二、编辑interfaces文件,添加内容

vim /etc/network/interfaces
iface eno1 inet6 static
        address  IPv6段
        netmask  掩码长度
post-up odhcp6c -P 64 -c DUID串 eno1 -d
post-up ip -6 a a IPv6段/掩码长度 dev eno1

IPv6段/掩码长度以及DUID串,是发工单问OneProvider客户要。
https://imgs.eatash.com/uploads/20210116154256.png

三、编辑其他文件

编辑local文件,修改或者添加内容

vim /etc/modprobe.d/local.conf
options ipv6 disable=0

编辑modules文件,添加如下字符

vim /etc/modules
ipv6

编辑sysctl文件,添加以下内容

vim /etc/sysctl.conf
net.ipv4.ip_forward=1
net.ipv4.conf.all.rp_filter=1
net.ipv4.icmp_echo_ignore_broadcasts=1
net.ipv4.conf.default.forwarding=1
net.ipv4.conf.default.proxy_arp = 0
net.ipv4.conf.default.send_redirects = 1
net.ipv4.conf.all.send_redirects = 0
net.ipv6.conf.eno1.autoconf=0
net.ipv6.conf.eno1.accept_ra=2
net.ipv6.conf.default.forwarding=1
net.ipv6.conf.all.forwarding=1
net.ipv6.conf.default.proxy_ndp=1
net.ipv6.conf.all.proxy_ndp=1

四、重启服务器

reboot
ip a
blabla
2: eno1
blabla
 inet6 2001:xxx:xxxx:xxx::/64 scope global 
       valid_lft forever preferred_lft forever
blabla
ping6 ipv6.google.com
PING ipv6.google.com(par10s39-in-x0e.1e100.net (2a00:1450:4007:807::200e)) 56 data bytes
64 bytes from par10s39-in-x0e.1e100.net (2a00:1450:4007:807::200e): icmp_seq=1 ttl=119 time=1.04 ms
64 bytes from par10s39-in-x0e.1e100.net (2a00:1450:4007:807::200e): icmp_seq=2 ttl=119 time=5.73 ms

五、小记

很多步骤不太确定是否必要,但用以上的步骤成功获取到IPv6。后面再好好学习下各个步骤的具体用处!

参考
1. https://documentation.online.net/en/dedicated-server/network/ipv6/prefix
2. https://www.fmqcloud.com/archives/pve.html
3. https://www.goojie.eu/23.html

0 0 vote
Article Rating
 收藏 (0) 打赏

您可以选择一种方式赞助本站

支付宝扫一扫赞助

微信钱包扫描赞助

未经允许不得转载:谷姐靓号网 » Online/OneProvider 服务器 Debian 10 系统配置/开启 IPv6

分享到: 生成海报
Subscribe
提醒
guest
0 评论
Inline Feedbacks
View all comments

买Google Voice认准【谷姐靓号网】

Google Voice靓号列表Google Voice自助购买
切换注册

登录

忘记密码 ?

切换登录

注册

我们将发送一封验证邮件至你的邮箱, 请正确填写以完成账号注册和激活

0
Would love your thoughts, please comment.x
()
x