We help IT Professionals succeed at work.

SonicWall, Route certain IPs to different Interfaces

Maximus54
Maximus54 asked
on
I have a PRO4100 SonicWall Firewall with SonicOS enhanced firmware 4.2 that I have finished configuring but I wanted to do one more thing to it before I deployed it. I wanted to route all outbound traffic of our servers with IP Addresses 192.168.1.2 through 192.168.1.20 to go out of one interface and route all of the Client computers with IP address range 192.168.1.21 through 192.168.0.254 to go though another interface. I have the DHCP server configured on my domain controller internally. I  know I can configure more than 1 WAN interface on the SonicWALL but how do I configure it so that one group of IP addresses IS routed through one interface while others go through another one. Thanks in advance.
Comment
Watch Question

Top Expert 2010
Commented:
You don't have to change anything on your DHCP server.  What you want to do is setup a static route on the 4100.  Configure a new address group and configure it to be a range.  Include the LAN IP addresses that you want to use the secondary gateway.  If you want everything else to use the primary gateway, then there's nothing left to do.  Of course, if you haven't created your secondary gateway, then you'll want to do that first.

Author

Commented:
Thanks Digitap, I will configure it this way once I get a chance. Points to you.

Author

Commented:
One quick question, when you say setup a static route, do you mean NAT or ARP?
Top Expert 2010

Commented:
No, just static route.  Go to Networking > Routing and add the route there.
Top Expert 2010

Commented:
oh, and thinks for the points!

Author

Commented:
I had more questions digitap. You already told me to setup a static route which I have never done before and to also setup a secondary gateway, my question is

1) Should I Configure a second WAN or LAN for the secondary gateway(I believe you meant configure WAN2 right since I want all of my internal PCs to use ONE private gateway ).

2) When you say configure a second route, can you describe the static route creation process. For example if I wanted to route IP addresses 10.10.10.2 - 10.10.10.50 through Gateway 1 and the rest through gateway 2. Thanks in advance.

Author

Commented:
Never mind I think I got it
Top Expert 2010

Commented:
yes, something similar to wan2.  you can name the zone whatever you want.

if you creat a secondary gateway on your sonicwall, the sonicwall will setup default routes.  you'll want to create a route specifying those hosts you want to use the secondary gateway.  also, you'll want to set the priority above the others.

Author

Commented:
Thanks again Digitap
Top Expert 2010

Commented:
sure, no problem.

Author

Commented:
So Digitap, I setup 2 routes like you told me to but it is not working . Here is what I did
I created a new zone called WAN2, linked an Interface with the WAN2 zone and I gave it a public IP address. I then created 2 different address groups, configured both as ranges of LAN ip addresses, and then configured each range of IP addresses to go out through 2 different Interfaces. After I hooked everything up, everything is still going out the first default gateway. Therefore am I missing a step. Since there is no link on WAN2, am I supposed to configure that differently. The 2 gateways have been configured on the Cisco router, the firewall is just supposed to indicate which IP addresses go out on which internet gateway.
Top Expert 2010

Commented:
If there isn't a link on WAN2, then I'm not sure if the sonicwall will honor the route you setup.  It should have a link.

Author

Commented:
Yeah I thought so too which is why I wanted to mention it. Right now it is setup on the PIX router to only allow one range of IP addresses to go through one Gateway. I read through the whole Cisco  PIX code and I did not find any indication or configuration of the second gateway. You have one range of IP addresses configured to go out one gateway but the rest are not even configured nor specified to go through any other gateway. The only indication of the second gateway that I saw was on the Cisco router and not on the PIX firewall.
Maybe if I just configure the Sonicwall to only allow one range of IP addresses to go through one gateway, well maybe the others will be routed through the other gateway since they are not identified to go through any specific gateway.
Top Expert 2010

Commented:
Did you make sure the static route you made comes BEFORE the default gateway route?  you can move them up in the list.