QOS / multiple subnet help

General discussion about Gargoyle, OpenWrt or anything else even remotely related to the project

Moderator: Moderators

Post Reply
gregger2k
Posts: 4
Joined: Sat Oct 09, 2010 9:25 pm

QOS / multiple subnet help

Post by gregger2k »

Hi all,
First let me describe what i am trying to accomplish. Our network consists of a Comcast DHCP cable modem internet connection with 16Mb down and 2Mb connected to a Dlink DWL-215 router with DD-WRT providing a NAT local network. This network is wirelessely PtoP bridged using 2 Dlink 2100 bridges to our remote site that hosts our VOIP server running Asterisk - IAX2 protocol (soon to be switched to FreePBX using SIP)
The problem is the wireless link runs about 2Mb up and 1.3Mb down. Thus the qos is needed for the wireless bridge much more than the wan.
I was thinking of splitting the network into 2 subnets and running Gargoyle on the remote router for QOS on the wireless bridge for the remote subnet. While I was testing the gargoyle software I could not find where to configure the router as a router not a bridge. I believe when set up as a bridge it will be doing double NAT, something I want to avoid. I tried disabling the firewall using the console but I was unsuccessful. Now for some questions:
Does what I am trying to do make sense?
Would Gargoyles QOS on the remote subnet manage the VOIP traffic priority over the wireless bridge?
What OpenWrt commands would I need to configure Gargoyle as a subnet router instead of a bridge, or to turn off NAT and the firewall?
If this works is there any chance of getting the configuration settings into the web interface? Managing bandwidth between subnets seems to be a common issue.

Any and all input will be greatly appreciated!!
Thanks in advance, Greg

pbix
Developer
Posts: 1373
Joined: Fri Aug 21, 2009 5:09 pm

Re: QOS / multiple subnet help

Post by pbix »

Your choices with Gargoyle are listed at the top of the connection->basic screen. Here you will select either "Gateway" or "Bridge/Repeater". If you select Gateway then Gargoyle will function as a router with DHCP, QoS and NAT support. You will then have a seperate subnet with the required double NAT. Not sure why this is a problem for you. You will have to setup static routes for your Asterisk server but I assume you can handle that.

If you select "Bridge/Repeater" Gargoyle will not provide DHCP and function only as a repeater meaning that your primary router is the DHCP server and there is no separate subnet and no NAT. In this mode I am not sure what QoS will do exactly. This needs to be tested. Good question though.

Now about the QoS and VoIP. In the router mode described above QoS can make sure that things which pass through the router are properly prioritized. Do other computers use the Wifi link? If so this is a problem with your idea in that other computers will be using the Wifi and this traffic goes directly to the router attached to the cable modem. So your Gargoyle router never sees it and cannot control it. If the Wifi is used only to link these two routers and all other connections are via LAN cables your idea can work.

So how about the phones? Are they wirelessly attached to the Asterisk server? This obviously would complicate things. Can you think of a way for Gargoyle to control all the traffic on the Wifi link? Perhaps 1 or more extra Gargoyle boxes should be added to provide a dedicated channel for this link.
Linksys WRT1900ACv2
Netgear WNDR3700v2
TP Link 1043ND v3
TP-Link TL-WDR3600 v1
Buffalo WZR-HP-G300NH2
WRT54G-TM

gregger2k
Posts: 4
Joined: Sat Oct 09, 2010 9:25 pm

Re: QOS / multiple subnet help

Post by gregger2k »

Thanks for the reply pbix.

I think I am trying to implement your last suggestion.
I will have 2 subnets, for example

192.168.0.x for the LAN on the router connected to the internet WAN using DHCP/NAT (not Gargoyle yet)

PtoP wireless bridge connected to the LAN 192.168.0.0 network switch on one end and the WAN port on the remote Gargoyle router on the other.

192.168.1.x LAN network on Gargoyle router with the PtpP bridge connected to the WAN port. This router will provide the QOS for the ptoP bridge.

The Gargoyle router needs to act as a regular subnet router without firewall/NAT and route all outbound traffic to the 192.168.0.0 gateway router. I need to configure a static route from 192.168.0.0 network to the 102.168.1.0 network.

All the traffic through the PtoP bridge will go through the Gargoyle router that should provide the QOS i need for VOIP.

I will probably install Gargoyle on the internet router for QOS of the clients on the 192.168.0.0 network but I am trying to get the remote subnet configured first.

What config file settings do I need to edit to configure Gargoyle to just route between the 192.168.0.0 and 192.168.1.1 networks without NAT and firewall?

In answer to pbix's questions:

The Cisco SIP phones are all on the remote 192.168.1.0 network along with the the Asterisk box so their traffic is local. With the 2 subnets as I described all WiFi bridge traffic should go through the remote Gargoyle QOS.

I will install Gargoyle on the internet router when I have another router that supports it. The internet router config should be straightforward and configurable by the GUI.

It looks like this configuration is not available through the GUI.
I am a noob at OprnWrt, this should probibly be easy :?

Thanks, Greg

