Ethernet

This will be the most widely used interface on a router carrying traffic to the real world.

Configuration

Common interface configuration

set interfaces ethernet <interface> address <address | dhcp | dhcpv6>

Configure interface <interface> with one or more interface addresses.

  • address can be specified multiple times as IPv4 and/or IPv6 address, e.g. 192.0.2.1/24 and/or 2001:db8::1/64
  • dhcp interface address is received by DHCP from a DHCP server on this segment.
  • dhcpv6 interface address is received by DHCPv6 from a DHCPv6 server on this segment.

Example:

set interfaces ethernet eth0 address 192.0.2.1/24
set interfaces ethernet eth0 address 2001:db8::1/64
set interfaces ethernet eth0 dhcp
set interfaces ethernet eth0 dhcpv6
set interfaces ethernet <interface> description <description>

Set a human readable, descriptive alias for this connection. Alias is used by e.g. the show interfaces command or SNMP based monitoring tools.

Example:

set interfaces ethernet eth0 description 'This is an awesome interface running on VyOS'
set interfaces ethernet <interface> disable

Disable given <interface>. It will be placed in administratively down (A/D) state.

Example:

set interfaces ethernet eth0 disable
set interfaces ethernet <interface> disable-flow-control

Ethernet flow control is a mechanism for temporarily stopping the transmission of data on Ethernet family computer networks. The goal of this mechanism is to ensure zero packet loss in the presence of network congestion.

The first flow control mechanism, the pause frame, was defined by the IEEE 802.3x standard.

A sending station (computer or network switch) may be transmitting data faster than the other end of the link can accept it. Using flow control, the receiving station can signal the sender requesting suspension of transmissions until the receiver catches up.

Use this command to disable the generation of Ethernet flow control (pause frames).

Example:

set interfaces ethernet eth0 disable-flow-control
set interfaces ethernet <interface> disable-link-detect

Use this command to direct an interface to not detect any physical state changes on a link, for example, when the cable is unplugged.

Default is to detects physical link state changes.

Example:

set interfaces ethernet eth0 disable-link-detect
set interfaces ethernet <interface> mac <xx:xx:xx:xx:xx:xx>

Configure user defined MAC address on given <interface>.

Example:

set interfaces ethernet eth0 mac '00:01:02:03:04:05'
set interfaces ethernet <interface> mtu <mtu>

Configure MTU on given <interface>. It is the size (in bytes) of the largest ethernet frame sent on this link.

Example:

set interfaces ethernet eth0 mtu 9000
set interfaces ethernet <interface> ipv6 address autoconf

SLAAC RFC 4862. IPv6 hosts can configure themselves automatically when connected to an IPv6 network using the Neighbor Discovery Protocol via ICMPv6 router discovery messages. When first connected to a network, a host sends a link-local router solicitation multicast request for its configuration parameters; routers respond to such a request with a router advertisement packet that contains Internet Layer configuration parameters.

Note

This method automatically disables IPv6 traffic forwarding on the interface in question.

Example:

set interfaces ethernet eth0 ipv6 address autoconf
set interfaces ethernet <interface> ipv6 address eui64 <prefix>

EUI-64 as specified in RFC 4291 allows a host to assign iteslf a unique 64-Bit IPv6 address.

set interfaces ethernet eth0 ipv6 address eui64 2001:db8:beef::/64
set interfaces ethernet <interface> vrf <vrf>

Place interface in given VRF instance.

See also

There is an entire chapter about how to configure a VRF, please check this for additional information.

Example:

set interfaces ethernet eth0 vrf red

DHCP(v6)

set interfaces ethernet <interface> dhcp-options client-id <description>

RFC 2131 states: The client MAY choose to explicitly provide the identifier through the ‘client identifier’ option. If the client supplies a ‘client identifier’, the client MUST use the same ‘client identifier’ in all subsequent messages, and the server MUST use that identifier to identify the client.

Example:

set interfaces ethernet eth0 dhcp-options client-id 'foo-bar'
set interfaces ethernet <interface> dhcp-options host-name <hostname>

Instead of sending the real system hostname to the DHCP server, overwrite the host-name with this given-value.

Example:

