switch with 2 diff ip

Unanswered Question
Mar 20th, 2008

Hi, I have a switch 3560 ios, issue is under vlan2 two server are connected with diff. series network say on port 1 - n port 2 I want both server can access each other. what should I do ?

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
ilnaiduccna Fri, 03/21/2008 - 00:02


Your query is not clear can you clear about it.

If i understood your question correctly, as you said you have one switch i.e., 3560 under vlan 2 and two servers connected in 1 & 2 switch ports then deffnitely they should communicate with each other when there is inter vlan routing.

If the two ports in different vlans? if yes you have to do inter vlan routing.



Richard Burts Fri, 03/21/2008 - 04:16


Michael asks a good question to clarify how the servers are configured. And the answer to this may direct which is the better solution on the switch. I believe that there are at least 2 alternatives which could work:

- configure the VLAN 2 interface with a subnet mask of /23 ( While we traditionally think of these addresses as separate /24 class C addresses, the /23 would include both and in 1 big subnet (which some people would refer to as a supernet).

- configure the VLAN 2 interface using secondary addressing. For example you might do something like this:

interface vlan 2

ip address

ip address secondary

this would allow the logically separate subnets/networks to exist within the same VLAN and allow the servers to communicate with each other. (Note that in this solution, depending on how the servers react, the servers may send the traffic to the switch to be relayed instead of sending directly to each other since they may believe that the other server is in a "remote" network and want to use their default gateway. The switch will send an ICMP redirect and if the switches honor the redirect they will communicate directly and if not they will continue to relay through the switch. The good news is that in either situation the servers will communicate.)

Is there a particular reason why the servers with such different addresses are put into the same VLAN instead of being put into separate VLANs? It would seem that separate VLANs would be a more simple solution.



blue4ciscome Mon, 03/24/2008 - 00:48

Thanx all u guys, Pls. solve my ground query first.

Two server conencted in vlan8 but with different ip address: see below

Gi0/2= server ip

Gi0/3= server ip

would above communicate with each other ?

but when i ping each other no thr is response.

thotsaphon Mon, 03/24/2008 - 01:25

Hi sunil,

Why don't you use separated vlans? To make sure that you've correctly configured ip addresses ,subnet mask and ip default-gateway of each server.Can the server ping its ip default-gateway? Can the server ping another ip default-gateway? Have you enabled an ip routing command at configuration mode?

Hopes this helps


blue4ciscome Mon, 03/24/2008 - 03:01

let me explain you my problem broadly.

I have two switches cisco ios 3560. I want to connect both switch together since same subnet server are connected to both switch.

1st switch:total vlans 3(1,2 & 8)

my server connected to vlan 8 (ip

srv1: mask

srv2: mask

2nd switch :total vlans 3(1,2 & 8)

my server connected to vlan 8 (ip

srv1: mask

srv2: mask


I want I can ping from server to &

now questions:

do i need trunk with cross cable if yes then guide me how both side.

Richard Burts Mon, 03/24/2008 - 05:09


There are inconsistencies in your question as this thread has developed. In the original post there was a single VLAN and one set of addresses. Now there are 3 VLANs and a different set of addresses. Please use a consistent question. If the situation changes or you need to ask a different question it would be better to begin a new post so that we can know clearly what question we are dealing with.

In my previous post I identified 2 alternatives that would allow the access you are now asking about (server to & From what you have posted I still believe that either the /23 mask on the VLAN interface or the use of secondary addressing would provide what you need.




This Discussion