Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

Unable to create interface null0

Hey guys,

I keep getting the

% route-map:can not set interface.

% Use P2P interfaces for set interface clause

every time I try to set ("set interface null0") a null interface inside a route map.

Has anyone seen this?

My route map is:

route-map MY-LOCAL-POLICY permit 10

match ip address 150

set ip next-hop

In this route map, I want to add the set interca null0 command but it gives me those errors messages.


Hall of Fame Super Gold

Re: Unable to create interface null0

Hi, why do you want to use null0 in route-map ? Null0 can be used only for certain purposes, eg permanent static routes for bgp, or packet discard.

Re: Unable to create interface null0

HI, [Pls Rate if HELPS]

If your requirement is to block certain IP @ Address: The below is the Example Config:

Create an ACL:

R2(config)#access-list 30 permit host

R2(config)#access-list 31 permit host

Perhaps if you want to specifically block traffic sourced from or You can use multiple match statements in one single route map, and have packets matching those two addresses sent to the bit bucket - the interface null0.

R2(config)#route-map EXAMPLE permit 30

R2(config-route-map)#match ip address 31

R2(config-route-map)#match ip address 32

R2(config-route-map)#set interface null0

Any traffic matching ACLs 31 or 32 will be sent to null0, resulting in its being discarded by the router. Any traffic that didn't match any of the route map statements will be returned to the routing engine for normal processing.

Hope I am Informative.


Best Regards,

Guru Prasad R

Hall of Fame Super Silver

Re: Unable to create interface null0


if you want traffic matching the access-list 150 to be sent to null0 why you want also to set an ip next-hop at the same time ?

I guess that if you remote the set ip next-hop you will be able to use the set interface null0 in this route-map clause.

there is no sense in setting an ip next hop if you want to discard traffic.

Of course I may be wrong, but experience says that it is not possible to use any combination of commands inside a route-map.

In this case if you set a next hop the IOS code treats the outgoing interface as multiaccess and does not allow you to use set interface that can be used for serial point-to-point interface only.

null0 is a logic interface for a waste bin.

hope to help

best regards