12-18-2011 09:58 PM - edited 03-07-2019 03:57 AM
I have been looking into this for a while and I can't seem to figure out why my 2nd vlan is not able to connect properly to the net. I would be grateful if someone could take a look and advise on what Im doing wrong.
My switch has 12 ports where my devices connects directly, they are all on Vlan 1 and they all work perfectly.
on Port 12 I have a dlink router that is connected to a cable modem. the dlink router has an Ip address of 192.168.0.20
I created a second vlan (vlan2) and enabled dhcp relay on it. then I assigned port 9 on the switch to (vlan2)
my laptop which is connected to port 9 seems to get an ip address fine and able to ping only some devices on my network (vlan1) and is not able to go out to the internet. I think it has to do with the routes
vlan 1 is giving this default route : 0.0.0.0 0.0.0.0 192.168.0.20 192.168.0.52 10
vlan 2 is giving this one : 0.0.0.0 0.0.0.0 192.168.1.1 192.168.1.51 10
why is my default routes look different for the 2 Vlans (the underlined) ? any idea on why vlan1 works and not vlan2 ?
here is my switch's config :
!
! Last configuration change at 00:25:58 UTC Mon Dec 19 2011
! NVRAM config last updated at 00:19:57 UTC Mon Dec 19 2011
!
version 12.2
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname S3750
!
boot-start-marker
boot-end-marker
!
enable secret 5 $1$kGRQ$mNfjtNRp6moUunJOlRPX71
!
!
!
no aaa new-model
clock timezone UTC -5
switch 1 provision ws-c3750g-12s
system mtu routing 1500
ip routing
!
!
!
!
!
!
!
!
spanning-tree mode pvst
spanning-tree extend system-id
!
vlan internal allocation policy ascending
!
!
!
!
interface GigabitEthernet1/0/1
!
interface GigabitEthernet1/0/2
!
interface GigabitEthernet1/0/3
!
interface GigabitEthernet1/0/4
!
interface GigabitEthernet1/0/5
!
interface GigabitEthernet1/0/6
!
interface GigabitEthernet1/0/7
!
interface GigabitEthernet1/0/8
!
interface GigabitEthernet1/0/9
switchport access vlan 2
!
interface GigabitEthernet1/0/10
!
interface GigabitEthernet1/0/11
!
interface GigabitEthernet1/0/12
!
interface Vlan1
ip address 192.168.0.1 255.255.255.0
!
interface Vlan2
ip address 192.168.1.1 255.255.255.0
ip helper-address 192.168.0.3
!
ip default-gateway 192.168.0.20
ip classless
ip route 0.0.0.0 0.0.0.0 192.168.0.20
ip http server
ip http secure-server
!
!
ip sla enable reaction-alerts
!
snmp-server community public RO
snmp-server community private RW
snmp-server location Home
!
!
line con 0
password cisco
login
line vty 0 4
password cisco
login
line vty 5 15
login
!
end
Here is the routing table on Computer 1 ( on Vlan 1) :
===========================================================================
Interface List
12...1c 6f 65 c1 a3 d3 ......Realtek PCIe GBE Family Controller #2
11...1c 6f 65 c1 3c 72 ......Realtek PCIe GBE Family Controller
1...........................Software Loopback Interface 1
15...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter
14...00 00 00 00 00 00 00 e0 Teredo Tunneling Pseudo-Interface
===========================================================================
IPv4 Route Table
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.0.20 192.168.0.52 10
127.0.0.0 255.0.0.0 On-link 127.0.0.1 306
127.0.0.1 255.255.255.255 On-link 127.0.0.1 306
127.255.255.255 255.255.255.255 On-link 127.0.0.1 306
192.168.0.0 255.255.255.0 On-link 192.168.0.52 266
192.168.0.52 255.255.255.255 On-link 192.168.0.52 266
192.168.0.255 255.255.255.255 On-link 192.168.0.52 266
224.0.0.0 240.0.0.0 On-link 127.0.0.1 306
224.0.0.0 240.0.0.0 On-link 192.168.0.52 266
255.255.255.255 255.255.255.255 On-link 127.0.0.1 306
255.255.255.255 255.255.255.255 On-link 192.168.0.52 266
===========================================================================
Persistent Routes:
None
IPv6 Route Table
===========================================================================
Active Routes:
If Metric Network Destination Gateway
1 306 ::1/128 On-link
11 266 fe80::/64 On-link
11 266 fe80::e98d:c724:7ef5:244a/128
On-link
1 306 ff00::/8 On-link
11 266 ff00::/8 On-link
===========================================================================
Persistent Routes:
None
and here is the routes on the computer that is on Vlan 2
===========================================================================
Interface List
15...f0 de f1 47 be 71 ......Intel(R) 82577LM Gigabit Network Connection
14...00 27 10 49 c8 b8 ......Intel(R) Centrino(R) Advanced-N 6200 AGN
1...........................Software Loopback Interface 1
13...00 00 00 00 00 00 00 e0 Microsoft ISATAP Adapter
27...00 00 00 00 00 00 00 e0 Microsoft Teredo Tunneling Adapter
===========================================================================
IPv4 Route Table
===========================================================================
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 192.168.1.1 192.168.1.51 10
127.0.0.0 255.0.0.0 On-link 127.0.0.1 306
127.0.0.1 255.255.255.255 On-link 127.0.0.1 306
127.255.255.255 255.255.255.255 On-link 127.0.0.1 306
192.168.1.0 255.255.255.0 On-link 192.168.1.51 266
192.168.1.51 255.255.255.255 On-link 192.168.1.51 266
192.168.1.255 255.255.255.255 On-link 192.168.1.51 266
224.0.0.0 240.0.0.0 On-link 127.0.0.1 306
224.0.0.0 240.0.0.0 On-link 192.168.1.51 266
255.255.255.255 255.255.255.255 On-link 127.0.0.1 306
255.255.255.255 255.255.255.255 On-link 192.168.1.51 266
===========================================================================
Persistent Routes:
None
IPv6 Route Table
===========================================================================
Active Routes:
If Metric Network Destination Gateway
1 306 ::1/128 On-link
1 306 ff00::/8 On-link
===========================================================================
Persistent Routes:
None
thank you for your time
12-18-2011 10:48 PM
Hi,
Change the default gateway address to the IP address of the dlink router.
Regards,
Smitesh
12-19-2011 06:36 PM
you have ip routing enabled, so you don't need this L2 command line
ip default-gateway 192.168.0.20
type this:
no ip default-gateway 192.168.0.20
12-20-2011 02:45 AM
Hi,
1)You should put the DHCP server on your 3750:
eg
ip dhcp excluded-address 192.168.0.1
ip dhcp excluded-address 192.168.1.1
ip dhcp pool LAN1
network 192.168.0.0 255.255.255.0
default-router 192.168.0.1
dns-server 8.8.8.8
ip dhcp pool LAN2
network 192.168.1.0 255.255.255.0
default-router 192.168.1.1
dns-server 8.8.8.8
2)Make the port going to the Dlink as a routed port:
int g1/0/12
no switchport
ip address 192.168.3.1 255.255.255.0
on the Dlink change the IP to 192.168.3.20
3) change your default route on 3750:
no ip route 0.0.0.0 0.0.0.0 192.168.0.20
ip route 0.0.0.0 0.0.0.0 192.168.3.20
4) remove the dhcp relay from the SVI:
int vlan 2
no ip helper-address 192.168.0.3
5) remove the DHCP service from the 192.168.0.3 interface
Regards.
Alain
12-20-2011 09:22 PM
I was able to get it to work by adding a route on my dlink to recognize the secondart (Vlan 2) (subnet 192.168.1.0)
Im using 2 windows server boxes ( 2003 and 2008 ) running DHCP/DNS/AD/IIS/Exchange 2010 I'm perefer keeping things running on my windows boxes.
I also rather keep the routing between the 2 subnets happening on the L3 switch. the DLink is a cheap router (DIR655) that doesnt even support routing between LAN subnets, I had to hack the config to get that part to work.
thank you all for your suggestions.
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: