EIGRP - Filtering - Prefix List - In
Filtering menggunakan prefix list dipilih bila kita ingin memfilter berdasarkan
netmasknya, misal network pada R3 dengan prefix /24 - /28 akan diblok, selain
itu akan ditampilkan.
sebelumnya rubah dulu network EIGRP di semua router, rubah menjadi network
0.0.0.0/0, hal ini bermaksud agar berapapun IP Address yang di tanam di Router
maka akan di advertise semuanya ke EIGRP
R1 sampai R3 Konfigurasinya :
router eigrp 1
network 0.0.0.0
!
Kemudian bikin IP Loopback di R3 dengan beberapa netmask yang variatif
di R3
interface Loopback0
ip address 3.3.3.3 255.255.255.255
!
interface Loopback1
ip address 3.3.3.17 255.255.255.240
!
interface Loopback2
ip address 3.3.3.33 255.255.255.248
!
interface Loopback3
ip address 3.3.3.100 255.255.255.224
!
interface Loopback4
ip address 3.3.3.150 255.255.255.252
!
interface Loopback5
ip address 3.3.3.200 255.255.255.240
!
Kemudian konfigurasi prefix list di R2
R2(config)#ip prefix-list EIGRP_IN seq 10 deny 3.3.3.0/24 le 28
R2(config)#ip prefix-list EIGRP_IN seq 20 permit 0.0.0.0/0 le 32
deny = tidak diperbolehkan
permit = di bolehkan
ge = Minimum prefix length to be matched
le = Maximum prefix length to be matched
Distribut ke EIGRP di R2
R2(config)#router eigrp 1
R2(config-router)#distribute-list prefix EIGRP_IN in
Verifikasi di R2
R2(config-router)#do sh ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
a - application route
+ - replicated route, % - next hop override
Gateway of last resort is not set
1.0.0.0/32 is subnetted, 1 subnets
D 1.1.1.1 [90/2297856] via 12.12.12.1, 00:15:26, Serial2/0
2.0.0.0/32 is subnetted, 1 subnets
C 2.2.2.2 is directly connected, Loopback0
3.0.0.0/8 is variably subnetted, 3 subnets, 3 masks
D 3.3.3.3/32 [90/409600] via 23.23.23.3, 00:15:34, Ethernet0/0
D 3.3.3.32/29 [90/409600] via 23.23.23.3, 00:12:58, Ethernet0/0
D 3.3.3.148/30 [90/409600] via 23.23.23.3, 00:09:42, Ethernet0/0
12.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 12.12.12.0/24 is directly connected, Serial2/0
L 12.12.12.2/32 is directly connected, Serial2/0
23.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 23.23.23.0/24 is directly connected, Ethernet0/0
L 23.23.23.2/32 is directly connected, Ethernet0/0
Terlihat di Routing table R2 bahwa IP Loopback /24 - /28 milik R3 tidak muncul
hal ini karena kita sudah mengkonfigurasi semua network 3.3.3.0/24 - /28
tidak diperbolehkan / di deny
EIGRP Filtering - Prefix List - Out
Direction prefix list selain pada input juga bisa diterapkan pada output
hapus dulu konfigurasi EIGRP prefix list di R2
kemudian bikin access list dan distribute ke EIGRP di R3 dengan mengubah
directionnya menjadi out
bikin prefix di R3
R3(config)#ip prefix-list EIGRP_OUT seq 10 deny 3.3.3.0/24 ge 28 le 32
R3(config)#ip prefix-list EIGRP_OUT seq 20 permit 0.0.0.0/0 le 32
distribute ke EIGRP
R3(config)#router eigrp 1
R3(config-router)#distribute-list prefix EIGRP_OUT out
Verifikasi di R1
R1#sh ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2
i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2
ia - IS-IS inter area, * - candidate default, U - per-user static route
o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP
a - application route
+ - replicated route, % - next hop override
Gateway of last resort is not set
1.0.0.0/32 is subnetted, 1 subnets
C 1.1.1.1 is directly connected, Loopback0
2.0.0.0/32 is subnetted, 1 subnets
D 2.2.2.2 [90/2297856] via 12.12.12.2, 00:37:00, Serial2/0
3.0.0.0/27 is subnetted, 1 subnets
D 3.3.3.96 [90/2323456] via 12.12.12.2, 00:05:00, Serial2/0
12.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 12.12.12.0/24 is directly connected, Serial2/0
L 12.12.12.1/32 is directly connected, Serial2/0
23.0.0.0/24 is subnetted, 1 subnets
D 23.23.23.0 [90/2195456] via 12.12.12.2, 00:37:00, Serial2/0
R1#
Mantab yang muncul hanya prefix 3.0.0.0/27 saja yang lainya tidak diperbolehkan
oleh R3
Sampai sini selesei
Salam Ngoprek