background image

 

12 

Configuring loopback and null interfaces  

This chapter describes how to configure a loopback interface and a null interface.  

Configuring a loopback interface 

A loopback interface is a virtual interface. The physical layer state and link layer protocols of a loopback 
interface are always up unless the loopback interface is manually shut down. Because of this benefit, 

loopback interfaces are widely used in the following scenarios: 

 

Configuring a loopback interface address as the source address of the IP packets that the device 
generates

—Because loopback interface addresses are stable unicast addresses, they are usually 

used as device identifications. When you configure a rule on an authentication or security server to 

permit or deny packets that a device generates, you can simplify the rule by configuring it to permit 
or deny packets carrying the loopback interface address that identifies the device. When you use 

a loopback interface address as the source address of IP packets, make sure the route from the 

loopback interface to the peer is reachable by performing routing configuration. All data packets 

sent to the loopback interface are considered packets sent to the device itself, so the device does not 
forward these packets. 

 

Using a loopback interface in dynamic routing protocols

—With no router ID configured for a 

dynamic routing protocol, the system selects highest loopback interface IP address selected as the 

router ID. In BGP, to avoid interruption of BGP sessions due to physical port failure, you can use a 

loopback interface as the source interface of BGP packets.  

To configure a loopback interface: 

 

Step Command 

Remarks 

1.

 

Enter system view. 

system-view 

N/A 

2.

 

Create a loopback interface 
and enter loopback interface 

view. 

interface loopback

 

interface-number

 

N/A 

3.

 

Set the interface description. 

description 

text

 

The default setting is 

interface name

 

Interface

 (for example, 

LoopBack1 

Interface

). 

4.

 

Restore the default settings for 

the loopback interface. 

default 

N/A 

5.

 

Bring up the loopback 
interface. 

undo shutdown 

By default, a loopback interface is up. 

 

Configuring a null interface   

A null interface is a virtual interface and is always up, but you can neither use it to forward data packets 
nor can you configure it with an IP address or link layer protocol. The null interface provides a simpler 

way to filter packets than ACL. You can filter undesired traffic by transmitting it to a null interface instead 

of applying an ACL. For example, if you specify a null interface as the next hop of a static route to a 

specific network segment, any packets routed to the network segment are dropped. 

Summary of Contents for S12500 Series

Page 1: ...H3C S12500 Series Routing Switches Interface Configuration Guide Hangzhou H3C Technologies Co Ltd http www h3c com Software version S12500 CMW710 R7128 Document version 6W710 20121130...

Page 2: ...ware Secware Storware NQA VVG V2 G Vn G PSPT XGbus N Bus TiGem InnoVision and HUASAN are trademarks of Hangzhou H3C Technologies Co Ltd All other trademarks that may be mentioned in this manual are th...

Page 3: ...onventions This section describes the conventions used in this documentation set Command conventions Convention Description Boldface Bold text represents commands and keywords that you enter literally...

Page 4: ...formation NOTE An alert that contains additional or supplementary information TIP An alert that provides helpful information Network topology icons Represents a generic network device such as a router...

Page 5: ...software features and configuration procedures Command references Provide a quick reference to all available commands Operations and maintenance System log messages Explains the system log messages Tr...

Page 6: ...http www h3c com Documentation feedback You can e mail your comments about product documentation to info h3c com We appreciate your comments...

Page 7: ...et interface 6 Setting the statistics polling interval 6 Configuring a Layer 2 Ethernet interface 7 Configuring storm suppression 7 Forcibly bringing up a fiber GE or 10 GE port 8 Setting the MDIX mod...

Page 8: ...rnet subinterface By creating subinterfaces on a Layer 3 Ethernet interface you enable the interface to carry packets for multiple VLANs Configuring common Ethernet interface settings IMPORTANT By def...

Page 9: ...ccess point identifier The sending end keeps the connection with the receiving end by sending this byte repeatedly The Path Trace byte J1 a byte in the High Order Path Overhead usually serves as a hig...

Page 10: ...down Configuring an Ethernet subinterface Step Command Remarks 1 Enter system view system view N A 2 Create an Ethernet subinterface interface interface type interface number subnumber N A 3 Set the i...

Page 11: ...nterface type interface number N A 3 Configure jumbo frame support jumboframe enable value By default the device allows jumbo frames within 9216 bytes to pass through On LST1XP16LEB1 and LST1XP16LEC1...

Page 12: ...With this command configured when the interface comes down or goes up the link updown event is not reported to the CPU until the interface is still down or up when the suppression interval delay time...

Page 13: ...drops on a link you can enable generic flow control at both ends of the link When traffic congestion occurs at the receiving end the receiving end sends a flow control Pause frame to ask the sending...

Page 14: ...one of the kbps and pps keywords To switch between the kbps and pps keywords you must first restore the broadcast multicast or unknown unicast suppression threshold to the default On an interface only...

Page 15: ...able a fiber port to forward traffic over a single link you can use the port up mode command This command brings up a fiber port by force even when no fiber links or optical modules are present If one...

Page 16: ...s each of which plays a dedicated role For example pins 1 and 2 transmit signals and pins 3 and 6 receive signals You can use both crossover and straight through Ethernet cables to connect copper Ethe...

Page 17: ...efault setting is 1500 bytes Displaying and maintaining an Ethernet interface or subinterface Execute display commands in any view and reset commands in user view Task Command Display interface traffi...

Page 18: ...r subinterface statistics reset counters interface interface type interface number interface number subnumber Clear the statistics of dropped packets on the specified interfaces reset packet drop inte...

Page 19: ...evice does not forward these packets Using a loopback interface in dynamic routing protocols With no router ID configured for a dynamic routing protocol the system selects highest loopback interface I...

Page 20: ...rface 4 Restore the default settings for the null interface default N A Displaying and maintaining loopback and null interfaces Execute display commands in any view and reset commands in user view Tas...

Page 21: ...aggregate interface and its member interfaces can break up the aggregation No limit is set on the maximum number of interfaces in an interface range The more interfaces in an interface range the longe...

Page 22: ...15 Step Command Remarks 5 Optional Verify the configuration display this N A...

Page 23: ...Layer 3 Ethernet interface or subinterface 61H10 Configuring a loopback interface 62H12 Configuring a null interface 63H12 Configuring common Ethernet interface settings 64H1 D Displaying and maintai...

Reviews: