Vlan/Switching Clarification Question

I have a vlan/subnet question that I need some clarification on (I thought I understood this, but maybe I don't).  Let's say I have three switches (Switch1 on the first floor of the building, Switch2 on the second floor of the building, and Switch3 on the third floor of the building).  Switch1 and Switch3 are going to be on the same vlan (Vlan 3) and these two switches are not directly connected.  They are both connected to Switch2.  I want Vlan 3 to use the 10.10.3.0 255.255.255.0 subnet.

My understanding is all three switches would need to know about Vlan 3.  My configuration on each switch would be:

Switch1> config t
Switch1# vlan 3
Switch1# interface vlan 3
Switch1(config-if)# ip address 10.10.3.0 255.255.255.0
Switch1(Config-if)# no shut
Switch1(config-if)# end
Switch1# Wr

Switch2> config t
Switch2# vlan 3
Switch2# interface vlan 3
Switch2(Config-if)# no shut
Switch2(config-if)# end
Switch2# Wr

Switch3> config t
Switch3# vlan 3
Switch3# interface vlan 3
Switch3(config-if)# ip address 10.10.3.0 255.255.255.0
Switch3(Config-if)# no shut
Switch3(config-if)# end
Switch3# Wr

Once the vlans have been defined on each switch, I just need to setup trunk ports between Switch1 and Switch2 and between Switch2 and Switch3.

Once this is done, I should be able to ping host3 (10.10.3.10) which is connected to Switch3 from host1 (10.10.3.5) which is connected to Switch1.

My questions are:
Are the following commands the correct way to associate a subnet with a vlan?
Switch1(config-if)# ip address 10.10.3.0 255.255.255.0
Switch3(config-if)# ip address 10.10.3.0 255.255.255.0

Do I need to do anything else on Switch2?

Sorry for asking such a basic question.  I don't have any switches to setup to test this on and I don't have Cisco Packet Tracer as I'm not in a Cisco Academy.

Thanks
LVL 1
ndalmolin_13Asked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Soulja53 6F 75 6C 6A 61 Commented:
Switch 1:

conf t
int vlan 3
ip address 10.10.3.5 255.255.255.0
no shut

switch 3:
int vlan 3
ip address 10.10.3.10 255.255.255.0
no shut
0
Sandeep GuptaConsultantCommented:
lot of wrong configs..


dont use IP 10.10.3.0 this is not valid

for your ease I am trying to help like this


host1 (10.10.3.5)---sw1(fa0/0)----(Fa0/0)-sw2-(fa0/1)--------(fa0/0)sw3--host3 (10.10.3.10)

now configure like this
now configure vlan 3 with ip address for each switch

and apply vlan 3 on trunk link between switches...

since you are using one vlan so you can also configure link as access.

cheers
0
Soulja53 6F 75 6C 6A 61 Commented:
interface vlan 3 is not needed on switch 2.

Switch 1 & 3
conf t
vlan 3
exit
int fax/x
switchport access vlan 3  (vlan interface won't come up unless you assign a port to the vlan)
exit
int fax/x  (trunk to switch 2)
switchport trunk encapsulation dot1q
switchport mode trunk

Switch 2
conf t
vlan 3
exit
int fax/x (trunk to switch 1)
switchport trunk encapsulation dot1q
switchport mode trunk

int fax/x (trunk to switch 3)
switchport trunk encapsulation dot1q
switchport mode trunk
0
Determine the Perfect Price for Your IT Services

Do you wonder if your IT business is truly profitable or if you should raise your prices? Learn how to calculate your overhead burden with our free interactive tool and use it to determine the right price for your IT services. Download your free eBook now!

Craig BeckCommented:
You don't need to apply IP addresses to any of the switches on VLAN3 if that VLAN is just going to be for user traffic.

The only IP address needed on the switches is a management IP address on whichever VLAN your management VLAN is.

All you need to do is create VLAN3 on each switch and ensure that the trunks between each switch allow VLAN3.

Done!
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
mikebernhardtCommented:
I would disagree with Craig in only one respect: You haven't mentioned whether there are other vlans which wil have to communicate with this one. If there are, then you might have to have an IP address on one of the switches to use as a default gateway for VLAN 3 users. this should be on the same switch that has the default gateway(s) for the other vlan(s).

If you are using some external router to route between multiple vlans then the above doesn't apply.
0
Craig BeckCommented:
@mikebernhardt: The OP didn't mention anything about routing so I didn't consider inter-VLAN routing as part of this solution.  Only VLANs were mentioned.

In any case there is no mention whether they are layer2 or layer3 switches so it's probably best to consider them as layer2 only.  Therefore a router would be required for routing between VLANs to be possible.
0
mikebernhardtCommented:
Agreed. I was just bringing that up in case there were other factors in his topology that he hadn't mentioned.
0
Soulja53 6F 75 6C 6A 61 Commented:
The whole point of me having him apply vlan 3 addresses on switch 1 and 3 is to test connectivity of vlan 3 between the switches.
0
Craig BeckCommented:
@soulja - But what if the switches are L2 only?  That means we can only apply one IP address to the switch at a time.  In that case the test is not possible unless you drop the management IP!
0
Soulja53 6F 75 6C 6A 61 Commented:
Exactly, he doesn't state whether vlan 3 is managment or not. My assumption is that it's management.  

Only so much you can do when so much info is not provided, so alot of answers will be based on assumptions.
0
Craig BeckCommented:
Well I was working on the 'assumption' that VLAN3 wouldn't be on all switches, therefore it was unlikely to be the management VLAN.
0
Soulja53 6F 75 6C 6A 61 Commented:
Well since the author mentions he wants the vlan on a certain subnet, doesn't mention an external router. Then attempts to create vlan interfaces, let's 'assume' all the switches are layer3. Hence my test would be valid. :)
0
Craig BeckCommented:
Or, we could assume that not everyone wants to be able to route between VLANs ;-)
0
ndalmolin_13Author Commented:
Thank you all for the input.  My apologies for not providing more information.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Switches / Hubs

From novice to tech pro — start learning today.