Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. And see here for current known issues.

New Member

Setting up Routing and Vlans

Hi Guys,

I am trying to configure my lab with Vlans and access to the internet VIA my Virgin Media router.  I have had this working but while messing around i have broken it.  Can anyone give me a hint as to how?  Below is my router configuration.  My laptop is connected to a switch and is pulling 192.168.10.1/24 via DHCP  Thanks

Current configuration : 1681 bytes

!

version 12.4

service timestamps debug datetime msec

service timestamps log datetime msec

no service password-encryption

!

hostname CBTRouter

!

boot-start-marker

boot-end-marker

!

enable secret 5 $1$XtrM$gDxcY6FRQ3LQWGfY./E4K.

!

no aaa new-model

no network-clock-participate slot 1

no network-clock-participate wic 0

ip cef

!

!

no ip dhcp use vrf connected

ip dhcp excluded-address 192.168.0.50

ip dhcp excluded-address 192.168.10.50

!

ip dhcp pool dpool1

   import all

   network 192.168.10.0 255.255.255.0

   default-router 192.168.10.50

!

!

no ip domain lookup

ip domain name CBTRouter.com

ip name-server 8.8.8.8

ip name-server 8.8.4.4

interface FastEthernet0/0

no ip address

ip virtual-reassembly

duplex auto

speed auto

!

interface FastEthernet0/0.10

description VLAN10 LEFT

encapsulation dot1Q 10

ip address 192.168.10.50 255.255.255.0

ip nat inside

ip virtual-reassembly

!

interface FastEthernet0/0.20

description VLAN21 RIGHT

encapsulation dot1Q 20

ip address 192.168.20.50 255.255.255.0

!

interface Serial0/0

no ip address

shutdown

!

interface FastEthernet0/1

ip address dhcp

ip nat outside

ip virtual-reassembly

duplex auto

speed auto

!

ip route 192.168.10.0 255.255.255.0 FastEthernet0/1

!

!

no ip http server

no ip http secure-server

ip nat pool no-overload 192.168.0.100 192.168.0.150 prefix-length 24

ip nat inside source list 7 pool no-overload

!

access-list 7 permit 192.168.10.0 0.0.0.255

!

!

control-plane

!

!

banner motd ^CC

My router. Keep out.^C

!

line con 0

exec-timeout 0 0

password cisco

logging synchronous

login

line aux 0

line vty 0 4

password cisco

login

!

!

end

7 REPLIES
Silver

Setting up Routing and Vlans

Why are you doing NAT on this device? Just to test?

Did your router receive an IP via DHCP and also a default route? Check that fa0/1 has an IP and that you have a default route with show ip route.

Daniel Dib
CCIE #37149

Daniel Dib CCIE #37149 Please rate helpful posts.
New Member

Setting up Routing and Vlans

Yes i am just testing really. 

FastEthernet0/1    192.168.0.7    YES DHCP   up   up

Gateway of last resort is 192.168.0.1 to network 0.0.0.0

C    192.168.10.0/24 is directly connected, FastEthernet0/0.10

C    192.168.20.0/24 is directly connected, FastEthernet0/0.20

C    192.168.0.0/24 is directly connected, FastEthernet0/1

S*   0.0.0.0/0 [254/0] via 192.168.0.1

I dont understand the static route in there. Where did that come from?  The 192.168.0.1 is my virgin media router but the only config i entered is:

ip route 192.168.10.0 255.255.255.0 FastEthernet0/1

Thanks

Patrick

Silver

Setting up Routing and Vlans

The "static" default route came from DHCP.

Is the Virgin router setup to do NAT for the 192.168.10.0/24 network? Does it have a route back for this network? What was the last change that you did?

Why did you put this route in:

ip route 192.168.10.0 255.255.255.0 FastEthernet0/1

That network is local to the router.

Daniel Dib
CCIE #37149

Daniel Dib CCIE #37149 Please rate helpful posts.
New Member

Re:Setting up Routing and Vlans

The last changes i made was creating the Vlans etc.  From the router I can ping out to the internet and i can also ping in to my laptop.

The Virgin is just a standard VM superhub made by Netgear i think.   I have made no changes to that at all. 

ip route 192.168.10.0 255.255.255.0 FastEthernet0/1- I am confused with this.  I though that this command should mean that anything from the .10 network should leave on F0/1.  Should i remove this?

Thanks for your assistance.

Patrick

Purple

Setting up Routing and Vlans

Hi,

ip route 192.168.10.0 255.255.255.0 FastEthernet0/1- I am confused with  this.  I though that this command should mean that anything from the .10  network should leave on F0/1.  Should i remove this?

No, it means that anything destined for 192.168.10.0/24 is located out fa0/1.

It is not necessary because this 192.168.10.0/24 is already directly connected as an IP address in this network was configured on f0/0.10. As the AD of connected interface iz zero and AD of static route is 1, this static route will never be installed in the routing table.

Regards.

Alain

Don't forget to rate helpful posts.

Don't forget to rate helpful posts.
New Member

Re:Setting up Routing and Vlans

I see there is a 1 problem with vlan 21 and encapsulation is dot1q 20. A little mistake.

Sent from Cisco Technical Support Android App

New Member

Re:Setting up Routing and Vlans

Well spotted.  I have checked this over and it was just the description that was incorrect so i have changed that. 

Thanks

Patrick

631
Views
0
Helpful
7
Replies
CreatePlease login to create content