Score:0

ipv6 route add with next hop fails

pl flag

I'm trying to add an ipv6 route on machine B to subnet behind next hop A:

2:2:2::2/64 +---+ 192:168:2::1/64      192:168:2::10/64 +---+
       -----| A |---------------------------------------| B |
            +---+                                       +---+

The next hop (192:168:2::1) is reachable (ping succeeds), yet I cannot add it as a next hop in an ipv6 route:

(B):~ > sudo ip -6 route add 2:2:2::/64 via 192:168:2::1
RTNETLINK answers: Invalid argument

Is it possible to get more details about which argument in the ip route add-command is invalid and why? How can I add a route for an ipv6 subnet that is not locally available?

These are the interfaces on machine B:

(ANDEVVM22):~ > ip -6 addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436
    inet6 ::1/128 scope host
        valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000
    inet6 3000::c066:def9/64 scope global
        valid_lft forever preferred_lft forever
    inet6 fe80::90af:efff:fe88:2e1b/64 scope link
        valid_lft forever preferred_lft forever
3: eth100: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 1000
    inet6 fe80::102e:2eff:fe41:4887/64 scope link
        valid_lft forever preferred_lft forever
4: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 500
    inet6 192:168:1::10/64 scope global
        valid_lft forever preferred_lft forever
5: eth2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qlen 500
    inet6 192:168:2::10/64 scope global
        valid_lft forever preferred_lft forever
John Mahowald avatar
cn flag
Any particular reason you are playing in unallocated bogon space? Generating ULAs, or getting a prefix from an ISP, or even the documentation prefix, would not conflict with the internet.
PieterV avatar
pl flag
This is only used in a test setup, disconnected from the internet. So I assume it doesn't really matter which exact addresses I use?
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.