set interfaces ethernet eth0 dhcp-options host-name 'VyOS'
set interfaces ethernet <interface> dhcp-options vendor-class-id <vendor-id>

The vendor-class-id option can be used to request a specific class of vendor options from the server.

Example:

set interfaces ethernet eth0 dhcp-options vendor-class-id 'VyOS'
set interfaces ethernet <interface> dhcp-options no-default-route

Only request an address from the DHCP server but do not request a default gateway.

Example:

set interfaces ethernet eth0 dhcp-options no-default-route
set interfaces ethernet <interface> dhcpv6-options parameters-only

This statement specifies dhcp6c to only exchange informational configuration parameters with servers. A list of DNS server addresses is an example of such parameters. This statement is useful when the client does not need stateful configuration parameters such as IPv6 addresses or prefixes.

set interfaces ethernet eth0 dhcpv6-options parameters-only
set interfaces ethernet <interface> dhcpv6-options rapid-commit

When rapid-commit is specified, dhcp6c will include a rapid-commit option in solicit messages and wait for an immediate reply instead of advertisements.

set interfaces ethernet eth0 dhcpv6-options rapid-commit
set interfaces ethernet <interface> dhcpv6-options temporary

Request only a temporary address and not form an IA_NA (Identity Association for Non-temporary Addresses) partnership.

set interfaces ethernet eth0 dhcpv6-options temporary

DHCPv6 Prefix Delegation (PD)

VyOS 1.3 (equuleus) supports DHCPv6-PD (RFC 3633). DHCPv6 Prefix Delegation is supported by most ISPs who provide native IPv6 for consumers on fixed networks.

set interfaces ethernet <interface> None None None None dhcpv6-option pd <id> length <length>

Some ISPs by default only delegate a /64 prefix. To request for a specific prefix size use this option to request for a bigger delegation for this pd <id>. This value is in the range from 32 - 64 so you could request up to a /32 prefix (if your ISP allows this) down to a /64 delegation.

The default value corresponds to 64.

To request a /56 prefix from your ISP use:

set interfaces ethernet eth0 None None None None dhcpv6-options pd 0 length 56
set interfaces ethernet <interface> None None None None dhcpv6-option pd <id> interface <delegatee> address <address>

Specify the interface address used locally on the interfcae where the prefix has been delegated to. ID must be a decimal integer.

It will be combined with the delegated prefix and the sla-id to form a complete interface address. The default is to use the EUI-64 address of the interface.

Example: Delegate a /64 prefix to interface eth8 which will use a local address on this router of <prefix>::ffff, as the address 65534 will correspond to ffff in hexadecimal notation.

set interfaces ethernet eth0 None None None None dhcpv6-option pd 0 interface eth8 address 65534
set interfaces ethernet <interface> None None None None dhcpv6-option pd <id> interface <delegatee> sla-id <id>

Specify the identifier value of the site-level aggregator (SLA) on the interface. ID must be a decimal number greater then 0 which fits in the length of SLA IDs (see below).

Example: If ID is 1 and the client is delegated an IPv6 prefix 2001:db8:ffff::/48, dhcp6c will combine the two values into a single IPv6 prefix, 2001:db8:ffff:1::/64, and will configure the prefix on the specified interface.

set interfaces ethernet eth0 None None None None dhcpv6-option pd 0 interface eth8 sla-id 1

Ethernet options

set interfaces ethernet <interface> duplex <auto | full | half>

Configure physical interface duplex setting.

  • auto - interface duplex setting is auto-negotiated
  • full - always use full-duplex
  • half - always use half-duplex

VyOS default will be auto.

set interfaces ethernet <interface> speed <auto | 10 | 100 | 1000 | 2500 | 5000 | 10000 | 25000 | 40000 | 50000 | 100000>

Configure physical interface speed setting.

  • auto - interface speed is auto-negotiated
  • 10 - 10 MBit/s
  • 100 - 100 MBit/s
  • 1000 - 1 GBit/s
  • 2500 - 2.5 GBit/s
  • 5000 - 5 GBit/s
  • 10000 - 10 GBit/s
  • 25000 - 25 GBit/s
  • 40000 - 40 GBit/s
  • 50000 - 50 GBit/s
  • 100000 - 100 GBit/s

VyOS default will be auto.

set interfaces ethernet <interface> mirror <interface>

Use this command to mirror the inbound traffic from one Ethernet interface to another interface. This feature is typically used to provide a copy of traffic inbound on one interface to a system running a monitoring or IPS application on another interface. The benefit of mirroring the traffic is that the application is isolated from the source traffic and so application processing does not affect the traffic or the system performance.

Example:

set interfaces ethernet eth0 mirror eth1

VLAN

Regular VLANs (802.1q)

IEEE 802.1q, often referred to as Dot1q, is the networking standard that supports virtual LANs (VLANs) on an IEEE 802.3 Ethernet network. The standard defines a system of VLAN tagging for Ethernet frames and the accompanying procedures to be used by bridges and switches in handling such frames. The standard also contains provisions for a quality-of-service prioritization scheme commonly known as IEEE 802.1p and defines the Generic Attribute Registration Protocol.

Portions of the network which are VLAN-aware (i.e., IEEE 802.1q conformant) can include VLAN tags. When a frame enters the VLAN-aware portion of the network, a tag is added to represent the VLAN membership. Each frame must be distinguishable as being within exactly one VLAN. A frame in the VLAN-aware portion of the network that does not contain a VLAN tag is assumed to be flowing on the native VLAN.

The standard was developed by IEEE 802.1, a working group of the IEEE 802 standards committee, and continues to be actively revised. One of the notable revisions is 802.1Q-2014 which incorporated IEEE 802.1aq (Shortest Path Bridging) and much of the IEEE 802.1d standard.

802.1q VLAN interfaces are represented as virtual sub-interfaces in VyOS. The term used for this is vif.

set interfaces ethernet <interface> vif <vlan-id>

Create a new VLAN interface on interface <interface> using the VLAN number provided via <vlan-id>.

You can create multiple VLAN interfaces on a physical interface. The VLAN ID range is from 0 to 4094.

Note

Only 802.1Q-tagged packets are accepted on Ethernet vifs.

set interfaces ethernet <interface> vif <vlan-id> address <address | dhcp | dhcpv6>

Configure interface <interface> with one or more interface addresses.

  • address can be specified multiple times as IPv4 and/or IPv6 address, e.g. 192.0.2.1/24 and/or 2001:db8::1/64
  • dhcp interface address is received by DHCP from a DHCP server on this segment.
  • dhcpv6 interface address is received by DHCPv6 from a DHCPv6 server on this segment.

Example:

set interfaces ethernet eth0 vif 10 address 192.0.2.1/24
set interfaces ethernet eth0 vif 10 address 2001:db8::1/64
set interfaces ethernet eth0 vif 10 dhcp
set interfaces ethernet eth0 vif 10 dhcpv6
set interfaces ethernet <interface> vif <vlan-id> description <description>

Set a human readable, descriptive alias for this connection. Alias is used by e.g. the show interfaces command or SNMP based monitoring tools.

Example:

set interfaces ethernet eth0 vif 10 description 'This is an awesome interface running on VyOS'
set interfaces ethernet <interface> vif <vlan-id> disable

Disable given <interface>. It will be placed in administratively down (A/D) state.

Example:

set interfaces ethernet eth0 vif 10 disable
set interfaces ethernet <interface> vif <vlan-id> disable-link-detect

Use this command to direct an interface to not detect any physical state changes on a link, for example, when the cable is unplugged.

Default is to detects physical link state changes.

Example:

set interfaces ethernet eth0 vif 10 disable-link-detect
set interfaces ethernet <interface> vif <vlan-id> mac <xx:xx:xx:xx:xx:xx>

Configure user defined MAC address on given <interface>.

Example:

set interfaces ethernet eth0 vif 10 mac '00:01:02:03:04:05'
set interfaces ethernet <interface> vif <vlan-id> mtu <mtu>

Configure MTU on given <interface>. It is the size (in bytes) of the largest ethernet frame sent on this link.

Example:

set interfaces ethernet eth0 vif 10 mtu 9000
set interfaces ethernet <interface> vif <vlan-id> ipv6 address autoconf

SLAAC RFC 4862. IPv6 hosts can configure themselves automatically when connected to an IPv6 network using the Neighbor Discovery Protocol via ICMPv6 router discovery messages. When first connected to a network, a host sends a link-local router solicitation multicast request for its configuration parameters; routers respond to such a request with a router advertisement packet that contains Internet Layer configuration parameters.

Note

This method automatically disables IPv6 traffic forwarding on the interface in question.

Example:

set interfaces ethernet eth0 vif 10 ipv6 address autoconf
set interfaces ethernet <interface> vif <vlan-id> ipv6 address eui64 <prefix>

EUI-64 as specified in RFC 4291 allows a host to assign iteslf a unique 64-Bit IPv6 address.

set interfaces ethernet eth0 vif 10 ipv6 address eui64 2001:db8:beef::/64
set interfaces ethernet <interface> vif <vlan-id> vrf <vrf>

Place interface in given VRF instance.

See also

There is an entire chapter about how to configure a VRF, please check this for additional information.

Example:

set interfaces ethernet eth0 vif 10 vrf red

DHCP(v6)

set interfaces ethernet <interface> vif <vlan-id> dhcp-options client-id <description>

RFC 2131 states: The client MAY choose to explicitly provide the identifier through the ‘client identifier’ option. If the client supplies a ‘client identifier’, the client MUST use the same ‘client identifier’ in all subsequent messages, and the server MUST use that identifier to identify the client.

Example:

set interfaces ethernet eth0 vif 10 dhcp-options client-id 'foo-bar'
set interfaces ethernet <interface> vif <vlan-id> dhcp-options host-name <hostname>

Instead of sending the real system hostname to the DHCP server, overwrite the host-name with this given-value.

Example:

set interfaces ethernet eth0 vif 10 dhcp-options host-name 'VyOS'
set interfaces ethernet <interface> vif <vlan-id> dhcp-options vendor-class-id <vendor-id>

The vendor-class-id option can be used to request a specific class of vendor options from the server.

Example:

set interfaces ethernet eth0 vif 10 dhcp-options vendor-class-id 'VyOS'
set interfaces ethernet <interface> vif <vlan-id> dhcp-options no-default-route

Only request an address from the DHCP server but do not request a default gateway.

Example:

set interfaces ethernet eth0 vif 10 dhcp-options no-default-route
set interfaces ethernet <interface> vif <vlan-id> dhcpv6-options parameters-only

This statement specifies dhcp6c to only exchange informational configuration parameters with servers. A list of DNS server addresses is an example of such parameters. This statement is useful when the client does not need stateful configuration parameters such as IPv6 addresses or prefixes.

set interfaces ethernet eth0 vif 10 dhcpv6-options parameters-only
set interfaces ethernet <interface> vif <vlan-id> dhcpv6-options rapid-commit

When rapid-commit is specified, dhcp6c will include a rapid-commit option in solicit messages and wait for an immediate reply instead of advertisements.

set interfaces ethernet eth0 vif 10 dhcpv6-options rapid-commit
set interfaces ethernet <interface> vif <vlan-id> dhcpv6-options temporary

Request only a temporary address and not form an IA_NA (Identity Association for Non-temporary Addresses) partnership.

set interfaces ethernet eth0 vif 10 dhcpv6-options temporary

DHCPv6 Prefix Delegation (PD)

VyOS 1.3 (equuleus) supports DHCPv6-PD (RFC 3633). DHCPv6 Prefix Delegation is supported by most ISPs who provide native IPv6 for consumers on fixed networks.

set interfaces ethernet <interface> vif <vlan-id> None None dhcpv6-option pd <id> length <length>

Some ISPs by default only delegate a /64 prefix. To request for a specific prefix size use this option to request for a bigger delegation for this pd <id>. This value is in the range from 32 - 64 so you could request up to a /32 prefix (if your ISP allows this) down to a /64 delegation.

The default value corresponds to 64.

To request a /56 prefix from your ISP use:

set interfaces ethernet eth0 vif 10 None None dhcpv6-options pd 0 length 56
set interfaces ethernet <interface> vif <vlan-id> None None dhcpv6-option pd <id> interface <delegatee> address <address>

Specify the interface address used locally on the interfcae where the prefix has been delegated to. ID must be a decimal integer.

It will be combined with the delegated prefix and the sla-id to form a complete interface address. The default is to use the EUI-64 address of the interface.

Example: Delegate a /64 prefix to interface eth8 which will use a local address on this router of <prefix>::ffff, as the address 65534 will correspond to ffff in hexadecimal notation.

set interfaces ethernet eth0 vif 10 None None dhcpv6-option pd 0 interface eth8 address 65534
set interfaces ethernet <interface> vif <vlan-id> None None dhcpv6-option pd <id> interface <delegatee> sla-id <id>

Specify the identifier value of the site-level aggregator (SLA) on the interface. ID must be a decimal number greater then 0 which fits in the length of SLA IDs (see below).

Example: If ID is 1 and the client is delegated an IPv6 prefix 2001:db8:ffff::/48, dhcp6c will combine the two values into a single IPv6 prefix, 2001:db8:ffff:1::/64, and will configure the prefix on the specified interface.

set interfaces ethernet eth0 vif 10 None None dhcpv6-option pd 0 interface eth8 sla-id 1

QinQ (802.1ad)

Call for Contributions

This section needs improvements, examples and explanations.

Please take a look at the Contributing Guide for our Documentation.

IEEE 802.1ad was an Ethernet networking standard informally known as QinQ as an amendment to IEEE standard 802.1q VLAN interfaces as described above. 802.1ad was incorporated into the base 802.1q standard in 2011. The technique is also known as provider bridging, Stacked VLANs, or simply QinQ or Q-in-Q. “Q-in-Q” can for supported devices apply to C-tag stacking on C-tag (Ethernet Type = 0x8100).

The original 802.1q specification allows a single Virtual Local Area Network (VLAN) header to be inserted into an Ethernet frame. QinQ allows multiple VLAN tags to be inserted into a single frame, an essential capability for implementing Metro Ethernet network topologies. Just as QinQ extends 802.1Q, QinQ itself is extended by other Metro Ethernet protocols.

In a multiple VLAN header context, out of convenience the term “VLAN tag” or just “tag” for short is often used in place of “802.1q VLAN header”. QinQ allows multiple VLAN tags in an Ethernet frame; together these tags constitute a tag stack. When used in the context of an Ethernet frame, a QinQ frame is a frame that has 2 VLAN 802.1q headers (double-tagged).

In VyOS the terms vif-s and vif-c stand for the ethertype tags that are used.

The inner tag is the tag which is closest to the payload portion of the frame. It is officially called C-TAG (customer tag, with ethertype 0x8100). The outer tag is the one closer/closest to the Ethernet header, its name is S-TAG (service tag with Ethernet Type = 0x88a8).

set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> address <address | dhcp | dhcpv6>

Configure interface <interface> with one or more interface addresses.

  • address can be specified multiple times as IPv4 and/or IPv6 address, e.g. 192.0.2.1/24 and/or 2001:db8::1/64
  • dhcp interface address is received by DHCP from a DHCP server on this segment.
  • dhcpv6 interface address is received by DHCPv6 from a DHCPv6 server on this segment.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 address 192.0.2.1/24
set interfaces ethernet eth0 vif-s 1000 vif-c 20 address 2001:db8::1/64
set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcp
set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> description <description>

Set a human readable, descriptive alias for this connection. Alias is used by e.g. the show interfaces command or SNMP based monitoring tools.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 description 'This is an awesome interface running on VyOS'
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> disable

Disable given <interface>. It will be placed in administratively down (A/D) state.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 disable
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> disable-link-detect

Use this command to direct an interface to not detect any physical state changes on a link, for example, when the cable is unplugged.

Default is to detects physical link state changes.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 disable-link-detect
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> mac <xx:xx:xx:xx:xx:xx>

Configure user defined MAC address on given <interface>.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 mac '00:01:02:03:04:05'
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> mtu <mtu>

Configure MTU on given <interface>. It is the size (in bytes) of the largest ethernet frame sent on this link.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 mtu 9000
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> ipv6 address autoconf

