# Configuring the Physical Interface

This section describes how to complete the basic configuration for a Fast Ethernet, Gigabit Ethernet, or 10-Gigabit Ethernet interface. CLI examples are provided with the individual command descriptions.

You can configure an Ethernet interface using the following set of tasks:

- Selecting an Ethernet Interface
- Configuring the Line Speed
- Configuring the Duplex Mode
- Specifying the MTU
- Specifying the Duration for Computing Load Statistics
- Adding a Description for the Ethernet Interface
- Validating MAC Addresses Per Interface
- Configuring the Debounce Timer
- Modifying the Debounce Interval

## Selecting an Ethernet Interface

You must select the type of Ethernet interface on a line module by using the interface command to be able to configure the settings for the specific interface.

Interface type selection can be performed using one of the following tasks:

- Selecting a Fast Ethernet Interface
- Selecting a Gigabit Ethernet Interface
- Selecting a 10-Gigabit Ethernet Interface

### Selecting a Fast Ethernet Interface

To select a Fast Ethernet interface on a line module, use the interface fastEthernet command in Global Configuration mode. You can also use it to select a Fast Ethernet management port on an SRP I/O module (ERX7xx models, ERX14xx models, and the ERX310 router) or an SRP IOA (E120 and E320 routers). For information about managing the Fast Ethernet port on the SRP module, see JunosE System Basics Configuration Guide.

| Note: Use the slot/port [.subinterface] format for Fast Ethernet and Gigabit Ethernet interfaces on ERX7xx models, ERX14xx models, and the ERX310 router. Use the slot/adapter/port format for the SRP IOA on the E120 or E320 routers; the port on the SRP IOA is always identified by 0.

- To select a Fast Ethernet interface on ERX7xx models, ERX14xx models, or the ERX310 router:
  host1(config)#interface fastEthernet 1/0
- To select the Fast Ethernet management port on an E120 or E320 router:
  host1(config)#interface fastEthernet 6/0/0

Use the no version to remove IP from an interface or subinterface. You must issue the no version from the highest level down; you cannot remove an interface or subinterface if the one above it still exists.

### Selecting a Gigabit Ethernet Interface

To select a Gigabit Ethernet interface on a line module, use the interface gigabitEthernet command in Global Configuration mode.

| Note: Use the slot/port [.subinterface] format for Fast Ethernet and Gigabit Ethernet interfaces on ERX7xx models, ERX14xx models, and the ERX310 router. Use the slot/adapter/port format for the SRP IOA on the E120 or E320 routers; the port on the SRP IOA is always identified by 0.

| Note: On the GE I/O module, you can configure only the primary port, 0. The router automatically uses the redundant port, 0R, if the primary port fails. On the GE-2 SFP I/O module, you can configure only the primary ports, 0 and 1. The router automatically uses the corresponding redundant port, 0R or 1R, if the primary port fails. On the OC3-2 GE APS I/O module, you can configure only port 2. Ports 0 and 1 are reserved for OC3/STM1 ATM interfaces. This I/O module does not support redundant ports in the current release. On the ES2-S1 GE-4 IOA, you can configure all four ports. On the ES2-S1 GE-8 IOA, you can configure all eight ports.

- To select a Gigabit Ethernet interface on ERX7xx models, ERX14xx models, and the ERX310 router:
  host1(config)#interface gigabitEthernet 1/0 host1(config)#interface gigabitEthernet 2/1
- To select a Gigabit Ethernet interface on an E120 or E320 router:
  host1(config)#interface gigabitEthernet 4/0/1

Use the no version to remove IP from an interface or subinterface. You must issue the no version from the highest level down; you cannot remove an interface or subinterface if the one above it still exists.

### Selecting a 10-Gigabit Ethernet Interface

To select a 10-Gigabit Ethernet interface on the E120 or E320 router, use the interface tengigabitEthernet command in Global Configuration mode.

| Note: Use the slot/adapter/port format for the SRP IOA on the E120 or E320 routers; the port on the SRP IOA is always identified by 0.

| Note: On the ES2-S2 10GE PR IOA, you can configure only the primary port, 0. The router automatically uses the redundant port, 0R, if the primary port fails.

To select a 10-Gigabit Ethernet interface on the ES2-S1 10GE IOA:

host1(config)#interface tenGigabitEthernet 4/0/0

Use the no version to remove IP from an interface. You must issue the no version from the highest level down; you cannot remove an interface or subinterface if the one above it still exists.

## Configuring the Line Speed

You can specify the line speed for Ethernet interfaces by using the speed command. This command works with the duplex command.

To specify the line speed:

- Issue the speed command in Interface Configuration mode.
  host1(config-if)#speed 10

  Use the no version to revert to the default, either automatically negotiate or 100 Mbps (FE-8 SFP I/O module only).

This command also works on the Fast Ethernet port on the SRP module on all E Series routers. For more information, see JunosE System Basics Configuration Guide.

| Note: If you set either the line speed or duplex mode to automatically negotiate by using the automatically negotiate keyword, the router negotiates both parameters. You can specify different values to prevent the router from negotiating these parameters. Automatic negotiation is not supported for the FE-8 SFP I/O module. For this I/O module, the default speed is 100 Mbps.

## Configuring the Duplex Mode

You can specify the duplex mode by using the duplex command. This command works with the speed command.

To specify the duplex mode:

- Issue the duplex command in Interface Configuration mode.
  host1(config-if)#duplex full

  Use the no version to revert to the default, either automatically negotiate or full duplex (FE-8 SFP I/O module only).

This command also works on the Fast Ethernet port on the SRP module on all E Series routers. For more information, see JunosE System Basics Configuration Guide.

| Note: If you set either the line speed or duplex mode to automatically negotiate by using the automatically negotiate keyword, the router negotiates both parameters. You can specify different values to prevent the router from negotiating these parameters. Automatic negotiation is not supported for the FE-8 SFP I/O module. For this I/O module, full duplex mode is the default.

## Specifying the MTU

You can specify the MTU for an interface by using the mtu command.

To specify the maximum allowable size in bytes of the maximum transmission unit for interfaces on Ethernet modules:

- Issue the mtu command in Interface Configuration mode by entering a value in the range 64–9188 bytes.
  host1(config-if)#mtu 9000

  The range for FE-8 I/O modules is 64–9042 bytes. This command does not work for the Fast Ethernet port on the SRP module. Use the no version to specify the default, 1518.

## Specifying the Duration for Computing Load Statistics

You can set the time interval at which the router calculates bit and packet rate counters by using the load-interval command.

To set the time interval at which the router calculates bit and packet rate counters:

- Issue the load-interval command in Interface Configuration mode by specifying a multiple of 30 seconds, in the range 30–300 seconds.
  host1(config-if)#load-interval 90

  Use the no version to restore the default time interval, 300 seconds.

This command does not work for the Fast Ethernet port on the SRP module.

## Adding a Description for the Ethernet Interface

To associate a text description of up to 64 characters with an Ethernet interface:

- Issue the ethernet description command in Interface Configuration mode for non-SRP Fast Ethernet or Gigabit Ethernet interfaces.
  host1(config-if)#ethernet description abcd1234

  This command does not work for the Fast Ethernet port on the SRP module. The description is displayed in the output for show configuration, show interfaces fastEthernet, show interfaces gigabitEthernet, and show interfaces tenGigabitEthernet commands. Use the no version to remove the description from the interface.

## Validating MAC Addresses Per Interface

When MAC address validation is enabled, the router checks the entry in the MAC validation table that corresponds to the IP source address of an incoming packet. The MAC source address of the packet must match the MAC source address of the table entry for the router to forward the packet.

To enable or disable MAC address validation on a per interface basis:

1. From Global Configuration mode, specify the interface on which you want to configure MAC address validation.
   host1(config)#interface gigabitEthernet 2/0
2. Assign an IP address and subnet mask for the interface.
   host1(config-if)#ip address 4.4.4.2 255.255.255.0
3. Specify the type of MAC address validation on the interface:
   - Use the strict keyword to prevent transmission of IP packets that do not reside in the validation table.
   - Use the loose keyword to enable IP packets to pass through even though the packets do not have entries in the validation table. Only packets that have matching IP–MAC pair entries in the table are validated.
   host1(config-if)#ip mac-validate strict

   Use the no version of this command to restore the default behavior, which is not to perform MAC address validation.

4. Exit the Interface Configuration mode.
   host1(config-if)#exit

| Note: For additional information about MAC address validation, see the arp validate command description in JunosE IP, IPv6, and IGP Configuration Guide.

## Configuring the Debounce Timer

You can enable the debounce configuration and set the interval, in seconds, for which an interface must maintain a given state—for example, up or down—before the interface reports the state change to the upper-layer protocols.

| Note: Debounce configuration is supported for all Ethernet module combinations on E Series routers.

When a link briefly goes up or down, the momentary loss of signal can cause a temporary service interrution for connection-oriented protocols such as PPPoE. Configuring the debounce interval prevents the router from prematurely tearing down and rebuilding the PPPoE connections during such brief network outages. Specify the interval, in seconds, for which an interface must maintain a given state before the state change is reported to the upper-layer links. The range is 1–5 seconds and the default interval is 1 second.

Observe the following guidelines when you configure the debounce feature for Ethernet interfaces:

- In networks where a link alternates between the up and down state for brief periods, we recommend that you set a longer debounce interval to prevent the router from prematurely and unnecessarily tearing down and rebuilding the PPPoE connections during brief network outages.
- In networks where the interface changes to a down state and remains in the down state for long periods of time, we recommend that you set a shorter debounce interval to minimize the latency (delay) required for the interface to notify the upper-layer protocols of the state change. When you set a longer debounce interval, the latency increases.
- We recommend that you disable the debounce feature in networks that require faster link status notifications to upper links.
- The debounce feature is not supported for Ethernet interfaces on which either IEEE 802.3ad link aggregation is configured.

The setting of the debounce command persists after you reboot the router.

To enable the debounce timer feature and configure an interval for which an interface in a certain state waits before notifying the state change to upper-layer protocols:

- Issue the debounce command in Interface Configuration mode.
  host1(config-if)#debounce 3

  Use the no version to restore the default behavior, which disables debounce on the interface.

## Modifying the Debounce Interval

You can modify the minimum time an Ethernet interface must maintain a given state—for example, up or down—before the interface notifies the upper-layer protocols of the state change. The interval can be in the range 1–5 seconds.

| Note: Debounce configuration is supported for all Ethernet module combinations on E Series routers.

You can configure this command only if you have enabled the debounce timer feature using the debounce command. After you enable this feature, you can use the debounce-interval command to modify the debounce interval. The setting of the debounce-interval command persists after you reboot the router.

To modify the debounce interval for a particular interface on which you have previously enabled the debounce timer feature:

- Issue the debounce-interval command in Interface Configuration mode.
  host1(config-if)#debounce-interval 4

  Use the no version to restore the default value, 1 second.

#### Related Documentation

- Managing Port Redundancy on Gigabit Ethernet I/O Modules
- Configuring Ethernet Interfaces
- Disabling Ethernet Interfaces
- Monitoring the Status of Fast Ethernet Interfaces
- Monitoring the Status of Gigabit Ethernet and 10-Gigabit Ethernet Interfaces
- Monitoring the Status of MAC Address Validation on Physical Interfaces
- debounce
- debounce-interval
- duplex
- ethernet description
- interface fastEthernet
- interface gigabitEthernet
- interface tenGigabitEthernet
- ip mac-validate
- load-interval
- mtu
- speed