Switched Ports

From DD-WRT Wiki

Revision as of 19:23, 7 December 2005 by Rammstein (Talk | contribs)
Jump to: navigation, search

With an older router, you can make for instance ports 3 and 4 to reside outside the router's NAT. Devices attached to these ports will request an own IP address from the ISP instead of getting a private IP address from your WRT. One might want to have such behaviour when having unsorted firewall issues with a SIP operator.

nvram set vlan0ports="1 2 5*" 
nvram set vlan1ports="0 3 4 5" 
nvram commit 
reboot 

According to the user reports, this is confirmed to work at least with a WRT54GSv1.1 after power cycling the router.

If you want to recover the default settings, write the following within ssh session:

nvram set vlan0ports="1 2 3 4 5*" 
nvram set vlan1ports="0 5" 
nvram commit 
reboot

The Port Numbering Explained

The numbers mean the following:

0  = WAN
1  = port 1
2  = port 2
3  = port 3
4  = port 4
5  = WLAN
5* = WLAN tagged

The variable vlan0ports equals to the natted LAN side. Correnpondently vlan1ports refers to the WAN side, outside the router's internat NAT addressing.