1

I have set up a Router on a stick configuration with a Cisco 1841 router, a Cisco 2960 switch, and ESXi server. I am new to this concept and looking for some clarifications. Here is my set up:

Router:

f0/0 : no ip addrr   (?? is this correct)
f0/0.1 : native vlan 1 - 10.0.0.1/24
f0/0.2 : vlan 2 - 10.0.2.2/24

DHCP pool is configured for 10.0.0.1 and 10.0.2.2 networks

NAT is configured for 10.0.0.1/24 and 10.0.2.2/24 networks

Switch:

One trunk port to Router

Another trunk port to ESXi

ESXi:

A virtual machine group with "All VLANS"

The problem I have is that when I connect a VM to the "ALL VLANS" portgroup, I am not able to configure the network. I have the same problem when I create a port group with VLAN1 in ESXi and connect a VM.

But it works fine for a port group with vlan 2.

The reason I am connecting trunk port to a VM is that I am installing a software called packetfence which needs a trunk cable plugged into the interface.

Is there anything that I am doing wrong?

3
  • You have assigned two interfaces to same subnet: "f0/0.1 : native vlan 1 - 10.0.0.1/24 f0/0.2 : vlan 2 - 10.0.0.2/24 " and "NAT configured for 10.0.0.1/24 and 10.0.0.2/24 networks" are same network. Feb 15, 2017 at 14:22
  • That was a mistake, i corrected it
    – Sridhar
    Feb 15, 2017 at 14:24
  • Did any answer help you? If so, you should accept the answer so that the question doesn't keep popping up forever, looking for an answer. Alternatively, you could provide and accept your own answer.
    – Ron Maupin
    Aug 14, 2017 at 21:32

2 Answers 2

1

Simple configuration would like this

Router

interface FastEthernet 0/0
no shutdown


interface FastEthernet 0/0.1
encapsulation dot1Q 1 native
ip address 10.0.0.1 255.255.255.0


interface FastEthernet 0/0.2
encapsulation dot1Q 2
ip address 10.0.2.1 255.255.255.0

Switch

interface  [UPLINK_INTERFACE]
description TO_ROUTER
switchport trunk encapsulation dot1Q
switchport mode trunk
switchport trunk native vlan 1
switchport nonegotiate
switchport trunk allowed vlan 1,2

interface [Interface_TO_VMWARE1]
no ip address
switchport trunk encapsulation dot1q
switchport trunk allowed vlan 1,2
switchport mode trunk
switchport nonegotiate
spanning-tree portfast
2
  • I only have one physical port into ESXi server, What are Interface_TO_VMWARE1 and Interface_TO_VMWARE2 going to be? What is a Port-Channel1
    – Sridhar
    Feb 15, 2017 at 15:13
  • You have mention portgroup in yours comment so I assumed you are ussing port channel, edited Feb 15, 2017 at 15:17
1

Additionally, on your ESXi host with a standard vSwitch, you shouldn't be using an "all VLANs" port group. Add a port group to your vSwitch for each VLAN that you want to use. Connect a vNIC from each VM to the port group according to what VLAN you want it connected to.

The "All VLANs" port group receives frames from all VLANs but frames sent out are not tagged, so they all go to the physical switches untagged (default) VLAN. I've only ever used it for packet capturing into a VM (together with promiscuous mode).

Not the answer you're looking for? Browse other questions tagged or ask your own question.