neighbor (RIP)

Configures RIP neighbor filter to specify RIP routes to be learned and advertised.
Syntax
neighbor filter-num { permit | deny } { any | ip-address }
no neighbor filter-num { permit | deny } { any | ip-address }
Command Default

Initially, by default, the device learns all RIP routes from all neighbors and advertises all routes to all neighbors. Once you have defined a filter that permits learning from a RIP neighbor, the default changes so that the device denies all other RIP neighbors except those specified.

Parameters
filter-num
Filter index number, a decimal value from 1 through 64.
permit
Allows routes to be learned and advertised for designated IP address or for any IP address, depending on configuration.
deny
Prevents routes from being learned or advertised for designated IP address or for any IP address, depending on configuration.
any
Indicates configured action is to be applied to all IP addresses.
ip-address
Specifies an IP address to which the filter applies.
Modes

RIP router configuration mode

Usage Guidelines

The no form of the command deactivates the filter.

You may require more than one filter to obtain the results you want. For example, if you create a filter to allow or deny a specific IP address, you must create additional filters to allow route learning and advertisement for any other IP addresses.

To avoid conflicting actions, give the filter with the highest priority the highest filter number. Typically, you would add the priority filter last. For example, If you want to deny only one IP address, you must create a second filter with a higher number (priority) to allow any others.

Examples

The following example configures the RIP router so that no RIP routes are learned or advertised for any neighbor.

device# configure terminal
device(config)# router rip
device(config-rip-router)# neighbor 1 deny any

The following example configures the RIP router to learn and advertise routes for all neighbors except neighboring IP address 10.70.12.104. Note the second filter is required and must have a higher filter number.

device# configure terminal
device(config)# router rip
device(config-rip-router)# neighbor 2 deny 10.70.12.104
device(config-rip-router)# neighbor 64 permit any