[GLLUG] Using IPv6 addresses with Debian

Chris Bell chrisbell at chrisbell.org.uk
Thu Mar 11 15:30:09 UTC 2021

On Thursday, 11 March 2021 15:22:11 GMT Andy Smith via GLLUG wrote:
> Hi Chris,
> On Thu, Mar 11, 2021 at 03:14:42PM +0000, Chris Bell via GLLUG wrote:
> > I am using Debian 10 Buster on various computers including RaspberryPi and
> > find that I can manually add addresses to a running computer, but if I
> > attempt to configure multiple addresses only the last is accepted, and
> > all but one is lost after a reboot.
> I don't see a concrete question in your email, but for what it's
> worth I add multiple IPv6 addresses on Debian by using pre-up hooks
> in the /etc/network/interfaces file, e.g.:
> iface eth0 inet6 static
>     address 2001:ba8:1f1:f019::2
>     netmask 64
>     gateway fe80::fcff:ffff:feff:ffff
>     pre-up ip -6 addr add 2001:ba8:1f1:f019::3/64 dev $IFACE preferred_lft 0
> pre-up ip -6 addr add 2001:ba8:1f1:f019::4/64 dev $IFACE preferred_lft 0
> The "preferred_lft 0" bit is so that the addresses are present and
> usable for daemons to bind to, but will never be used as a source
> address for outgoing traffic. Without that, the last added address
> will be used as the source address.
> Cheers,
> Andy
Thanks for the reply, I will try that.

Chris Bell
Website http://chrisbell.org.uk

More information about the GLLUG mailing list