SLAAC RFC 4862. IPv6 hosts can configure themselves automatically when connected to an IPv6 network using the Neighbor Discovery Protocol via ICMPv6 router discovery messages. When first connected to a network, a host sends a link-local router solicitation multicast request for its configuration parameters; routers respond to such a request with a router advertisement packet that contains Internet Layer configuration parameters.

Note

This method automatically disables IPv6 traffic forwarding on the interface in question.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 ipv6 address autoconf
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> ipv6 address eui64 <prefix>

EUI-64 as specified in RFC 4291 allows a host to assign iteslf a unique 64-Bit IPv6 address.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 ipv6 address eui64 2001:db8:beef::/64
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> vrf <vrf>

Place interface in given VRF instance.

See also

There is an entire chapter about how to configure a VRF, please check this for additional information.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 vrf red

DHCP(v6)

set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcp-options client-id <description>

RFC 2131 states: The client MAY choose to explicitly provide the identifier through the ‘client identifier’ option. If the client supplies a ‘client identifier’, the client MUST use the same ‘client identifier’ in all subsequent messages, and the server MUST use that identifier to identify the client.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcp-options client-id 'foo-bar'
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcp-options host-name <hostname>

Instead of sending the real system hostname to the DHCP server, overwrite the host-name with this given-value.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcp-options host-name 'VyOS'
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcp-options vendor-class-id <vendor-id>

The vendor-class-id option can be used to request a specific class of vendor options from the server.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcp-options vendor-class-id 'VyOS'
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcp-options no-default-route

Only request an address from the DHCP server but do not request a default gateway.

Example:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcp-options no-default-route
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-options parameters-only

This statement specifies dhcp6c to only exchange informational configuration parameters with servers. A list of DNS server addresses is an example of such parameters. This statement is useful when the client does not need stateful configuration parameters such as IPv6 addresses or prefixes.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-options parameters-only
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-options rapid-commit

When rapid-commit is specified, dhcp6c will include a rapid-commit option in solicit messages and wait for an immediate reply instead of advertisements.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-options rapid-commit
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-options temporary

Request only a temporary address and not form an IA_NA (Identity Association for Non-temporary Addresses) partnership.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-options temporary

DHCPv6 Prefix Delegation (PD)

VyOS 1.3 (equuleus) supports DHCPv6-PD (RFC 3633). DHCPv6 Prefix Delegation is supported by most ISPs who provide native IPv6 for consumers on fixed networks.

set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-option pd <id> length <length>

Some ISPs by default only delegate a /64 prefix. To request for a specific prefix size use this option to request for a bigger delegation for this pd <id>. This value is in the range from 32 - 64 so you could request up to a /32 prefix (if your ISP allows this) down to a /64 delegation.

The default value corresponds to 64.

To request a /56 prefix from your ISP use:

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-options pd 0 length 56
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-option pd <id> interface <delegatee> address <address>

Specify the interface address used locally on the interfcae where the prefix has been delegated to. ID must be a decimal integer.

It will be combined with the delegated prefix and the sla-id to form a complete interface address. The default is to use the EUI-64 address of the interface.

Example: Delegate a /64 prefix to interface eth8 which will use a local address on this router of <prefix>::ffff, as the address 65534 will correspond to ffff in hexadecimal notation.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-option pd 0 interface eth8 address 65534
set interfaces ethernet <interface> vif-s <vlan-id> vif-c <vlan-id> dhcpv6-option pd <id> interface <delegatee> sla-id <id>

Specify the identifier value of the site-level aggregator (SLA) on the interface. ID must be a decimal number greater then 0 which fits in the length of SLA IDs (see below).

Example: If ID is 1 and the client is delegated an IPv6 prefix 2001:db8:ffff::/48, dhcp6c will combine the two values into a single IPv6 prefix, 2001:db8:ffff:1::/64, and will configure the prefix on the specified interface.

set interfaces ethernet eth0 vif-s 1000 vif-c 20 dhcpv6-option pd 0 interface eth8 sla-id 1

Operation

show interfaces ethernet

Show brief interface information.

vyos@vyos:~$ show interfaces ethernet
Codes: S - State, L - Link, u - Up, D - Down, A - Admin Down
Interface        IP Address                        S/L  Description
---------        ----------                        ---  -----------
eth0             172.18.201.10/24                  u/u  LAN
eth1             172.18.202.11/24                  u/u  WAN
eth2             -                                 u/D
show interfaces ethernet <interface>

Show detailed information on given <interface>

vyos@vyos:~$ show interfaces ethernet eth0
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 00:50:44:00:f5:c9 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::250:44ff:fe00:f5c9/64 scope link
       valid_lft forever preferred_lft forever

    RX:  bytes    packets     errors    dropped    overrun      mcast
      56735451     179841          0          0          0     142380
    TX:  bytes    packets     errors    dropped    carrier collisions
       5601460      62595          0          0          0          0
show interfaces ethernet <interface> physical

Show information about physical <interface>

vyos@vyos:~$ show interfaces ethernet eth0 physical
Settings for eth0:
        Supported ports: [ TP ]
        Supported link modes:   1000baseT/Full
                                10000baseT/Full
        Supported pause frame use: No
        Supports auto-negotiation: No
        Supported FEC modes: Not reported
        Advertised link modes:  Not reported
        Advertised pause frame use: No
        Advertised auto-negotiation: No
        Advertised FEC modes: Not reported
        Speed: 10000Mb/s
        Duplex: Full
        Port: Twisted Pair
        PHYAD: 0
        Transceiver: internal
        Auto-negotiation: off
        MDI-X: Unknown
        Supports Wake-on: uag
        Wake-on: d
        Link detected: yes
driver: vmxnet3
version: 1.4.16.0-k-NAPI
firmware-version:
expansion-rom-version:
bus-info: 0000:0b:00.0
supports-statistics: yes
supports-test: no
supports-eeprom-access: no
supports-register-dump: yes
supports-priv-flags: no
show interfaces ethernet <interface> physical offload

Show available offloading functions on given <interface>

vyos@vyos:~$ show interfaces ethernet eth0 physical offload
rx-checksumming               on
tx-checksumming               on
tx-checksum-ip-generic        on
scatter-gather                off
tx-scatter-gather             off
tcp-segmentation-offload      off
tx-tcp-segmentation           off
tx-tcp-mangleid-segmentation  off
tx-tcp6-segmentation          off
udp-fragmentation-offload     off
generic-segmentation-offload  off
generic-receive-offload       off
large-receive-offload         off
rx-vlan-offload               on
tx-vlan-offload               on
ntuple-filters                off
receive-hashing               on
tx-gre-segmentation           on
tx-gre-csum-segmentation      on
tx-udp_tnl-segmentation       on
tx-udp_tnl-csum-segmentation  on
tx-gso-partial                on
tx-nocache-copy               off
rx-all                        off
show interfaces ethernet <interface> transceiver

Show transceiver information from plugin modules, e.g SFP+, QSFP

vyos@vyos:~$ show interfaces ethernet eth5 transceiver
   Identifier              : 0x03 (SFP)
   Extended identifier     : 0x04 (GBIC/SFP defined by 2-wire interface ID)
   Connector               : 0x07 (LC)
   Transceiver codes       : 0x00 0x00 0x00 0x01 0x00 0x00 0x00 0x00 0x00
   Transceiver type        : Ethernet: 1000BASE-SX
   Encoding                : 0x01 (8B/10B)
   BR, Nominal             : 1300MBd
   Rate identifier         : 0x00 (unspecified)
   Length (SMF,km)         : 0km
   Length (SMF)            : 0m
   Length (50um)           : 550m
   Length (62.5um)         : 270m
   Length (Copper)         : 0m
   Length (OM3)            : 0m
   Laser wavelength        : 850nm
   Vendor name             : CISCO-FINISAR
   Vendor OUI              : 00:90:65
   Vendor PN               : FTRJ-8519-7D-CS4
   Vendor rev              : A
   Option values           : 0x00 0x1a
   Option                  : RX_LOS implemented
   Option                  : TX_FAULT implemented
   Option                  : TX_DISABLE implemented
   BR margin, max          : 0%
   BR margin, min          : 0%
   Vendor SN               : FNS092xxxxx
   Date code               : 0506xx