EN ESTA PÁGINA
Ejemplo: configuración del encadenamiento de servicios para el enrutamiento LAN-WAN
En este ejemplo, se muestra cómo configurar el encadenamiento de servicios para el enrutamiento de LAN-WAN.
Requisitos
En este ejemplo se utilizan los siguientes componentes de hardware y software:
NFX150 con Junos OS versión 18.1R1
Visión general
En este ejemplo se explica cómo configurar las distintas capas del dispositivo para permitir que el tráfico de la red LAN entre en el dispositivo, fluya a través del OVS, salga del dispositivo y entre en la red WAN.
Topología
En este ejemplo se usa la topología que se muestra en la figura 1.

Configuración
Asignar las interfaces
Procedimiento paso a paso
Asigne el puerto físico heth-0-0 a la interfaz FPC0.
user@host# set vmhost virtualization-options interfaces ge-0/0/0 mapping interface heth-0-0
Asigne la interfaz FPC1 ge-1/0/2 al puerto físico heth-0-4.
user@host# set vmhost virtualization-options interfaces ge-1/0/2 mapping interface heth-0-4
Configurar la ruta de datos de capa 2
Procedimiento paso a paso
Configure VLAN para las interfaces del lado LAN.
user@host# set vlans vlan100 vlan-id 100
Configure los puertos del panel frontal de la LAN y agréguelos a la VLAN del lado de la LAN.
user@host# set interfaces ge-0/0/0 unit 0 family ethernet-switching interface-mode trunk user@host# set interfaces ge-0/0/0 unit 0 family ethernet-switching vlan members vlan100
Configure las interfaces internas como puertos troncales y agréguelas a la VLAN del lado LAN. Las interfaces internas suelen ser puertos troncales, ya que deben admitir el tráfico de varios puertos del panel frontal y VLAN.
user@host# set interfaces sxe-0/0/0 unit 0 family ethernet-switching interface-mode trunk user@host# set interfaces sxe-0/0/0 unit 0 family ethernet-switching vlan members vlan100
Configurar la ruta de datos de capa 3
Procedimiento paso a paso
Configure el etiquetado VLAN en ge-1/0/0:
user@host# set interfaces ge-1/0/0 vlan-tagging user@host# set interfaces ge-1/0/0 unit 0 vlan-id 100 user@host# set interfaces ge-1/0/0 unit 0 family inet address 192.0.3.1/24
Configure el etiquetado VLAN en ge-1/0/2:
user@host# set interfaces ge-1/0/2 vlan-tagging user@host# set interfaces ge-1/0/2 unit 0 vlan-id 200 user@host# set interfaces ge-1/0/2 unit 0 family inet address 203.0.113.2/30
Verificación
Comprobación del estado de las interfaces
Propósito
Verifique el estado de las interfaces de capa 2 y capa 3.
Acción
Para verificar el estado de las interfaces:
Compruebe el estado de los puertos físicos.
user@host> show interfaces heth-0-0 statistics Physical interface: heth-0-0, Enabled, Physical link is Up Link-level type: Ethernet, Media type: Copper, MTU: 9192, Speed: 1Gbps, Duplex: Full-duplex, Auto-negotiation: Enabled Device flags : Present Running Current address: 00:00:5e:00:53:8d, Hardware address: 00:00:5e:00:53:8d Input packets : 272469 Output packets: 674 MAC statistics: Input bytes: 17438016, Input packets: 272469, Output bytes: 48658, Output packets: 674 VF statistics: VF Number: 0, PCI Address: 0000:02:10:1, Mapped to: ge-0/0/0 Input bytes: 17433984, Input packets: 272406, Output bytes: 48658, Output packets: 674, Multicast packets: 272406 VF Number: 1, PCI Address: 0000:02:10:5, Mapped to: ge-0/0/0 Input bytes: 0, Input packets: 0, Output bytes: 0, Output packets: 0, Multicast packets: 0 VF Number: 2, PCI Address: 0000:02:11:1, Mapped to: ge-0/0/0 Input bytes: 0, Input packets: 0, Output bytes: 0, Output packets: 0, Multicast packets: 0 VF Number: 3, PCI Address: 0000:02:11:5, Mapped to: ge-0/0/0 Input bytes: 0, Input packets: 0, Output bytes: 0, Output packets: 0, Multicast packets: 0
Verifique el estado de las interfaces de capa 2 (ge-0/0/x) y capa 3 (ge-1/0/x).
user@host > show interfaces interface-name statistics
Por ejemplo:
user@host > show interfaces ge-0/0/0 statistics Physical interface: ge-0/0/0, Enabled, Physical link is Up Interface index: 144, SNMP ifIndex: 518 Link-level type: Ethernet, MTU: 9192, LAN-PHY mode, Speed: 1000mbps, BPDU Error: None, Loop Detect PDU Error: None, Ethernet-Switching Error: None, MAC-REWRITE Error: None, Loopback: Disabled, Source filtering: Disabled, Flow control: Enabled Device flags : Present Running Interface flags: SNMP-Traps Internal: 0x4000 Link flags : None CoS queues : 8 supported, 8 maximum usable queues Current address: 00:00:5e:00:53:43, Hardware address: 00:00:5e:00:53:43 Last flapped : 2018-04-18 05:38:22 UTC (2d 10:07 ago) Statistics last cleared: Never Input rate : 0 bps (0 pps) Output rate : 0 bps (0 pps) Input errors: 0, Output errors: 0 Active alarms : None Active defects : None PCS statistics Seconds Bit errors 0 Errored blocks 0 Ethernet FEC statistics Errors FEC Corrected Errors 0 FEC Uncorrected Errors 0 FEC Corrected Errors Rate 0 FEC Uncorrected Errors Rate 0 PRBS Statistics : Disabled Interface transmit statistics: Disabled Logical interface ge-0/0/0.0 (Index 333) (SNMP ifIndex 524) Flags: Up SNMP-Traps 0x24024000 Encapsulation: Ethernet-Bridge Input packets : 147888 Output packets: 22 Protocol eth-switch, MTU: 9192 Flags: Is-Primary