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 -192.168.5.2 n port 2 192.168.4.6 I want both server can access each other. what should I do ?

I have this problem too.
0 votes
  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 0 (0 ratings)
Loading.
ilnaiduccna Fri, 03/21/2008 - 00:02

Hi,

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.

Regards,

Naidu.

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

sunil

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 (255.255.254.0). While we traditionally think of these addresses as separate /24 class C addresses, the /23 would include both 192.168.4.0 and 192.168.5.0 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 192.168.4.1 255.255.255.0

ip address 192.168.5.1 255.255.255.0 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.

HTH

Rick

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 192.168.5.10

Gi0/3= server ip 192.168.4.10

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

Thot

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 192.168.5.20/27)

srv1:192.168.5.1 mask 255.255.255.224

srv2:192.168.5.10 mask 255.255.255.224

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

my server connected to vlan 8 (ip 192.168.4.5/24)

srv1:192.168.5.12 mask 255.255.255.224

srv2:192.168.5.13 mask 255.255.255.224

srv3:192.168.4.12/24

I want I can ping from server 192.168.5.10 to 192.168.5.13 & 192.168.4.13

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

sunil

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 192.168.5.10 to 192.168.5.13 & 192.168.4.13). 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.

HTH

Rick

Actions

This Discussion