Skip to content

kernel: interfaces altname support #6786

@k0ste

Description

@k0ste

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=7a56493f0620
https://git.kernel.org/pub/scm/network/iproute2/iproute2.git/commit/?id=3aa0e51be

Support is added recently in systemd/systemd#14350
Tested with frr 7.4

Set alternative name to the interface:

ip link property add gig0 altname vrrp0

See interface altnames:

[root@linux01 ~]# ip link show gig0
2: gig0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 08:00:27:d3:fb:ea brd ff:ff:ff:ff:ff:ff
    altname vrrp0

Work with altnames of interface:

[root@linux01 ~]# ip link show vrrp0
2: gig0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000
    link/ether 08:00:27:d3:fb:ea brd ff:ff:ff:ff:ff:ff
    altname vrrp0

Frr currently can't work with altnames of interface:

Hello, this is FRRouting (version 7.4).
Copyright 1996-2005 Kunihiro Ishiguro, et al.

linux01# sh interface 
Interface gig0 is up, line protocol is up
  Link ups:       0    last: (never)
  Link downs:     0    last: (never)
  vrf: default
  index 2 metric 0 mtu 1500 speed 1000 
  flags: <UP,BROADCAST,RUNNING,MULTICAST>
  Type: Ethernet
  HWaddr: 08:00:27:d3:fb:ea
  inet 192.168.4.86/26
  Interface Type Other
Interface lo is up, line protocol is up
  Link ups:       0    last: (never)
  Link downs:     0    last: (never)
  vrf: default
  index 1 metric 0 mtu 65536 speed 0 
  flags: <UP,LOOPBACK,RUNNING>
  Type: Loopback
  Interface Type Other
linux01# sh interface vrrp0
% Can't find interface vrrp0
linux01# 

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions