1 00:00:00,000 --> 00:00:03,304 [AUDIO LOGO] 2 00:00:03,304 --> 00:00:08,029 3 00:00:08,029 --> 00:00:12,110 We know that MPLS creates a label for every route 4 00:00:12,110 --> 00:00:13,550 in the routing table. 5 00:00:13,550 --> 00:00:16,020 That doesn't necessarily mean, however, 6 00:00:16,020 --> 00:00:18,620 that we want to advertise those labels 7 00:00:18,620 --> 00:00:20,880 to every one of our peers. 8 00:00:20,880 --> 00:00:23,600 So what we have is a way that we can limit 9 00:00:23,600 --> 00:00:28,050 or filter which labels are sent to which peers. 10 00:00:28,050 --> 00:00:30,630 This is a relatively easy process. 11 00:00:30,630 --> 00:00:33,650 However, there are some rather unique rules 12 00:00:33,650 --> 00:00:36,450 that we want to look at before we just jump into this. 13 00:00:36,450 --> 00:00:39,025 So that's actually what we're going to do first. 14 00:00:39,025 --> 00:00:41,150 Then, of course, we'll take a look at our topology, 15 00:00:41,150 --> 00:00:42,733 just to see what we're going to build, 16 00:00:42,733 --> 00:00:46,230 and jump into the command line and make this happen. 17 00:00:46,230 --> 00:00:49,100 But on the other side, there's also-- 18 00:00:49,100 --> 00:00:52,430 we may not want to receive all labels. 19 00:00:52,430 --> 00:00:54,530 That's a much easier process. 20 00:00:54,530 --> 00:00:56,640 We don't have to worry about a bunch of rules, 21 00:00:56,640 --> 00:00:57,950 it's just the filter. 22 00:00:57,950 --> 00:01:00,240 But we're going to be taking a look at that as well. 23 00:01:00,240 --> 00:01:02,921 So again, let's go ahead and jump into that topology, 24 00:01:02,921 --> 00:01:05,129 take a look at what we're going to build and look at, 25 00:01:05,129 --> 00:01:09,640 and then, of course, get this up and operational. 26 00:01:09,640 --> 00:01:12,270 So let's begin by looking at these filtering 27 00:01:12,270 --> 00:01:16,360 rules around our conditional label advertisement. 28 00:01:16,360 --> 00:01:19,650 So the first rule is, if there is 29 00:01:19,650 --> 00:01:24,090 no ACL about a particular label, that label is 30 00:01:24,090 --> 00:01:26,340 going to be sent to everyone. 31 00:01:26,340 --> 00:01:29,790 And you could argue that this is the default condition. 32 00:01:29,790 --> 00:01:32,280 There is no ACL about any labels. 33 00:01:32,280 --> 00:01:35,470 And therefore, those labels are sent to everyone. 34 00:01:35,470 --> 00:01:37,380 But what we mean here is that if we 35 00:01:37,380 --> 00:01:39,930 don't create an ACL about a particular label, 36 00:01:39,930 --> 00:01:42,540 then anything else we do is not going to affect 37 00:01:42,540 --> 00:01:44,580 that particular label. 38 00:01:44,580 --> 00:01:50,760 The next rule is, if there is an ACL about a label, 39 00:01:50,760 --> 00:01:54,240 then that label will be sent only 40 00:01:54,240 --> 00:01:56,160 to the configured neighbors. 41 00:01:56,160 --> 00:01:58,410 In other words, it will stop being 42 00:01:58,410 --> 00:02:01,980 advertised to the neighbors that are not listed. 43 00:02:01,980 --> 00:02:05,430 Another rather interesting rule is these ACLs 44 00:02:05,430 --> 00:02:10,630 that we create can only be applied to one neighbor. 45 00:02:10,630 --> 00:02:12,930 So in that ACL, you're going to have 46 00:02:12,930 --> 00:02:16,860 to list all of the prefixes that you want labels advertised 47 00:02:16,860 --> 00:02:19,420 to that particular neighbor. 48 00:02:19,420 --> 00:02:22,740 And again, this is related to the first rule, 49 00:02:22,740 --> 00:02:26,400 but it's saying that if there is an ACL 50 00:02:26,400 --> 00:02:30,930 to a particular neighbor, but a particular label is not 51 00:02:30,930 --> 00:02:33,930 addressed, it will still be sent. 52 00:02:33,930 --> 00:02:36,570 Like I said, closely related to the first rule, 53 00:02:36,570 --> 00:02:38,070 but it's just a little bit different 54 00:02:38,070 --> 00:02:41,190 because, in this case, there actually is an ACL. 55 00:02:41,190 --> 00:02:44,620 It's just not addressing that particular label. 56 00:02:44,620 --> 00:02:48,480 And then, the last one here isn't necessarily a rule, 57 00:02:48,480 --> 00:02:51,300 but a modification of the rules. 58 00:02:51,300 --> 00:02:56,010 We can actually turn off all label distribution 59 00:02:56,010 --> 00:03:00,810 and only send things if they are explicitly allowed, 60 00:03:00,810 --> 00:03:04,200 which would effectively kill the first rule here. 61 00:03:04,200 --> 00:03:07,140 We're saying, no, no, no, we don't send labels to anybody, 62 00:03:07,140 --> 00:03:11,100 unless we have an ACL saying that we should. 63 00:03:11,100 --> 00:03:12,900 If you want to look at it this way, 64 00:03:12,900 --> 00:03:16,800 the default behavior is pretty much a permit all. 65 00:03:16,800 --> 00:03:18,840 We send labels to everybody. 66 00:03:18,840 --> 00:03:20,790 And then, we implement our filters 67 00:03:20,790 --> 00:03:23,100 to say where we don't want them sent. 68 00:03:23,100 --> 00:03:24,690 But with this bottom choice, we're 69 00:03:24,690 --> 00:03:27,030 changing that to a default deny. 70 00:03:27,030 --> 00:03:31,950 We don't send labels to anybody, unless our ACLs say we should. 71 00:03:31,950 --> 00:03:34,670 So let's go ahead and jump into our topology diagram, 72 00:03:34,670 --> 00:03:37,170 take a look at where we're going to implement this, and then 73 00:03:37,170 --> 00:03:41,220 let's jump into that command line and get this working. 74 00:03:41,220 --> 00:03:43,660 Now, the way we have this configured right now, 75 00:03:43,660 --> 00:03:47,580 particularly since we're doing prefix suppression on all 76 00:03:47,580 --> 00:03:49,860 of the transit networks, we're really 77 00:03:49,860 --> 00:03:53,070 not generating and sending labels for any prefixes 78 00:03:53,070 --> 00:03:54,280 that we don't need. 79 00:03:54,280 --> 00:03:58,300 So we've already optimized our network here. 80 00:03:58,300 --> 00:04:00,510 So that means we can really filter anything 81 00:04:00,510 --> 00:04:01,963 without breaking something. 82 00:04:01,963 --> 00:04:03,630 So what we're going to do is, we're just 83 00:04:03,630 --> 00:04:07,260 going to create a new loopback interface on router 2, 84 00:04:07,260 --> 00:04:10,530 just so we can filter out its label and see how all of this 85 00:04:10,530 --> 00:04:11,200 works. 86 00:04:11,200 --> 00:04:13,390 So let's go ahead and jump into the command line. 87 00:04:13,390 --> 00:04:15,180 Of course, we'll be starting on router 2, 88 00:04:15,180 --> 00:04:18,412 creating that loopback. 89 00:04:18,412 --> 00:04:20,079 So what we're going to do is just create 90 00:04:20,079 --> 00:04:23,140 an interface loopback 22 here. 91 00:04:23,140 --> 00:04:26,770 We'll give it an IP address, and we'll just make it a /32 92 00:04:26,770 --> 00:04:30,290 address of all 22s. 93 00:04:30,290 --> 00:04:35,330 We'll go into router OSPF 1 into area zero, 94 00:04:35,330 --> 00:04:39,560 and we'll bring interface loopback 22 into OSPF. 95 00:04:39,560 --> 00:04:42,470 And the same thing with MPLS LVP. 96 00:04:42,470 --> 00:04:45,420 We'll enable that on the interface as well. 97 00:04:45,420 --> 00:04:47,370 We'll commit those changes. 98 00:04:47,370 --> 00:04:49,550 So now, routers 3 and 4 should have 99 00:04:49,550 --> 00:04:51,800 a label for this new network. 100 00:04:51,800 --> 00:04:54,060 Let's go over and verify. 101 00:04:54,060 --> 00:04:56,900 So we'll do our show MPLS forwarding table. 102 00:04:56,900 --> 00:05:01,400 And we see that we have this 22.22.22.22 network, which 103 00:05:01,400 --> 00:05:04,350 is configured as pop, which is fine. 104 00:05:04,350 --> 00:05:05,930 It's doing PHP. 105 00:05:05,930 --> 00:05:07,775 We should see the same thing on router 4. 106 00:05:07,775 --> 00:05:11,870 107 00:05:11,870 --> 00:05:16,090 And we see that router 4 has the exact same configuration. 108 00:05:16,090 --> 00:05:19,860 So now that we have this network and label on router 3, 109 00:05:19,860 --> 00:05:21,760 of course, you know what we're here for. 110 00:05:21,760 --> 00:05:23,050 We're here to filter it. 111 00:05:23,050 --> 00:05:26,190 So now, let's configure router 2 so 112 00:05:26,190 --> 00:05:30,900 that it no longer sends the label for 22.22.22.22 113 00:05:30,900 --> 00:05:31,620 to router 3. 114 00:05:31,620 --> 00:05:35,080 But, of course, we still want router 4 to get it. 115 00:05:35,080 --> 00:05:37,830 So let's jump back over to router 2 and configure 116 00:05:37,830 --> 00:05:39,970 our filtering. 117 00:05:39,970 --> 00:05:43,680 So on router 2, what we need to do is create an ACL. 118 00:05:43,680 --> 00:05:46,050 So we'll say, IPv4 access list. 119 00:05:46,050 --> 00:05:50,400 And we'll just call this ACL_R4. 120 00:05:50,400 --> 00:05:51,900 Because what we're going to be doing 121 00:05:51,900 --> 00:05:56,850 is configuring this to only send this prefix to router 4. 122 00:05:56,850 --> 00:06:03,570 So we're going to say to permit IPv4 host 10.4.4.4 any. 123 00:06:03,570 --> 00:06:05,970 So that configures which peer we're 124 00:06:05,970 --> 00:06:07,980 going to be applying this to. 125 00:06:07,980 --> 00:06:11,160 Then, we're going to need another IPv4 ACL. 126 00:06:11,160 --> 00:06:14,100 And let's call this one actually OUT. 127 00:06:14,100 --> 00:06:16,110 This is going to be almost the same. 128 00:06:16,110 --> 00:06:20,040 But for this one, we're going to be listing the network 129 00:06:20,040 --> 00:06:21,280 that we're talking about. 130 00:06:21,280 --> 00:06:24,450 So in this case, 22.22.22.22. 131 00:06:24,450 --> 00:06:30,090 So which prefixes do we want to advertise to which peers? 132 00:06:30,090 --> 00:06:32,970 That's the purpose of these two ACLs. 133 00:06:32,970 --> 00:06:36,630 To apply this, we go into MPLS LDP. 134 00:06:36,630 --> 00:06:39,630 We're going to address family IPv4. 135 00:06:39,630 --> 00:06:45,420 We say label local advertise for. 136 00:06:45,420 --> 00:06:48,660 and then, of course, it wants to know which prefixes, so 137 00:06:48,660 --> 00:06:50,430 for which prefixes. 138 00:06:50,430 --> 00:06:55,180 This would be where we put in the ACL_R4_OUT. 139 00:06:55,180 --> 00:06:57,750 And then we say who we want to send it to. 140 00:06:57,750 --> 00:07:01,590 And this, of course, would be the ACL_R4. 141 00:07:01,590 --> 00:07:04,140 Now, remember our fundamental rules here. 142 00:07:04,140 --> 00:07:07,440 If we configure ACLs to go to a neighbor 143 00:07:07,440 --> 00:07:09,450 to advertise a particular prefix, 144 00:07:09,450 --> 00:07:11,880 it means that prefix is no longer 145 00:07:11,880 --> 00:07:14,320 advertised to anybody else. 146 00:07:14,320 --> 00:07:17,310 So by telling it what to send a router 4, 147 00:07:17,310 --> 00:07:21,270 we're telling it not to send this one to router 3. 148 00:07:21,270 --> 00:07:23,950 So let's go ahead and commit those changes. 149 00:07:23,950 --> 00:07:26,160 We'll exit configuration. 150 00:07:26,160 --> 00:07:28,650 And just to make sure everything's up to date, 151 00:07:28,650 --> 00:07:32,130 particularly since this is just a lab, let's just go ahead 152 00:07:32,130 --> 00:07:35,040 and clear our MPLS LDP neighbors, 153 00:07:35,040 --> 00:07:37,920 just to make sure everything's up to date. 154 00:07:37,920 --> 00:07:40,860 And then if we go back over to router 3, 155 00:07:40,860 --> 00:07:46,080 we should lose the label for the 22.22.22.22. 156 00:07:46,080 --> 00:07:48,080 And we can see that we have. 157 00:07:48,080 --> 00:07:50,670 We, of course, still know about the prefix. 158 00:07:50,670 --> 00:07:52,680 The prefix still exists. 159 00:07:52,680 --> 00:07:57,120 However, notice that the outgoing label is unlabeled. 160 00:07:57,120 --> 00:08:01,830 That means we did not receive a label, even the pop label, 161 00:08:01,830 --> 00:08:03,700 for that prefix. 162 00:08:03,700 --> 00:08:06,570 So our filtering is working correctly. 163 00:08:06,570 --> 00:08:10,440 If we go over to router 4, router 4 still 164 00:08:10,440 --> 00:08:13,050 has that prefix listed as pop. 165 00:08:13,050 --> 00:08:16,930 Because router 4 is still getting the label. 166 00:08:16,930 --> 00:08:20,580 So that pretty much covers how to control conditional label 167 00:08:20,580 --> 00:08:21,960 advertisement. 168 00:08:21,960 --> 00:08:25,200 We've set this up so that router 4 gets the label, 169 00:08:25,200 --> 00:08:26,940 but router 3 doesn't. 170 00:08:26,940 --> 00:08:28,950 It's, again, fairly straightforward, as long 171 00:08:28,950 --> 00:08:30,940 as we keep the rules in mind. 172 00:08:30,940 --> 00:08:33,570 But what about accepting labels? 173 00:08:33,570 --> 00:08:36,809 Well, since we're filtering things, why not configure 174 00:08:36,809 --> 00:08:40,830 router 4 here to not accept the label for this prefix, 175 00:08:40,830 --> 00:08:42,750 since we know that it's still getting it. 176 00:08:42,750 --> 00:08:44,680 Let's go ahead and do that. 177 00:08:44,680 --> 00:08:47,750 So once again, we're going to want an ACL. 178 00:08:47,750 --> 00:08:50,060 So let's start by creating this access list. 179 00:08:50,060 --> 00:08:53,060 We'll call it ACL_LABELS_R2, which 180 00:08:53,060 --> 00:08:55,850 is going to list the prefixes that we're 181 00:08:55,850 --> 00:08:57,960 willing to accept labels for. 182 00:08:57,960 --> 00:09:01,620 So in this case, it's just going to be router 2's loopback. 183 00:09:01,620 --> 00:09:05,030 So once again, let's go into MPLS LDP 184 00:09:05,030 --> 00:09:08,090 Into the address family IPv4. 185 00:09:08,090 --> 00:09:09,380 We'll say label. 186 00:09:09,380 --> 00:09:12,620 But this time, it's label remote. 187 00:09:12,620 --> 00:09:16,910 Which remote labels are we going to accept. 188 00:09:16,910 --> 00:09:18,990 We're going to say from. 189 00:09:18,990 --> 00:09:22,670 And here, we put in the LDP here that we're 190 00:09:22,670 --> 00:09:27,170 going to accept this from, colon, the label space. 191 00:09:27,170 --> 00:09:29,780 The label space is currently zero. 192 00:09:29,780 --> 00:09:33,350 So we're going to put in the host address, colon, zero. 193 00:09:33,350 --> 00:09:37,340 And then, we're going to say for, and we put in our ACL. 194 00:09:37,340 --> 00:09:41,630 We'll commit those changes and exit configuration. 195 00:09:41,630 --> 00:09:45,300 Then, let's look at our show MPLS forwarding table again. 196 00:09:45,300 --> 00:09:48,710 And what we see is that to 10.2.2.2, 197 00:09:48,710 --> 00:09:52,790 which we are still accepting the label for, says pop. 198 00:09:52,790 --> 00:09:57,710 But now, the 22.22.22.22, which we just effectively filtered 199 00:09:57,710 --> 00:10:02,670 out, is now set to unlabeled, exactly as it should be. 200 00:10:02,670 --> 00:10:05,810 So now, we have our outbound and our inbound label 201 00:10:05,810 --> 00:10:09,620 filtering working as we want. 202 00:10:09,620 --> 00:10:13,720 So in this video, we saw how to configure conditional label 203 00:10:13,720 --> 00:10:18,340 advertisement, as well as conditional label acceptance, 204 00:10:18,340 --> 00:10:21,640 if we don't want to get labels or send labels 205 00:10:21,640 --> 00:10:24,650 for every prefix in the routing table. 206 00:10:24,650 --> 00:10:27,440 We can see that this is fairly easily filtered out. 207 00:10:27,440 --> 00:10:29,750 And as long as we follow the rules correctly, 208 00:10:29,750 --> 00:10:31,990 we should get the labels where we want them 209 00:10:31,990 --> 00:10:34,010 on the devices that need them. 210 00:10:34,010 --> 00:10:36,190 So that pretty much wraps up everything 211 00:10:36,190 --> 00:10:39,460 we need to talk about in this skill, which leaves us 212 00:10:39,460 --> 00:10:41,300 with just one more thing to do. 213 00:10:41,300 --> 00:10:44,410 And that's our review in the form of a quiz. 214 00:10:44,410 --> 00:10:46,910 That's exactly what we're going to do next. 215 00:10:46,910 --> 00:10:50,110 Until then, I hope this has been informative for you, 216 00:10:50,110 --> 00:10:53,160 and I'd like to thank you for viewing. 217 00:10:53,160 --> 00:10:57,000