Need to give fallback static ipv6 if dhcpv6 server fails to give dhcpv6 ip

Hi,

I need to give fallback static ipv6 address when dhcpv6 server fails to give ipv6 IP.

Thanks in advance.

To the router itself? To clients of the router?

If it is to the "WAN" interface, if you have a static IPv6 address available, I'm not understanding why you use DHCPv6 at all on that interface.

1 Like

Hi @jeff

I want to give fallback static ipv6 address to the router itself.
I am using DHCPv6 on LAN interface. If somehow DHCPv6 fails to give DHCPv6 IP address to the router then i want to give fallback static IPv6 address.

Thanks in advance

I am interpreting that to mean to the LAN interface, not the WAN interface.

Do you have a DHCPv6 server running somewhere on the LAN network?

I'm not sure of the problem you're trying to solve. Would you state what communication "fails" if the DHCPv6 server fails?

You can assign "as many addresses as you want" to an IPv6 interface. If the interface is working properly, it will automatically have a link-local address that can be used for on-link communication without any DHCPv6 involved. You should be able to assign an IPv6 "global" address from your delegated prefix to the device and have it co-exist with any additionally assigned by DHCPv6.

1 Like

There's no built-in fallback method, but you can use either link-local addresses, or aliases for both static and dynamic addresses:
https://openwrt.org/docs/guide-user/network/network_interface_alias

1 Like