NETGEAR is aware of a growing number of phone and online scams. To learn how to stay safe click here.
Forum Discussion
ghost974
Aug 16, 2017Aspirant
Static route on S3300
I have a 2 datacenters composed of a Load balancer and a switch. Each location has it own internet connection/ gateway. I have a LANX connection between both location to stack my S3300. Servers on ...
Hopchen
Aug 16, 2017Prodigy
Hi,
The problem is that you can create all the static routes you want on the switch-stack, but it won't matter as the servers will never send traffic to the switches, for routing purposes. The servers will use their default gateway - the LBs.
You have two choices here:
1. Change the routing design and let the switch-stack do the routing internally (servers will have the switch-stack as default gateway). That would fix this, but you would have an issue with the two LB gateways after the switch-stack. This model switch can't do more than one default gateway in its routing table. You would need something like policy based routing on the switch-stack. So, this option is probably not good for you.
2. Don't add any routes on the switch-stack, but instead simply add IP addresses to the VLAN interfaces on your switch-stack (I assume you have two VLANs based on the diagram?). Then do static routes on the servers instead.
Example
VLAN 3 Overview:
Subnet: 192.168.3.x
Server 1: 192.168.3.10
Server 2: 192.168.3.20
VLAN 3 IP address on the switch-stack: 192.168.3.254 (could be any IP in the subnet not, already in use)
Gateway: 192.168.3.1/192.168.3.2 (The LBs)
VLAN 6 Overview:
Subnet: 192.168.6.x
Server 1: 192.168.6.10
Server 2: 192.168.6.20
VLAN 6 IP address on the switch-stack: 192.168.6.254 (could be any IP in the subnet, not already in use)
Gateway: 192.168.6.1/192.168.6.2 (The LBs)
On the servers in VLAN 3 you simply add a static routes to the subnet of VLAN 6.
Destination Network: 192.168.6.0
Subnet mask: 255.255.255.0
Gateway/next hop: 192.168.3.254 (switch-stack VLAN 3 IP address)
Same story for the servers in VLAN 6. On those servers you just add a static route to the VLAN 3 subnet.
Destination Network: 192.168.3.0
Subnet mask: 255.255.255.0
Gateway/next hop: 192.168.6.254 (switch-stack VLAN 6 IP address)
This way the switch-stack would do routing for the servers, when they want to communicate internally. And for everything else (Internet, etc.), the servers will go to they default gateway (the LBs). That will work fine. Remember, you would need to make sure routing is also enabled on the switch-stack: "Routing" --> "IP" --> Enable "Routing Mode".
I hope that clarifies it for you. Else let me know.
Cheers
- ghost974Aug 16, 2017Aspirant
Hi Hopchen, thx for the reply. I do understand the solution where my server will have the switch are their gateway for internal routing.
The switch-stack is seen as only 1 equipement, so just 1 default gateway. Do I configure gateway in Route > Routing Table > Configure Route > DefaultRoute ?
How would the switch know that traffic from servers 3.10 will go to 3.1, or 3.20 will go to 3.2 ?
- HopchenAug 16, 2017Prodigy
Hi,
I assume you are referring to my suggestion number 2? In that case, I have answered your questions below.
"Do I configure gateway in Route > Routing Table > Configure Route > DefaultRoute"
No need to do any additional routes on the switch-stack essentially. The switch-stack will have two routing duties. Route traffic from the 192.168.3.x network to the 192.168.6.x network and vice versa. You will create VLAN interfaces in each VLAN (3 and 6) to accomplish this. You don't need to make routes to tell the switch-stack where networks 192.168.3.x and 192.168.6.x are. The switch-stack knows already. It has interfaces in those networks :)"How would the switch-stack know that traffic from servers 3.10 will go to 3.1, or 3.20 will go to 3.2?"
That is not how it would work :). The end solution would work like this:
- If server in VLAN/network 3 or 6 wants to communicate with a server in the other network, then the request is sent to the switch-stack (defined by the static routes you created on those servers). The packet is routed to the other VLAN/network solely by the switch-stack. Your LBs will never see that traffic.
- If a server in VLAN/network 3 or 6 wants to communicate with anything else (Internet, etc.) the request is sent to the server's default gateway, which will be the LBs. The switch-stack is not involved here at all, from a routing point of view.
Let me know if anything is unclear.
Cheers- ghost974Aug 17, 2017Aspirant
Ok I understand. I have configured VLANs, and an IP in each VLAN. I have no tag configured on my load balancer so I untagged all port.
Only 1 VLAN seems to works, I can't reach it with the other IP.
I'd like to not use the VLAN tagging as it requires changes on the load balancer too.
(vlan6 is now vlan4)
Related Content
NETGEAR Academy

Boost your skills with the Netgear Academy - Get trained, certified and stay ahead with the latest Netgear technology!
Join Us!