Академический Документы
Профессиональный Документы
Культура Документы
Assumptions
During the remainder of this document were making the following assumptions:
You have installed VIRL on ESXi as per the install guide instructions; make sure your are using
one of the minimum supported versions:
o ESXi 5.1U2 (Build 1483097)
o ESXi 5.5U1 (Build 1623387)
o ESXi 6.0 (Build 2494585)
You have connected and configured your L3 switch or router to support your VIRL VLANs.
You have some understanding of basic routing.
You have access to your ESXi host and connected network devices.
http://virl-dev-innovate.cisco.com/client.php
Page 1
Steps
Step 1 Configure static IP address for the management interface of the VIRL VM (recommended)
Step 2 Follow the instructions outlined in Step 10 of the installation guide to configure the IP
address of each VLAN. We need at least three VLANs that will coincide with each
network (FLAT, FLAT1, SNAT). In this example we are configuring the VLANs as per the
attached diagram.
NOTE:
In this example the gateway for VLAN10 is configured to be 172.16.1.2 (interface VLAN10). Because of this,
we must update /etc/virl.ini to use this interface instead of the default 172.16.1.1 as illustrated here:
Step 3 Once you have finished and saved all changes to virl.ini ensure to continue the steps
to rehost and L2 kernel Patch the system. Note that there will be two reboots in order
to properly prepare the system.
Check Point
The virl.ini file should now reflect your physical network(s) in FLAT, FLAT1 and SNAT network
settings. Next, route statements in the physical router need to be configured. In this example, we are
using a Linksys WRT1900AC wireless router. Remember that route statements are written like this:
For destination network, the next hop is my next device on my network
Or
For any device in network 172.16.1.0/24, go to this device 172.16.50.4
This is what it looks like on the router. Note that your device may use different naming convention.
Page 2
NOTE:
In this example, the router does not have the capability to create VLANs and VLAN interfaces. Because of this,
we are using a Cisco Catalyst 3520 (see diagram) switch to create SVI2 / Interface VLANs. Since this switch
understands routing, we are able to send all used networks to its gateway, which here is a WRT1900AC.
You can perform the same function using a router or firewall that supports the creation of sub-interfaces.
The next step assumes you are connecting your ESXi host NIC to either a Layer 3 switch or a Cisco
Router / Firewall. (If you are using a Cisco router, proceed to step 5.)
Step 4 Connect and define VLAN interfaces (SVI) on your L3 switch
# conf t
# interface vlan 1
# ip address 172.16.50.4
# interface vlan10
# ip address 172.16.1.2 255.255.255.0
# interface vlan20
# ip address 172.16.2.2 255.255.255.0
# interface vlan30
# ip address 172.16.3.2 255.255.255.0
Step 5 Create sub-interfaces for your networks
# conf t
# interface gi x/x.1
# encap dot1q 1
# ip address 172.16.50.4
2
Page 3
Example
VIRL VM on VLAN 1 (172.16.50.12)
virl@virl:~$ ping 172.16.1.2
Pinging 172.16.1.2 with 32 bytes of data:
Reply from 172.16.1.2: bytes=32 time=2ms TTL=255
Reply from 172.16.1.2: bytes=32 time=2ms TTL=255
Reply from 172.16.1.2: bytes=32 time=2ms TTL=255
Reply from 172.16.1.2: bytes=32 time=2ms TTL=255
Ping statistics for 172.16.1.2:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 2ms, Maximum = 2ms, Average = 2ms
Page 4
Example traceroute
VIRL VM on VLAN 1 (172.16.50.55)
virl@virl:~$ traceroute n 172.16.1.2
traceroute to 172.16.1.2 (), 30 hops max, 60 byte packets
1 172.16.50.3 0.656 ms 0.609 ms 0.583 ms
2 172.16.50.4 0.505 ms 0.575 ms 0.633 ms
3 172.16.1.2 0.392 ms 0.417 ms 0.456 ms
NOTE:
If you are on Linux or Mac the command is traceroute n 172.16.1.2 The d and n options return
the numeric value of the hop rather than trying to resolve the name of the device. If you do not use the
command options then it can take a very long time to complete. This is especially true on Windows machines.
The Windows equivalent command is tracert -d
Step 9 Create topology in VM Maestro with the Management Network setting set to Private
Simulation Network and add a Flat Connector to each device you want to connect
TIP:
If you have multiple devices you can save time by configuring the default route before you run ANK. To do
this, select your node(s) > AutoNetKit > scroll down to Global under Custom Configuration. Enter default route
or any other command you wish to include (see illustration / screenshot on the following page).
Step 10 Click Build initial configurations button to configure each device in the simulation and
start your simulation when ready.
Page 5
Step 11 Once your simulation has started, each node connected to a Flat-x connector will be
configured with an interface into the Flat network and will receive an IP address. In this
example, this is our configured VLAN 10 of 172.16.1.0/24. As shown below, you should
be able to connect to any of those IP addresses.
Page 6
Step 12 You should now be able to connect to your physical network and the Internet. This is
especially helpful for customizing your server images. Once connected to your server
running in the simulation you can download packages as needed from Ubuntu repositories.
This facilitates when the simulation requires a web, mail or light SQL server. Of course,
you are not limited to these but you will be limited to available resources on the server
image.
Happy connecting!
Page 7
VLAN30
VLAN20
VLAN10
VMK0
NIC1
interface FastEthernet0/21
switchport trunk encapsulation dot1q
switchport trunk allowed vlan 10,20,30,40
switchport mode trunk
NIC2
VLAN1
VIRL VM
ESXi Host
eth4
Init.
vSwitch 1
eth3
eth2
eth1
eth0
SNAT
Flat1
Flat
vSwitch 0
L3 Switch
Interface vlan 01 IP: 172.16.50.4
Interface vlan 10 IP: 172.16.1.2
Interface vlan 20 IP: 172.16.2.2
Interface vlan 30 IP: 172.16.3.2
Default route 172.16.50.3
Router
IP: 172.16.50.3
Routes:
172.16.1.0/24 172.16.50.4
172.16.2.0/24 172.16.50.4
172.16.3.0/24 172.16.50.4
## l2 network
## l2_network format is address/cidr format x.x.x.x/x
## Default
l2_network: 172.16.1.0/24
l2_mask: 255.255.255.0
l2_network_gateway: 172.16.1.2
Page 8