1 00:00:00,000 --> 00:00:03,465 [AUDIO LOGO] 2 00:00:03,465 --> 00:00:07,920 3 00:00:07,920 --> 00:00:11,910 So we've looked at several different BGP attributes 4 00:00:11,910 --> 00:00:17,200 that we can use to change BGP path selection. 5 00:00:17,200 --> 00:00:19,140 Now there's another attribute we need 6 00:00:19,140 --> 00:00:21,880 to look at here, communities. 7 00:00:21,880 --> 00:00:24,030 Now, the thing with communities, they're 8 00:00:24,030 --> 00:00:29,970 not going to affect BGP's decision in any way directly. 9 00:00:29,970 --> 00:00:35,520 Communities are just a way to tag or mark a prefix. 10 00:00:35,520 --> 00:00:38,580 The device receiving that community 11 00:00:38,580 --> 00:00:41,940 then has to be set to do something with it. 12 00:00:41,940 --> 00:00:43,750 What's it going to do? 13 00:00:43,750 --> 00:00:46,260 Well, that's going to be for us to decide. 14 00:00:46,260 --> 00:00:48,450 But one of the things that can do 15 00:00:48,450 --> 00:00:53,050 is change one of the attributes that we've already discussed. 16 00:00:53,050 --> 00:00:55,890 So maybe it changes weight, maybe 17 00:00:55,890 --> 00:00:57,960 it changes local preference. 18 00:00:57,960 --> 00:01:01,710 And that would affect the outbound decision 19 00:01:01,710 --> 00:01:04,890 of the other AS that we're sending the community 20 00:01:04,890 --> 00:01:10,730 to, therefore, affecting our inbound traffic when 21 00:01:10,730 --> 00:01:13,740 that AS sends traffic to us. 22 00:01:13,740 --> 00:01:18,590 So effectively what we would be doing is using communities 23 00:01:18,590 --> 00:01:22,880 to affect the inbound traffic, but we're doing it 24 00:01:22,880 --> 00:01:26,090 indirectly because really what's happening 25 00:01:26,090 --> 00:01:30,770 is the other AS is affecting their outbound policy based 26 00:01:30,770 --> 00:01:33,170 on the communities we send. 27 00:01:33,170 --> 00:01:37,280 Now for any of this to work, the ASs 28 00:01:37,280 --> 00:01:41,540 would have to communicate the communities with each other. 29 00:01:41,540 --> 00:01:44,420 I can't just guess what community 30 00:01:44,420 --> 00:01:47,210 to send to a particular service provider 31 00:01:47,210 --> 00:01:51,510 to get them to do a particular thing with my networks. 32 00:01:51,510 --> 00:01:53,840 So this is information that's generally 33 00:01:53,840 --> 00:01:57,470 going to be published somewhere on each service provider's 34 00:01:57,470 --> 00:01:58,970 site. 35 00:01:58,970 --> 00:02:00,770 As a service provider when you're 36 00:02:00,770 --> 00:02:03,290 interacting with other service providers, 37 00:02:03,290 --> 00:02:06,140 you have to know their policies just 38 00:02:06,140 --> 00:02:08,690 as much as you're going to have to notify them 39 00:02:08,690 --> 00:02:10,199 of your policies. 40 00:02:10,199 --> 00:02:13,130 So whatever communities you decide 41 00:02:13,130 --> 00:02:17,390 to use to allow them to influence traffic, 42 00:02:17,390 --> 00:02:20,450 you have to publish those probably on a website, 43 00:02:20,450 --> 00:02:22,940 but the point is everybody has to be 44 00:02:22,940 --> 00:02:26,700 aware of these communities or else nobody can use them. 45 00:02:26,700 --> 00:02:28,670 So what we're going to be doing is 46 00:02:28,670 --> 00:02:31,640 we're going to be sending some updates between our AS numbers, 47 00:02:31,640 --> 00:02:33,710 and we're going to use communities 48 00:02:33,710 --> 00:02:38,194 to affect the return traffic coming back to our AS. 49 00:02:38,194 --> 00:02:41,990 So as always let's take a look at our topology first, 50 00:02:41,990 --> 00:02:44,510 put together a game plan, and then we'll 51 00:02:44,510 --> 00:02:46,970 jump into the command line and get communities 52 00:02:46,970 --> 00:02:51,360 working in our topology. 53 00:02:51,360 --> 00:02:55,670 So for this demonstration, we're going to focus on that loopback 54 00:02:55,670 --> 00:03:04,770 interface on router 8 which is 100.8.8.0/24. 55 00:03:04,770 --> 00:03:06,350 And what we're going to be doing is 56 00:03:06,350 --> 00:03:12,260 having AS 65001 influence the path 57 00:03:12,260 --> 00:03:16,370 that service provider 1 or AS 100 58 00:03:16,370 --> 00:03:20,000 is using to get to that network. 59 00:03:20,000 --> 00:03:22,190 What should be happening right now, 60 00:03:22,190 --> 00:03:26,900 and we will, of course, verify this, router 1 and router 3 61 00:03:26,900 --> 00:03:32,570 should be sending traffic directly to router 7. 62 00:03:32,570 --> 00:03:36,320 What we want to accomplish is we want to get both of them 63 00:03:36,320 --> 00:03:41,750 to switch over and send the traffic to AS 1000. 64 00:03:41,750 --> 00:03:45,290 Now we're going to approach this from the perspective 65 00:03:45,290 --> 00:03:49,610 that we only have control over customer A. 66 00:03:49,610 --> 00:03:53,960 Now what I mean by that is we'll be doing the configuration 67 00:03:53,960 --> 00:04:00,020 to influence the path selection on router 7. 68 00:04:00,020 --> 00:04:04,490 We will, of course, have to do configuration on router 1 69 00:04:04,490 --> 00:04:08,450 and router 3 to get this to work to begin with. 70 00:04:08,450 --> 00:04:12,450 The service provider routers for the neighboring AS, of course, 71 00:04:12,450 --> 00:04:14,030 have to be configured. 72 00:04:14,030 --> 00:04:17,630 We also have to choose how we're going to do this. 73 00:04:17,630 --> 00:04:21,290 What we need to remember is this prefix 74 00:04:21,290 --> 00:04:26,030 that we want to use is being learned from router 6 75 00:04:26,030 --> 00:04:30,860 to router 1, and there's no local preference or weight 76 00:04:30,860 --> 00:04:33,470 or anything being set on that. 77 00:04:33,470 --> 00:04:37,820 Therefore, it's going to have the default local preference 78 00:04:37,820 --> 00:04:39,560 of 100. 79 00:04:39,560 --> 00:04:42,620 And we will use local preference to influence this path 80 00:04:42,620 --> 00:04:46,952 selection just because generally it's a better choice. 81 00:04:46,952 --> 00:04:48,410 So keeping in mind that we're going 82 00:04:48,410 --> 00:04:52,100 to be getting that default local preference, what we need 83 00:04:52,100 --> 00:04:55,940 to do since higher local preference wins, 84 00:04:55,940 --> 00:05:02,100 is when router 7 is sending out its updates to AS 100, 85 00:05:02,100 --> 00:05:05,420 we're going to have to set the local preference to something 86 00:05:05,420 --> 00:05:09,380 different like, for example, maybe 80. 87 00:05:09,380 --> 00:05:12,710 So we will have to assign community strings for this 88 00:05:12,710 --> 00:05:13,940 to happen. 89 00:05:13,940 --> 00:05:15,500 I would recommend that we're probably 90 00:05:15,500 --> 00:05:20,420 going to use community 100:80. 91 00:05:20,420 --> 00:05:23,240 The first part of the community is usually 92 00:05:23,240 --> 00:05:26,420 the AS number that's assigning this community string, 93 00:05:26,420 --> 00:05:29,120 and then the second part is usually 94 00:05:29,120 --> 00:05:31,340 something that just makes sense based 95 00:05:31,340 --> 00:05:33,090 on what we're trying to set. 96 00:05:33,090 --> 00:05:35,750 And since we're trying to set the local preference to 80, 97 00:05:35,750 --> 00:05:39,890 it would make sense to make the second part of this 80. 98 00:05:39,890 --> 00:05:41,570 Technically it could be any number 99 00:05:41,570 --> 00:05:47,075 you want, but we'll use 100:80 to get router 1 and router 3 100 00:05:47,075 --> 00:05:50,840 to lower their local preference to 80. 101 00:05:50,840 --> 00:05:53,660 Therefore, they will choose the path 102 00:05:53,660 --> 00:05:57,860 with the default local preference going to router 6. 103 00:05:57,860 --> 00:06:01,400 So let's begin by, of course, verifying the current path 104 00:06:01,400 --> 00:06:02,240 selection. 105 00:06:02,240 --> 00:06:04,250 We'll jump into the routers, and we'll 106 00:06:04,250 --> 00:06:06,695 make sure that router 1 and router 3 107 00:06:06,695 --> 00:06:11,070 are currently going directly to router 7. 108 00:06:11,070 --> 00:06:14,040 So let's begin with the show BGP for the prefix we're 109 00:06:14,040 --> 00:06:15,600 looking for. 110 00:06:15,600 --> 00:06:20,170 What we see here is that it has three available paths. 111 00:06:20,170 --> 00:06:23,730 The first one is learned from router 3. 112 00:06:23,730 --> 00:06:27,420 Now this one actually has an inaccessible next hop 113 00:06:27,420 --> 00:06:31,190 of 10.7.7.7. 114 00:06:31,190 --> 00:06:34,460 If we intended to actually try to use that path, 115 00:06:34,460 --> 00:06:37,850 we would want to fix this because that path is not 116 00:06:37,850 --> 00:06:38,810 usable. 117 00:06:38,810 --> 00:06:43,410 And particularly for redundancy, that should probably be fixed. 118 00:06:43,410 --> 00:06:45,860 However, in this particular demonstration, 119 00:06:45,860 --> 00:06:48,860 that's not the path that we're going to try to choose, 120 00:06:48,860 --> 00:06:50,900 so it really shouldn't affect how 121 00:06:50,900 --> 00:06:53,190 we're going to be changing our path selection. 122 00:06:53,190 --> 00:06:56,580 So for right now, we're not going to worry about that. 123 00:06:56,580 --> 00:06:59,390 The second path we can see is the path 124 00:06:59,390 --> 00:07:01,550 learned through router 6. 125 00:07:01,550 --> 00:07:04,730 This is the path that we ultimately want to use, 126 00:07:04,730 --> 00:07:07,580 and then, of course, we have path 3, 127 00:07:07,580 --> 00:07:10,460 which is the one that's currently the best. 128 00:07:10,460 --> 00:07:13,910 This is the path learned directly from router 7 129 00:07:13,910 --> 00:07:18,020 with router 7 itself being the next hop. 130 00:07:18,020 --> 00:07:21,300 Let's verify what we have on router 3 as well. 131 00:07:21,300 --> 00:07:23,150 Remember, in this example, that router 3 132 00:07:23,150 --> 00:07:28,790 is a route-reflector client of router 1 and router 2. 133 00:07:28,790 --> 00:07:32,840 So notice that we're getting the prefix from both of our route 134 00:07:32,840 --> 00:07:38,210 reflectors, and both of them are showing a next hop of router 1. 135 00:07:38,210 --> 00:07:41,570 Now the other path we have here, of course, the one that's 136 00:07:41,570 --> 00:07:45,770 currently best is, again, the one directly from router 7 137 00:07:45,770 --> 00:07:48,600 with router 7 as the next hop. 138 00:07:48,600 --> 00:07:50,720 So again, these are things that we're 139 00:07:50,720 --> 00:07:54,470 going to want to change through using local preference 140 00:07:54,470 --> 00:07:57,330 and communities. 141 00:07:57,330 --> 00:08:00,210 So the first thing we have to do to get this to work, 142 00:08:00,210 --> 00:08:03,830 we have to start by setting up router 1 and router 143 00:08:03,830 --> 00:08:07,520 3, our service provider routers, in order 144 00:08:07,520 --> 00:08:10,460 to accept the communities and do what 145 00:08:10,460 --> 00:08:15,570 we want with those communities to effect the BGP updates. 146 00:08:15,570 --> 00:08:17,660 So let's go ahead and configure that first. 147 00:08:17,660 --> 00:08:19,790 We'll start on router 1. 148 00:08:19,790 --> 00:08:22,490 First thing we'll need is a community-set. 149 00:08:22,490 --> 00:08:24,980 We'll call this CS_FROM_CUSTOMERS. 150 00:08:24,980 --> 00:08:27,800 151 00:08:27,800 --> 00:08:31,100 What we're going to match on is the 100:80 152 00:08:31,100 --> 00:08:34,669 that we said we were going to use in our game plan. 153 00:08:34,669 --> 00:08:39,020 We'll end the set, and then we'll write our route policy. 154 00:08:39,020 --> 00:08:42,169 We'll also call this FROM_CUSTOMERS. 155 00:08:42,169 --> 00:08:47,510 And for our logic, we're going to say if community. 156 00:08:47,510 --> 00:08:51,140 We'll do a matches-any, meaning it will accept anything 157 00:08:51,140 --> 00:08:51,950 in the list. 158 00:08:51,950 --> 00:08:53,960 It doesn't particularly matter since there's 159 00:08:53,960 --> 00:08:56,930 only one item in our list, but here we'll 160 00:08:56,930 --> 00:09:00,110 put our community-set. 161 00:09:00,110 --> 00:09:04,550 Then what we're going to do is set the local preference, 162 00:09:04,550 --> 00:09:07,850 and we're going to set the local preference to 80 exactly 163 00:09:07,850 --> 00:09:10,220 like we said in our game plan. 164 00:09:10,220 --> 00:09:12,380 We'll then forward the route. 165 00:09:12,380 --> 00:09:14,370 And again, we're not trying to filter, 166 00:09:14,370 --> 00:09:16,730 so we will pass all the other routes 167 00:09:16,730 --> 00:09:20,780 as well if they don't match our community-set. 168 00:09:20,780 --> 00:09:22,790 We'll exit out of our if. 169 00:09:22,790 --> 00:09:25,190 We'll exit out of our policy. 170 00:09:25,190 --> 00:09:27,890 Go into BGP for our neighbor. 171 00:09:27,890 --> 00:09:30,530 This would be towards router 7. 172 00:09:30,530 --> 00:09:35,090 Into our address family, and we'll assign our route policy. 173 00:09:35,090 --> 00:09:37,850 This will be an inbound policy because we're 174 00:09:37,850 --> 00:09:41,060 going to be applying this as the router coming in 175 00:09:41,060 --> 00:09:42,740 from the customers. 176 00:09:42,740 --> 00:09:46,820 We'll commit our changes and exit configuration. 177 00:09:46,820 --> 00:09:49,190 Router 3's configuration is going 178 00:09:49,190 --> 00:09:52,290 to be identical to router 1 here, 179 00:09:52,290 --> 00:09:54,660 so we'll just copy and paste. 180 00:09:54,660 --> 00:09:57,740 This is what we're going to be pasting in on router 3. 181 00:09:57,740 --> 00:10:02,570 As you can see, it's exactly what we just typed on router 1. 182 00:10:02,570 --> 00:10:10,440 So let's go ahead and paste that in and the exit configuration. 183 00:10:10,440 --> 00:10:14,550 Our next step is going to be configuring router 7 184 00:10:14,550 --> 00:10:19,470 to send the community to router 3 and router 1 so that it 185 00:10:19,470 --> 00:10:21,610 influences the path selection. 186 00:10:21,610 --> 00:10:28,020 So now let's go configure this on iOS XE on router 7. 187 00:10:28,020 --> 00:10:31,210 So the first thing we're going to need is a route map. 188 00:10:31,210 --> 00:10:35,410 We'll call it RM_TO_SP1. 189 00:10:35,410 --> 00:10:39,580 And what we're going to do is simply set the community 190 00:10:39,580 --> 00:10:42,100 to the 100:80. 191 00:10:42,100 --> 00:10:44,410 Now if you haven't seen this before, 192 00:10:44,410 --> 00:10:47,620 iOS XE does something interesting with community 193 00:10:47,620 --> 00:10:50,110 strings and how it displays them. 194 00:10:50,110 --> 00:10:52,780 If we were to say do show route-map, 195 00:10:52,780 --> 00:10:57,600 we can see here that on the route map, RM_TO_SP1, 196 00:10:57,600 --> 00:11:03,300 it's displaying the community as 6553680. 197 00:11:03,300 --> 00:11:08,630 Not exactly the 100:80 as we typed it in. 198 00:11:08,630 --> 00:11:13,220 This is the older way of displaying community strings 199 00:11:13,220 --> 00:11:15,080 in decimal format. 200 00:11:15,080 --> 00:11:18,740 This is still the default on iOS XE. 201 00:11:18,740 --> 00:11:22,520 If we want to see this in the newer format like the way we 202 00:11:22,520 --> 00:11:25,730 entered it, we have to put in one configuration 203 00:11:25,730 --> 00:11:27,150 command on the router. 204 00:11:27,150 --> 00:11:29,100 Let's go ahead and take a look at it. 205 00:11:29,100 --> 00:11:34,500 So we have to type ip bgp new-format. 206 00:11:34,500 --> 00:11:36,080 Now this will, of course, take us out 207 00:11:36,080 --> 00:11:39,440 of route-map configuration mode because this is actually 208 00:11:39,440 --> 00:11:41,340 a global command. 209 00:11:41,340 --> 00:11:43,890 But if we look at our route-map again, 210 00:11:43,890 --> 00:11:47,180 we can see that now the community is listed nicely 211 00:11:47,180 --> 00:11:50,430 as 100:80. 212 00:11:50,430 --> 00:11:53,960 Keep in mind this just affects how it's displayed. 213 00:11:53,960 --> 00:11:56,210 This doesn't actually affect the functionality 214 00:11:56,210 --> 00:11:59,070 of the communities in any way. 215 00:11:59,070 --> 00:12:00,840 However, it is much nicer. 216 00:12:00,840 --> 00:12:02,820 So now that we have that in there, 217 00:12:02,820 --> 00:12:05,880 let's go ahead and configure our router. 218 00:12:05,880 --> 00:12:09,490 So we're going to router BGP 65001. 219 00:12:09,490 --> 00:12:11,890 Now we haven't really looked at the running configuration 220 00:12:11,890 --> 00:12:13,600 on router 7. 221 00:12:13,600 --> 00:12:18,460 If we do a show run section BGP, what we need to see here 222 00:12:18,460 --> 00:12:23,230 is we're actually using peer policy templates and peer 223 00:12:23,230 --> 00:12:27,070 session templates here on router 7. 224 00:12:27,070 --> 00:12:29,890 Now, we could still put these commands directly 225 00:12:29,890 --> 00:12:32,860 on the neighbors, but it's going to make a lot more sense 226 00:12:32,860 --> 00:12:37,010 to use these templates since we already have them here. 227 00:12:37,010 --> 00:12:41,290 So we're going to say template peer-policy Main. 228 00:12:41,290 --> 00:12:43,570 Now we're not trying to apply the route-map to all 229 00:12:43,570 --> 00:12:48,280 the neighbors, but we are trying to get it to send communities, 230 00:12:48,280 --> 00:12:51,950 and we have to tell iOS XE to do that. 231 00:12:51,950 --> 00:12:54,310 So we have to say send-community. 232 00:12:54,310 --> 00:12:56,380 Then we have to choose if we want to send 233 00:12:56,380 --> 00:13:00,160 extended, standard, or both. 234 00:13:00,160 --> 00:13:03,520 By the way, all of this is simply about the fact 235 00:13:03,520 --> 00:13:08,240 that iOS XE does not send communities by default. 236 00:13:08,240 --> 00:13:10,780 So since we're going to write a route-map that's 237 00:13:10,780 --> 00:13:13,840 setting communities, and then apply it to a neighbor, 238 00:13:13,840 --> 00:13:16,120 it would probably help if we were actually 239 00:13:16,120 --> 00:13:18,280 sending those communities. 240 00:13:18,280 --> 00:13:21,320 The default behavior, like I said, is not to. 241 00:13:21,320 --> 00:13:23,710 So all we're really doing is enabling 242 00:13:23,710 --> 00:13:27,490 a feature, the ability to send communities. 243 00:13:27,490 --> 00:13:30,490 It doesn't mean it's going to start magically doing that. 244 00:13:30,490 --> 00:13:34,900 The reason I'm saying it this way is I usually turn on both. 245 00:13:34,900 --> 00:13:36,970 Some people look at this and say, well, you're 246 00:13:36,970 --> 00:13:39,700 not even using extended communities right now. 247 00:13:39,700 --> 00:13:40,580 That's true. 248 00:13:40,580 --> 00:13:41,570 I'm not. 249 00:13:41,570 --> 00:13:43,630 But on the other hand, it doesn't really 250 00:13:43,630 --> 00:13:46,972 hurt to turn them on even if you're not using them, 251 00:13:46,972 --> 00:13:49,180 and then you would be ready to use them in the future 252 00:13:49,180 --> 00:13:50,510 if you wanted to. 253 00:13:50,510 --> 00:13:53,380 So when I'm enabling communities on the router, 254 00:13:53,380 --> 00:13:55,900 I usually do both just because it 255 00:13:55,900 --> 00:13:57,700 doesn't hurt to have them enabled 256 00:13:57,700 --> 00:13:59,450 even if you're not using them. 257 00:13:59,450 --> 00:14:02,530 So we'll just go ahead and do both. 258 00:14:02,530 --> 00:14:04,230 Now at this point, we're probably 259 00:14:04,230 --> 00:14:07,020 going to want a peer-policy specifically 260 00:14:07,020 --> 00:14:11,440 for service provider 1, so let's go ahead and create one. 261 00:14:11,440 --> 00:14:14,910 So we'll say template peer-policy, 262 00:14:14,910 --> 00:14:19,170 and let's just call it something like SP1. 263 00:14:19,170 --> 00:14:20,970 And what we're going to do is we're 264 00:14:20,970 --> 00:14:27,480 going to apply our route-map, so route-map RM_TWO_SP1, 265 00:14:27,480 --> 00:14:30,150 and that would be applied outbound. 266 00:14:30,150 --> 00:14:33,930 And then, of course, just like the other peer policies, 267 00:14:33,930 --> 00:14:36,120 we're going to tell this to inherit. 268 00:14:36,120 --> 00:14:38,340 Now when you're inheriting these, 269 00:14:38,340 --> 00:14:40,800 you have to give it a sequence number 270 00:14:40,800 --> 00:14:43,800 because if you're inheriting more than one policy, 271 00:14:43,800 --> 00:14:47,310 they have to be inherited in a specific order. 272 00:14:47,310 --> 00:14:50,580 Now in this case, we're only inheriting one policy, 273 00:14:50,580 --> 00:14:52,330 so it doesn't really matter. 274 00:14:52,330 --> 00:14:55,060 We'll say to inherit this one first. 275 00:14:55,060 --> 00:14:57,360 Now let's configure our neighbors 276 00:14:57,360 --> 00:15:02,740 we'll start with 50.0.167.1, that's router 1's address. 277 00:15:02,740 --> 00:15:04,750 And what are we going to do? 278 00:15:04,750 --> 00:15:09,050 We're going to tell it to inherit peer-policy SP1. 279 00:15:09,050 --> 00:15:10,800 Then we're just going to hit the up arrow, 280 00:15:10,800 --> 00:15:13,360 and we'll change our neighbor statement. 281 00:15:13,360 --> 00:15:16,830 This is going to be for 10.3.3.3. 282 00:15:16,830 --> 00:15:20,040 So just a quick recap of what we had to configure here. 283 00:15:20,040 --> 00:15:23,640 We had to set up our route-map, which goes ahead 284 00:15:23,640 --> 00:15:26,850 and sets the community on the updates being sent out 285 00:15:26,850 --> 00:15:28,830 to service provider 1. 286 00:15:28,830 --> 00:15:33,390 Then we updated our Main peer-policy 287 00:15:33,390 --> 00:15:37,960 to tell it to send communities both extended and standard. 288 00:15:37,960 --> 00:15:41,490 Then we created a new peer template 289 00:15:41,490 --> 00:15:46,650 that inherits the main template and applies our new route map. 290 00:15:46,650 --> 00:15:50,280 We then configured both of our neighbors router 1 291 00:15:50,280 --> 00:15:55,500 and router 3 in service provider 1 or AS 100 to then 292 00:15:55,500 --> 00:15:59,760 inherit that new policy that we put on the neighborship. 293 00:15:59,760 --> 00:16:03,780 So now we should be able to clear our outbound updates 294 00:16:03,780 --> 00:16:06,900 and see the changes actually happen on router 1 295 00:16:06,900 --> 00:16:09,130 and router 3. 296 00:16:09,130 --> 00:16:12,760 Now before we actually do that, let's set up a Wireshark 297 00:16:12,760 --> 00:16:17,590 capture just on router 1, so we can see this update coming in 298 00:16:17,590 --> 00:16:21,800 and take a look at the community strings on that update. 299 00:16:21,800 --> 00:16:24,370 So I started up that Wireshark capture. 300 00:16:24,370 --> 00:16:26,050 We've seen that quite a few times. 301 00:16:26,050 --> 00:16:28,000 I don't think we need to see the setup, 302 00:16:28,000 --> 00:16:30,830 but let's go ahead and do our clear now. 303 00:16:30,830 --> 00:16:35,350 So first, let's go to router 1 and see if it got the updates. 304 00:16:35,350 --> 00:16:38,110 We'll just do a show BGP for our prefix. 305 00:16:38,110 --> 00:16:42,160 And what we see here is our first path 306 00:16:42,160 --> 00:16:45,040 is the path through AS 1000. 307 00:16:45,040 --> 00:16:48,670 It has the default local preference of 100, 308 00:16:48,670 --> 00:16:52,120 and therefore, is being chosen as best. 309 00:16:52,120 --> 00:16:56,920 The route that we did not want to use, the one from router 7, 310 00:16:56,920 --> 00:17:01,450 we can see is now being set to a local preference of 80 exactly 311 00:17:01,450 --> 00:17:02,510 as we wanted. 312 00:17:02,510 --> 00:17:08,990 And we can see the community of 100:80 attached to this update. 313 00:17:08,990 --> 00:17:10,720 So now let's go take a look at what 314 00:17:10,720 --> 00:17:12,819 this looks like in Wireshark. 315 00:17:12,819 --> 00:17:15,910 So looking here in Wireshark, we can 316 00:17:15,910 --> 00:17:19,839 see that we've received this update from router 7. 317 00:17:19,839 --> 00:17:22,480 And if we look down in the update itself, 318 00:17:22,480 --> 00:17:26,329 first for the NLRI, we can see that this is in fact, 319 00:17:26,329 --> 00:17:31,540 for the 100.8.8.0/24 prefix. 320 00:17:31,540 --> 00:17:34,670 And then here under the path attributes, 321 00:17:34,670 --> 00:17:37,510 we can see quite clearly where it's carrying 322 00:17:37,510 --> 00:17:41,630 that community of 100:80. 323 00:17:41,630 --> 00:17:43,760 Now just as one final verification just 324 00:17:43,760 --> 00:17:46,230 to make sure everything's working as it should be, 325 00:17:46,230 --> 00:17:49,880 let's also verify this on router 3. 326 00:17:49,880 --> 00:17:52,880 So on router 3 we'll just do a show BGP. 327 00:17:52,880 --> 00:17:58,850 And what we see is that for the 100.8.8.0/24 prefix, 328 00:17:58,850 --> 00:18:05,090 the next hop of 10.1.1.1 has been selected going to an AS 329 00:18:05,090 --> 00:18:10,040 path of the 10000 65001. 330 00:18:10,040 --> 00:18:12,740 So this has also worked where it's not 331 00:18:12,740 --> 00:18:14,840 trying to go directly to router 7, 332 00:18:14,840 --> 00:18:17,960 but rather going up to router 1 who's 333 00:18:17,960 --> 00:18:20,720 then going over to AS 1000. 334 00:18:20,720 --> 00:18:23,720 So this is local preference being 335 00:18:23,720 --> 00:18:31,210 manipulated by community strings working exactly as we designed. 336 00:18:31,210 --> 00:18:34,420 In this video, we took a look at how 337 00:18:34,420 --> 00:18:40,690 to use communities to actually manipulate inbound BGP path 338 00:18:40,690 --> 00:18:41,950 selection. 339 00:18:41,950 --> 00:18:45,400 And we do this by sending a specific community 340 00:18:45,400 --> 00:18:49,630 to our neighboring AS who then has a policy implemented 341 00:18:49,630 --> 00:18:52,900 to do something with that prefix, such as change 342 00:18:52,900 --> 00:18:55,330 the local preference, which is what we did. 343 00:18:55,330 --> 00:18:57,220 Theoretically, they could also change 344 00:18:57,220 --> 00:19:00,490 the weight or some other BGP attribute 345 00:19:00,490 --> 00:19:04,300 to influence the path selection, but local preference 346 00:19:04,300 --> 00:19:07,010 is a very common thing to do here. 347 00:19:07,010 --> 00:19:11,410 So in that way, we actually influenced the outbound path 348 00:19:11,410 --> 00:19:14,560 selection of our neighboring AS, which, 349 00:19:14,560 --> 00:19:19,310 of course, is effectively our inbound path selection. 350 00:19:19,310 --> 00:19:21,430 I hope this has been informative for you, 351 00:19:21,430 --> 00:19:24,540 and I'd like to thank you for viewing. 352 00:19:24,540 --> 00:19:28,000