pbix
Developer
Posts: 1373
Joined: Fri Aug 21, 2009 5:09 pm

Re: QOS / multiple subnet help

Post by pbix »

There is no way to disable NAT using the Gargoyle GUI.

There is a way to do this via command line scripts but you should get the system working first using the standard NATing method before you venture into such things. What is your concern about the double NAT?

How about explaining what you need of Wifi other than the PtoP link? If you need Wifi for other purposes what do you propose to be the access point(s)? Its possible that all this can be done without anymore hardware depending on your answer to this question.

Anyway using a dedicated PtoP link will allow QoS to control priorities and maintain your VoIP quality.

For what reason are you thinking to put Gargoyle on the main router?
Linksys WRT1900ACv2
Netgear WNDR3700v2
TP Link 1043ND v3
TP-Link TL-WDR3600 v1
Buffalo WZR-HP-G300NH2
WRT54G-TM

gregger2k
Posts: 4
Joined: Sat Oct 09, 2010 9:25 pm

Re: QOS / multiple subnet help

Post by gregger2k »

pbix,

I am concerned about double NAT because of the SIP VOIP connections. It is enough trouble with NAT, would double NAT be twice as much trouble? also why translate twice if not necessary.

the clients on both subnets are using the routers built in WiFi Ap's. Thus the separate PtoP bridge. The bridge link is about 1 mile using hi-gain antennas. If I could get the bridge speeds up I would not need the QOS for the link. Like I said, I am getting 2Mb up from the remote and 1.3Mb down. There are some trees partially blocking the link. I will try to reposition the antennas for better link speed and quality.

I want QOS on the main router to manage the internet connection speeds. Sometimes there are large transfers on the local subnet that can use all the internet bandwidth. The differences in link speeds is what can cause problems.

Thanks, Greg

pbix
Developer
Posts: 1373
Joined: Fri Aug 21, 2009 5:09 pm

Re: QOS / multiple subnet help

Post by pbix »

Greg,

A 1 mile PtoP link sounds way cool. Your setup makes sense given the situation.

Your question of why translate twice if not necessary? Well with Gargoyle it is necessary at the moment. The NATless router option might be a cool enhancement especially if you could come up with a script to make it work which we could incorporate into the GUI.

You said your comcast box is a DHCP server to your DWL-215 so it sounds like you already have double NAT.

So what are you doing now? Are you using a SIP proxy like Milkfish on DD-WRT? Some people use static routes with Asterisk because I understand you can confine the RTP ports to a certain range with it. If you have only one registration then Gargoyle works fine since it has some SIP code built in. For more than one you need a proper proxy. I have used siproxd on OpenWRT and it seems to work OK.

http://siproxd.sourceforge.net/siproxd_ ... _c7s5.html

I looked for the DLINK DWL-215 in the DD-WRT router database and did not see it. How much RAM does it have? Make sure you get one with 32Megs with the extras you probably will need.

You are wise to implement QoS and regardless of your link bandwidths. There is always a way to saturate a link regardless of how fast it is and that will cause your VoIP to suffer.

As a test you might try putting in all your static routes and then running the command '/etc/init.d/firewall stop' from the command line. At least until you do any other GUI change it might stop NATing for you. Just a guess though.
Linksys WRT1900ACv2
Netgear WNDR3700v2
TP Link 1043ND v3
TP-Link TL-WDR3600 v1
Buffalo WZR-HP-G300NH2
WRT54G-TM

gregger2k
Posts: 4
Joined: Sat Oct 09, 2010 9:25 pm

Re: QOS / multiple subnet help

Post by gregger2k »

pbix,

I think the Comcast box is acting like a bridge and the DHCP request is being passed on from the router to the Comcast network. I will check it though.

Currently our Asterisk box is using the IAX2 protocol that only uses 1 port (4569). I have the port forwarded to our asterisk box. I have asterisk configured for a NAT connection so it registers to our VOIP provider frequently enough to keep the NAT connection alive anyway.

I have been testing FreeSWITCH and I like it a lot. I especially like the fact that it can be compiled and run on a windoze box. ( blasphemy I know, but this is a business and everything else runs on windows. I am windows, not a Linux expert!) I might even try to run it on Openwrt ;) The issue there is that FreeSWITCH no longer supports the IAX2 protocol so I will have to use SIP. I am testing it now and SIP seems to work fine with FreeSWITCH registering frequently to keep the SIP channels open.

I misspoke on the Dlink. It is a DIR-615/E3 4MB flash, 32MB ram. It doesn't seem to be supported on Openwrt or Gargoyle currently though. Someone reported dunning DIR-600 firmware on it though and the internal board was even labeled DIR-600. I am not quite ready to brick it though.

I am testing Gargoyle on a Buffalo WZR-HP-G300NH WITH 32MB flash and 64MB ram so I am good there. I also have an Asus WL520GU but it is slower with less ram.

When I get back to my test environment I will try your suggestions with the static routes NAT not worry about the NAT for now.

Thanks for your suggestions, Greg

Post Reply