| 1 | Static Routing Lab |
|---|
| 2 | ================== |
|---|
| 3 | |
|---|
| 4 | Accessing the routers |
|---|
| 5 | --------------------- |
|---|
| 6 | |
|---|
| 7 | The overall architecture and the full address plan can be found in the [IP |
|---|
| 8 | Address Plan](<0.72_ip_address_plan.md>). |
|---|
| 9 | |
|---|
| 10 | See the [Layer 2 Network Design Lab](<1.31_layer_2_network_design_lab.md>) for |
|---|
| 11 | details of how to login. The routers have the same username and passwords as the |
|---|
| 12 | switches. |
|---|
| 13 | |
|---|
| 14 | The console details are: |
|---|
| 15 | |
|---|
| 16 | | **Router Name** | **Console** | |
|---|
| 17 | |-----------------|----------------------------| |
|---|
| 18 | | r1-bdr-campus1 | telnet s1.ws.nsrc.org 2101 | |
|---|
| 19 | | r1-bdr-campus2 | telnet s1.ws.nsrc.org 2201 | |
|---|
| 20 | | r1-bdr-campus3 | telnet s1.ws.nsrc.org 2301 | |
|---|
| 21 | | r1-bdr-campus4 | telnet s1.ws.nsrc.org 2401 | |
|---|
| 22 | | r1-bdr-campus5 | telnet s1.ws.nsrc.org 2501 | |
|---|
| 23 | | r1-bdr-campus6 | telnet s1.ws.nsrc.org 2601 | |
|---|
| 24 | | r1-core-campus1 | telnet s1.ws.nsrc.org 2102 | |
|---|
| 25 | | r1-core-campus2 | telnet s1.ws.nsrc.org 2202 | |
|---|
| 26 | | r1-core-campus3 | telnet s1.ws.nsrc.org 2302 | |
|---|
| 27 | | r1-core-campus4 | telnet s1.ws.nsrc.org 2402 | |
|---|
| 28 | | r1-core-campus5 | telnet s1.ws.nsrc.org 2502 | |
|---|
| 29 | | r1-core-campus6 | telnet s1.ws.nsrc.org 2602 | |
|---|
| 30 | |
|---|
| 31 | Basic Router Configuration |
|---|
| 32 | -------------------------- |
|---|
| 33 | |
|---|
| 34 | |
|---|
| 35 | |
|---|
| 36 |  |
|---|
| 37 | |
|---|
| 38 | Our campus network consists of two routers, r1-bdr-campusX and r1-core-campusX |
|---|
| 39 | as well as six switches that we've already configured. |
|---|
| 40 | |
|---|
| 41 | The following table shows the connections between each device in the campus: |
|---|
| 42 | |
|---|
| 43 | | **Device** | **Interface** | **Remote Device** | **Remote Interface** | |
|---|
| 44 | |-----------------|------------------|-------------------|----------------------| |
|---|
| 45 | | sd1-bN-campusX | FastEthernet1/12 | se1-bN-campusX | FastEthernet1/14 | |
|---|
| 46 | | | FastEthernet1/13 | se1-bN-campusX | FastEthernet1/15 | |
|---|
| 47 | | | FastEthernet1/14 | se2-bN-campusX | FastEthernet1/15 | |
|---|
| 48 | | r1-core-campusX | FastEthernet0/0 | r1-bdr-campusX | FastEthernet0/1 | |
|---|
| 49 | | | FastEthernet0/1 | sd1-b1-campusX | FastEthernet1/15 | |
|---|
| 50 | | | FastEthernet1/0 | sd1-b2-campusX | FastEthernet1/15 | |
|---|
| 51 | | | FastEthernet1/1 | pc1-campusX | | |
|---|
| 52 | |
|---|
| 53 | ### Hostname |
|---|
| 54 | |
|---|
| 55 | Your routers should be given a basic configuration as follows: |
|---|
| 56 | |
|---|
| 57 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 58 | Router> enable |
|---|
| 59 | Router# config terminal |
|---|
| 60 | Enter configuration commands, one per line. End with CNTL/Z. |
|---|
| 61 | Router(config)# hostname r1-bdr-campusX |
|---|
| 62 | r1-bdr-campusX(config)# |
|---|
| 63 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 64 | |
|---|
| 65 | ### Turn Off Domain Name Lookups |
|---|
| 66 | |
|---|
| 67 | Cisco devices will always try to look up the DNS for any name or address |
|---|
| 68 | specified in the command line. You can see this when doing a trace on a router |
|---|
| 69 | with no DNS server or a DNS server with no in-addr.arpa entries for the IP |
|---|
| 70 | addresses. We will turn this lookup off for the labs for the time being to speed |
|---|
| 71 | up traceroutes. |
|---|
| 72 | |
|---|
| 73 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 74 | r1-bdr-campusX (config)# no ip domain-lookup |
|---|
| 75 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 76 | |
|---|
| 77 | ### Configure console and other ports |
|---|
| 78 | |
|---|
| 79 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 80 | r1-bdr-campusX (config)# line con 0 |
|---|
| 81 | r1-bdr-campusX (config-line)# transport preferred none |
|---|
| 82 | r1-bdr-campusX (config-line)# line vty 0 4 |
|---|
| 83 | r1-bdr-campusX (config-line)# transport preferred none |
|---|
| 84 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 85 | |
|---|
| 86 | ### Usernames and Passwords |
|---|
| 87 | |
|---|
| 88 | All router usernames should be **cndlab** and all passwords should be |
|---|
| 89 | **lab-PW**. Please do not change the username or password to anything else, or |
|---|
| 90 | leave the password unconfigured (access to vty ports is not possible if no |
|---|
| 91 | password is set). It is essential for a smooth operating lab that all |
|---|
| 92 | participants have access to all routers. |
|---|
| 93 | |
|---|
| 94 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 95 | r1-bdr-campusX (config)# username cndlab secret lab-PW |
|---|
| 96 | r1-bdr-campusX (config)# enable secret lab-PW |
|---|
| 97 | r1-bdr-campusX (config)# service password-encryption |
|---|
| 98 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 99 | |
|---|
| 100 | The service password-encryption directive tells the router to encrypt all |
|---|
| 101 | passwords stored in the router’s configuration (apart from enable secret which |
|---|
| 102 | is already encrypted). |
|---|
| 103 | |
|---|
| 104 | **Note A:** There is the temptation to simply have a username of cisco and |
|---|
| 105 | password of cisco as a lazy solution to the username/password problem. Under no |
|---|
| 106 | circumstances must any service provider operator ever use easily guessable |
|---|
| 107 | passwords as these on their live operational network. |
|---|
| 108 | |
|---|
| 109 | **IMPORTANT: This sentence cannot be emphasized enough. It is quite common for |
|---|
| 110 | attackers to gain access to networks simply because operators have used familiar |
|---|
| 111 | or easily guessed passwords.** |
|---|
| 112 | |
|---|
| 113 | **Note B:** for IOS releases prior to 12.3, the username/secret pair is not |
|---|
| 114 | available, and operators will have to configure username/password instead. The |
|---|
| 115 | latter format uses type-7 encryption, whereas the former is the more secure md5 |
|---|
| 116 | based encryption. |
|---|
| 117 | |
|---|
| 118 | ### Enabling login access for other machines |
|---|
| 119 | |
|---|
| 120 | In order to let you telnet into your router in future modules of this workshop, |
|---|
| 121 | you need to configure a password for all virtual terminal lines. |
|---|
| 122 | |
|---|
| 123 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 124 | r1-bdr-campusX (config)# aaa new-model |
|---|
| 125 | r1-bdr-campusX (config)# aaa authentication login default local |
|---|
| 126 | r1-bdr-campusX (config)# aaa authentication enable default enable |
|---|
| 127 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 128 | |
|---|
| 129 | This series of commands tells the router to look locally for standard user login |
|---|
| 130 | (the username password pair set earlier), and to the locally configured enable |
|---|
| 131 | secret for the enable login. By default, login will be enabled on all vtys for |
|---|
| 132 | other teams to gain access. |
|---|
| 133 | |
|---|
| 134 | ### Configure system logging |
|---|
| 135 | |
|---|
| 136 | A vital part of any Internet operational system is to record logs. The router by |
|---|
| 137 | default will display system logs on the router console. However, this is |
|---|
| 138 | undesirable for Internet operational routers, as the console is a 9600 baud |
|---|
| 139 | connection, and can place a high processor interrupt load at the time of busy |
|---|
| 140 | traffic on the network. However, the router logs can also be recorded into a |
|---|
| 141 | buffer on the router – this takes no interrupt load and it also enables to |
|---|
| 142 | operator to check the history of what events happened on the router. In a future |
|---|
| 143 | module, the lab will configuration the router to send the log messages to a |
|---|
| 144 | SYSLOG server. |
|---|
| 145 | |
|---|
| 146 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 147 | r1-bdr-campusX (config)# no logging console |
|---|
| 148 | r1-bdr-campusX (config)# logging buffered 8192 debug |
|---|
| 149 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 150 | |
|---|
| 151 | which disables console logs and instead records all logs in a 8192 byte buffer |
|---|
| 152 | set aside on the router. To see the contents of this internal logging buffer at |
|---|
| 153 | any time, the command “show log” should be used at the command prompt. |
|---|
| 154 | |
|---|
| 155 | ### Save the Configuration. |
|---|
| 156 | |
|---|
| 157 | With the basic configuration in place, save the configuration. To do this, exit |
|---|
| 158 | from enable mode by typing “end” or “`<ctrl>` Z”, and at the command prompt |
|---|
| 159 | enter “write memory”. |
|---|
| 160 | |
|---|
| 161 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 162 | r1-bdr-campusX(config)#^Z |
|---|
| 163 | r1-bdr-campusX# write memory |
|---|
| 164 | Building configuration... |
|---|
| 165 | [OK] |
|---|
| 166 | r1-bdr-campusX# |
|---|
| 167 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 168 | |
|---|
| 169 | It is highly recommended that the configuration is saved quite frequently to |
|---|
| 170 | NVRAM. If the configuration is not saved to NVRAM, any changes made to the |
|---|
| 171 | running configuration will be lost after a power cycle or virtual machine |
|---|
| 172 | failure. |
|---|
| 173 | |
|---|
| 174 | Log off the router by typing *exit*, and then log back in again. Notice how the |
|---|
| 175 | login sequence has changed, prompting for a “username” and “password” from the |
|---|
| 176 | user. Note that at each checkpoint in the workshop, you should save the |
|---|
| 177 | configuration to memory – remember that powering the router off will result in |
|---|
| 178 | it reverting to the last saved configuration in NVRAM. |
|---|
| 179 | |
|---|
| 180 | |
|---|
| 181 | |
|---|
| 182 | Configure the Core Router |
|---|
| 183 | ------------------------- |
|---|
| 184 | |
|---|
| 185 | ### Configure interface to the Border router |
|---|
| 186 | |
|---|
| 187 | Make sure you change the X below to the correct value for your campus: |
|---|
| 188 | |
|---|
| 189 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 190 | interface FastEthernet0/0 |
|---|
| 191 | description CAMPUS CORE to BORDER |
|---|
| 192 | ip address 100.68.X.2 255.255.255.240 |
|---|
| 193 | ipv6 address 2001:db8:X:0::2/64 |
|---|
| 194 | no ip redirects |
|---|
| 195 | no ip proxy-arp |
|---|
| 196 | no shutdown |
|---|
| 197 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 198 | |
|---|
| 199 | ### Configure the Management VLAN interfaces |
|---|
| 200 | |
|---|
| 201 | In the VLAN lab we moved the Management address of the switches into a dedicated |
|---|
| 202 | vlan for each building. We used vlan 41 in Building 1 and vlan 42 in Building 2. |
|---|
| 203 | Now we'll configure our core router so that it can talk to these vlans (and the |
|---|
| 204 | switches). |
|---|
| 205 | |
|---|
| 206 | On r1-core-campusX add the following for Building 1: |
|---|
| 207 | |
|---|
| 208 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 209 | interface FastEthernet0/1 |
|---|
| 210 | no ip address |
|---|
| 211 | no shutdown |
|---|
| 212 | ! |
|---|
| 213 | interface FastEthernet0/1.41 |
|---|
| 214 | description Building 1 Management - vlan 41 |
|---|
| 215 | encapsulation dot1Q 41 |
|---|
| 216 | ip address 172.2X.0.1 255.255.255.240 |
|---|
| 217 | ipv6 address 2001:db8:X:3::1/64 |
|---|
| 218 | no ip redirects |
|---|
| 219 | no ip proxy-arp |
|---|
| 220 | no shutdown |
|---|
| 221 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 222 | |
|---|
| 223 | And for Building 2: |
|---|
| 224 | |
|---|
| 225 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 226 | interface FastEthernet0/1 |
|---|
| 227 | no ip address |
|---|
| 228 | no shutdown |
|---|
| 229 | ! |
|---|
| 230 | interface FastEthernet0/1.42 |
|---|
| 231 | description Building 2 Management - vlan 42 |
|---|
| 232 | encapsulatoin dot1Q 42 |
|---|
| 233 | ip address 172.2X.0.17 255.255.255.240 |
|---|
| 234 | ipv6 address 2001:db8:X:4::1/64 |
|---|
| 235 | no ip redirects |
|---|
| 236 | no ip proxy-arp |
|---|
| 237 | no shutdown |
|---|
| 238 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 239 | |
|---|
| 240 | Exit config mode and save your changes! |
|---|
| 241 | |
|---|
| 242 | Test that you can ping all six switches from the core router. You should also |
|---|
| 243 | test that you can ping the Building 1 switches from the Building 2 switches. |
|---|
| 244 | |
|---|
| 245 | ### Configure the STAFF and STUDENT interfaces |
|---|
| 246 | |
|---|
| 247 | We've configured STAFF and STUDENT ports on our edge switches and any device |
|---|
| 248 | plugged into those ports should be able to talk to others in the same vlan. If |
|---|
| 249 | we want to allow those devices to get to the wider campus network and the |
|---|
| 250 | Internet we need to add interfaces on the core router. |
|---|
| 251 | |
|---|
| 252 | For Building 1 we need to add: |
|---|
| 253 | |
|---|
| 254 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 255 | interface FastEthernet0/1.51 |
|---|
| 256 | description Building 1 STAFF - vlan 51 |
|---|
| 257 | encapsulation dot1Q 51 |
|---|
| 258 | ip address 172.2X.51.1 255.255.255.0 |
|---|
| 259 | ipv6 address 2001:db8:X:51::1/64 |
|---|
| 260 | no ip redirects |
|---|
| 261 | no ip proxy-arp |
|---|
| 262 | no shutdown |
|---|
| 263 | ! |
|---|
| 264 | interface FastEthernet0/1.61 |
|---|
| 265 | description Building 1 STUDENT - vlan 61 |
|---|
| 266 | encapsulation dot1Q 61 |
|---|
| 267 | ip address 172.2X.61.1 255.255.255.0 |
|---|
| 268 | ipv6 address 2001:db8:X:61::1/64 |
|---|
| 269 | no ip redirects |
|---|
| 270 | no ip proxy-arp |
|---|
| 271 | no shutdown |
|---|
| 272 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 273 | |
|---|
| 274 | For Building 2 we need to add: |
|---|
| 275 | |
|---|
| 276 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 277 | interface FastEthernet0/1.52 |
|---|
| 278 | description Building 2 STAFF - vlan 52 |
|---|
| 279 | encapsulation dot1Q 52 |
|---|
| 280 | ip address 172.2X.52.1 255.255.255.0 |
|---|
| 281 | ipv6 address 2001:db8:X:52::1/64 |
|---|
| 282 | no ip redirects |
|---|
| 283 | no ip proxy-arp |
|---|
| 284 | no shutdown |
|---|
| 285 | ! |
|---|
| 286 | interface FastEthernet0/1.62 |
|---|
| 287 | description Building 2 STUDENT - vlan 62 |
|---|
| 288 | encapsulation dot1Q 62 |
|---|
| 289 | ip address 172.2X.62.1 255.255.255.0 |
|---|
| 290 | ipv6 address 2001:db8:X:62::1/64 |
|---|
| 291 | no ip redirects |
|---|
| 292 | no ip proxy-arp |
|---|
| 293 | no shutdown |
|---|
| 294 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 295 | |
|---|
| 296 | If we had a real physical network, we'd be able to connect a device to the |
|---|
| 297 | switch ports we set up earlier, configure an IP address and ping the router at |
|---|
| 298 | this stage. |
|---|
| 299 | |
|---|
| 300 | ### Configure the Network Management and Monitoring interface |
|---|
| 301 | |
|---|
| 302 | Our network management and monitoring server, pc1-campusX.ws.nsrc.org, is |
|---|
| 303 | connected to FastEthernet1/1 on the core router. We'll configure the router, |
|---|
| 304 | r1-core-campusX, so that we can start to use that server to manage and monitor |
|---|
| 305 | our network: |
|---|
| 306 | |
|---|
| 307 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 308 | interface FastEthernet1/1 |
|---|
| 309 | description Network Management and Monitoring |
|---|
| 310 | no switchport |
|---|
| 311 | ip address 100.68.X.129 255.255.255.240 |
|---|
| 312 | ipv6 address 2001:db8:X:1::1/64 |
|---|
| 313 | no ip redirects |
|---|
| 314 | no ip proxy-arp |
|---|
| 315 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 316 | |
|---|
| 317 | At this stage you should be able to ssh to pc1-campusX.ws.nsrc.org as sysadm and |
|---|
| 318 | ping the core router on this address. |
|---|
| 319 | |
|---|
| 320 | If that works, try using telnet to connect to the router. |
|---|
| 321 | |
|---|
| 322 | ### Set up SNMP access on the Core router |
|---|
| 323 | |
|---|
| 324 | Later in the week we're going to start using SNMP to manage the routers and |
|---|
| 325 | switches. We'll add the necessary commands at this stage: |
|---|
| 326 | |
|---|
| 327 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 328 | access-list 99 permit 100.68.X.130 |
|---|
| 329 | ! |
|---|
| 330 | snmp-server community NetManage RO 99 |
|---|
| 331 | snmp ifmib ifindex persist |
|---|
| 332 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 333 | |
|---|
| 334 | The access-list only allows SNMP queries from the NMM server. |
|---|
| 335 | |
|---|
| 336 | If your router doesn't take the above snmp commands, try the following instead. |
|---|
| 337 | Even though Cisco IOS is one operating system, the implementation details on |
|---|
| 338 | different platforms can well be different: |
|---|
| 339 | |
|---|
| 340 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 341 | access-list 99 permit 100.68.X.130 |
|---|
| 342 | ! |
|---|
| 343 | snmp-server community NetManage RO 99 |
|---|
| 344 | snmp-server ifindex persist |
|---|
| 345 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 346 | |
|---|
| 347 | |
|---|
| 348 | |
|---|
| 349 | Configure the Border Router |
|---|
| 350 | --------------------------- |
|---|
| 351 | |
|---|
| 352 | ### Configure the NREN interface |
|---|
| 353 | |
|---|
| 354 | The full address plan for the lab can be found in the [IP Address |
|---|
| 355 | Plan](<0.72_ip_address_plan.md>). Consult the address plan for the addresses of |
|---|
| 356 | the point to point links between the Campus Border Router and the NREN Router. |
|---|
| 357 | |
|---|
| 358 | Make sure you change the **X** and **Y** below to the correct value from address |
|---|
| 359 | plan mentioned above: |
|---|
| 360 | |
|---|
| 361 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 362 | interface FastEthernet0/0 |
|---|
| 363 | description Link to NREN |
|---|
| 364 | ip address 100.68.0.Y 255.255.255.252 |
|---|
| 365 | ipv6 address 2001:db8:0:X::1/127 |
|---|
| 366 | no ip redirects |
|---|
| 367 | no ip proxy-arp |
|---|
| 368 | no shutdown |
|---|
| 369 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 370 | |
|---|
| 371 | Test that you can ping the NREN end of the link. |
|---|
| 372 | |
|---|
| 373 | ### Configure the Core interface |
|---|
| 374 | |
|---|
| 375 | Make sure you change the **X** below to the correct value for your campus: |
|---|
| 376 | |
|---|
| 377 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 378 | interface FastEthernet0/1 |
|---|
| 379 | description CAMPUS CORE |
|---|
| 380 | ip address 100.68.X.1 255.255.255.240 |
|---|
| 381 | ipv6 address 2001:db8:X:0::1/64 |
|---|
| 382 | no ip redirects |
|---|
| 383 | no ip proxy-arp |
|---|
| 384 | no shutdown |
|---|
| 385 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 386 | |
|---|
| 387 | Test that you can ping your Core router at the other end this link. |
|---|
| 388 | |
|---|
| 389 | ### Set up SNMP access on the Border router |
|---|
| 390 | |
|---|
| 391 | Later in the week we're going to start using SNMP to manage the routers and |
|---|
| 392 | switches. We'll add the necessary commands at this stage: |
|---|
| 393 | |
|---|
| 394 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 395 | access-list 99 permit 100.68.X.130 |
|---|
| 396 | ! |
|---|
| 397 | snmp-server community NetManage RO 99 |
|---|
| 398 | snmp ifmib ifindex persist |
|---|
| 399 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 400 | |
|---|
| 401 | The access-list only allows SNMP queries from the NMM server. |
|---|
| 402 | |
|---|
| 403 | If your router doesn't take the above snmp commands, try the following instead. |
|---|
| 404 | Even though Cisco IOS is one operating system, the implementation details on |
|---|
| 405 | different platforms can well be different: |
|---|
| 406 | |
|---|
| 407 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 408 | access-list 99 permit 100.68.X.130 |
|---|
| 409 | ! |
|---|
| 410 | snmp-server community NetManage RO 99 |
|---|
| 411 | snmp-server ifindex persist |
|---|
| 412 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 413 | |
|---|
| 414 | |
|---|
| 415 | |
|---|
| 416 | Configure Static Routing |
|---|
| 417 | ------------------------ |
|---|
| 418 | |
|---|
| 419 | At this stage you should be able to ping each of the devices in your campus |
|---|
| 420 | network from their immediate neighbours. If you try to ping the Border router |
|---|
| 421 | from one of the switches or the NMM server you'll have less success. We need to |
|---|
| 422 | add some additional routing information to the routers so that we can pass |
|---|
| 423 | packets successfully. |
|---|
| 424 | |
|---|
| 425 | Let's look at the routing information on the Core router: |
|---|
| 426 | |
|---|
| 427 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 428 | r1-core-campus1#sh ip route |
|---|
| 429 | Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP |
|---|
| 430 | D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area |
|---|
| 431 | N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2 |
|---|
| 432 | E1 - OSPF external type 1, E2 - OSPF external type 2 |
|---|
| 433 | i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2 |
|---|
| 434 | ia - IS-IS inter area, * - candidate default, U - per-user static route |
|---|
| 435 | o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP |
|---|
| 436 | + - replicated route, % - next hop override |
|---|
| 437 | |
|---|
| 438 | Gateway of last resort is not set |
|---|
| 439 | |
|---|
| 440 | 100.0.0.0/8 is variably subnetted, 5 subnets, 2 masks |
|---|
| 441 | C 100.68.1.0/28 is directly connected, FastEthernet0/0 |
|---|
| 442 | L 100.68.1.2/32 is directly connected, FastEthernet0/0 |
|---|
| 443 | C 100.68.1.128/28 is directly connected, FastEthernet1/1 |
|---|
| 444 | L 100.68.1.129/32 is directly connected, FastEthernet1/1 |
|---|
| 445 | C 100.68.1.242/32 is directly connected, Loopback0 |
|---|
| 446 | 172.21.0.0/16 is variably subnetted, 4 subnets, 2 masks |
|---|
| 447 | C 172.21.0.0/28 is directly connected, FastEthernet0/1.41 |
|---|
| 448 | L 172.21.0.1/32 is directly connected, FastEthernet0/1.41 |
|---|
| 449 | C 172.21.0.16/28 is directly connected, FastEthernet1/0.42 |
|---|
| 450 | L 172.21.0.17/32 is directly connected, FastEthernet1/0.42 |
|---|
| 451 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 452 | |
|---|
| 453 | and on the Border router: |
|---|
| 454 | |
|---|
| 455 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 456 | r1-bdr-campus1>sh ip route |
|---|
| 457 | Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP |
|---|
| 458 | D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area |
|---|
| 459 | N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2 |
|---|
| 460 | E1 - OSPF external type 1, E2 - OSPF external type 2 |
|---|
| 461 | i - IS-IS, su - IS-IS summary, L1 - IS-IS level-1, L2 - IS-IS level-2 |
|---|
| 462 | ia - IS-IS inter area, * - candidate default, U - per-user static route |
|---|
| 463 | o - ODR, P - periodic downloaded static route, H - NHRP, l - LISP |
|---|
| 464 | + - replicated route, % - next hop override |
|---|
| 465 | |
|---|
| 466 | Gateway of last resort is not set |
|---|
| 467 | |
|---|
| 468 | 100.0.0.0/8 is variably subnetted, 5 subnets, 3 masks |
|---|
| 469 | C 100.68.0.0/30 is directly connected, FastEthernet0/0 |
|---|
| 470 | L 100.68.0.2/32 is directly connected, FastEthernet0/0 |
|---|
| 471 | C 100.68.1.0/28 is directly connected, FastEthernet0/1 |
|---|
| 472 | L 100.68.1.1/32 is directly connected, FastEthernet0/1 |
|---|
| 473 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 474 | |
|---|
| 475 | Each of the routers knows about the **local** and **connected** networks but no |
|---|
| 476 | other routes. |
|---|
| 477 | |
|---|
| 478 | What about IPv6? What routes do you see for IPv6 destinations? Is there a |
|---|
| 479 | similarity with what you see for IPv4? |
|---|
| 480 | |
|---|
| 481 | ### Turn on IPv6 Routing |
|---|
| 482 | |
|---|
| 483 | Cisco IOS routers have IPv6 Routing turned off by default. So while we can reach |
|---|
| 484 | our directly attached neighbours, we cannot get anywhere beyond, nor can we turn |
|---|
| 485 | on any IPv6 routing protocols. We now need to turn on IPv6 routing, and to do |
|---|
| 486 | that we use the following command: |
|---|
| 487 | |
|---|
| 488 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 489 | ipv6 unicast-routing |
|---|
| 490 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 491 | |
|---|
| 492 | ### Static routes on the Core router |
|---|
| 493 | |
|---|
| 494 | The Core router needs a default route added to it so that we can forward traffic |
|---|
| 495 | from the Campus network to the wider Internet via the NREN. We add this route to |
|---|
| 496 | send traffic to the border router: |
|---|
| 497 | |
|---|
| 498 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 499 | ip route 0.0.0.0 0.0.0.0 100.68.X.1 |
|---|
| 500 | ipv6 route ::/0 2001:db8:X:0::1 |
|---|
| 501 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 502 | |
|---|
| 503 | ### Static routes on the Border router |
|---|
| 504 | |
|---|
| 505 | The Border needs a default route added to it so that we can forward traffic from |
|---|
| 506 | the Campus network to the wider Internet via the NREN. We add this route to send |
|---|
| 507 | traffic to the NREN router: |
|---|
| 508 | |
|---|
| 509 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 510 | ip route 0.0.0.0 0.0.0.0 100.68.0.Y |
|---|
| 511 | ipv6 route ::/0 2001:db8:0:X::0 |
|---|
| 512 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
|---|
| 513 | |
|---|
| 514 | Choose the correct value for **X** and **Y** from the IP address tables we used |
|---|
| 515 | when we set up the interface. |
|---|
| 516 | |
|---|
| 517 | **IMPORTANT: You have added a number of subnets on your core router and building |
|---|
| 518 | switches for the NMM subnet and VLAN 41, 42, 51, 52, 61, 62. Your Border router |
|---|
| 519 | needs to be able to send packets to those subnets.** |
|---|
| 520 | |
|---|
| 521 | Which networks should you add routes for? |
|---|
| 522 | |
|---|
| 523 | **HINT**: You need routes for all the IPv4 networks assigned to your Campus. See |
|---|
| 524 | the [IP Address Plan](<0.72_ip_address_plan.md>) for details. |
|---|
| 525 | |
|---|
| 526 | **Add these routes.** |
|---|
| 527 | |
|---|
| 528 | ### Testing the routing setup |
|---|
| 529 | |
|---|
| 530 | The two NREN routers are connected to the same workshop subnet as your laptops, |
|---|
| 531 | 10.10.0.0/24. They have the IPv4 addresses, 10.10.0.201 and 10.10.0.202. |
|---|
| 532 | |
|---|
| 533 | You should be able to ping these addresses from your Core router if your setup |
|---|
| 534 | is correct. You should also be able to ping your Core router from your laptop. |
|---|
| 535 | |
|---|
| 536 | Now try pinging 8.8.8.8 - does this work? |
|---|
| 537 | |
|---|
| 538 | *Checkpoint: call an instructor and show them your working system.* |
|---|