napalm-automation / napalm-junos

Apache License 2.0
22 stars 42 forks source link

Feature request: Support interface units #158

Closed martzuk closed 6 years ago

martzuk commented 7 years ago

Description of Issue/Question

Junos has a concept of physical and logical interfaces. Physical: xe-0/0/0 Logical xe-0/0/0.0

In practice this means xe-0/0/0 will hold physical properties of a port e.g. speed. xe-0/0/0.0 will hold logical properties such as IP addresses etc.

On Napalm-EOS this already seems to be supported, as subinterfaces:

marty@box01:~$ sudo salt edge01.xxx01 net.interfaces
edge01.xxx01:
    ----------
    comment:
    out:
        ---
[SNIP]
        Ethernet45:
            ----------
            description:
                IXP
            is_enabled:
                True
            is_up:
                True
            last_flapped:
                1487297742.56
            mac_address:
                11:22:33:44:55:66
            speed:
                10000
        Ethernet45.11:
            ----------
            description:
                IXP Primary
            is_enabled:
                True
            is_up:
                True
            last_flapped:
                1487297742.66
            mac_address:
                11:22:33:44:55:66
            speed:
                10000
        Ethernet45.12:
            ----------
            description:
                IXP Secondary
            is_enabled:
                True
            is_up:
                True
            last_flapped:
                1487297742.66
            mac_address:
                11:22:33:44:55:66
            speed:
                10000
[SNIP]

It would be great to have this same functionality on Juniper

mirceaulinic commented 6 years ago

This will be tracked under https://github.com/napalm-automation/napalm/issues/431