Why is the CPU internal port untagged in vlan#ports?

Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware
Author Message
KurianOfBorg
DD-WRT Novice


Joined: 04 Jul 2013
Posts: 6

PostPosted: Mon Jul 08, 2013 11:18    Post subject: Why is the CPU internal port untagged in vlan#ports? Reply with quote
Why is the CPU internal port not tagged in vlan#ports?

If I wanted to trunk vlan1 and vlan2 on physical port 4 I'd have to set:
Code:
vlan1ports = 4t ...
vlan2ports = 4t ...


However the CPU internal port on vlan1 & vlan2 is just:
Code:
vlan1ports = 8* ...
vlan2ports = 8 ...


Won't vlan2 packets also be sent untagged to the CPU?
Sponsor
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 10141

PostPosted: Tue Jul 09, 2013 22:39    Post subject: Reply with quote
Nope, the cpu port is special and always gets tagged even when you don't specify it. The /proc/switch interface doesn't work too well with newer switches but on older switches you could use it to cat the current config or echo new configs and it would show the cpu port always with a "t" behind it.

Btw since you have a rt-n16 any build over 17000 should have a working VLAN GUI. You should use the GUI whenever possible.

_________________
Read the forum announcements thoroughly! Be cautious if you're inexperienced.
Available for paid consulting. (Don't PM about complicated setups otherwise)
Looking for bricks and spare routers to expand my collection. (not interested in G spec models)
KurianOfBorg
DD-WRT Novice


Joined: 04 Jul 2013
Posts: 6

PostPosted: Wed Jul 10, 2013 4:11    Post subject: Reply with quote
phuzi0n wrote:
Nope, the cpu port is special and always gets tagged even when you don't specify it. The /proc/switch interface doesn't work too well with newer switches but on older switches you could use it to cat the current config or echo new configs and it would show the cpu port always with a "t" behind it.

Btw since you have a rt-n16 any build over 17000 should have a working VLAN GUI. You should use the GUI whenever possible.


The initial nvram settings shown by the GUI are for 100Mbps switches (vlan0ports instead of vlan1ports and port#vlans values reference vlan0 instead of vlan1). Changing anything in the GUI also sets only vlan0ports which is unused on the RT-N16.

I'm running dd-wrt.v24-21676_NEWD-2_K2.6_mini_RT-N16.trx.

I also noticed that trying to erase or blank out vlan0ports doesn't stick. It gets regenerated on boot.
mac913
DD-WRT Guru


Joined: 02 May 2008
Posts: 1848
Location: Canada

PostPosted: Wed Jul 10, 2013 13:12    Post subject: Reply with quote
I too was trying to get VLAN working through CLI and had problems.

Having builds +15500 (I think) give you working VLANs from the GUI and ignore the CLI for setup and status.

If you started using the CLI, do a factory default and use the GUI and don't use the CLI. This is what I have done and I have 5 working VLANs connecting to Switches supporting 802.1q VLAN Tagging with no issues.

_________________
Home Network on Telus 1Gb PureFibre - 10GbE Copper Backbone
2x R7800 - Gateway & WiFi & 3xWireGuard - DDWRT r53562 Std k4.9

Off Site 1

R7000 - Gateway & WiFi & WireGuard - DDWRT r54517 Std
E3000 - Station Bridge - DDWRT r49626 Mega K4.4

Off Site 2

R7000 - Gateway & WiFi - DDWRT r54517 Std
E2000 - Wired ISP IPTV PVR Blocker - DDWRT r35531


YAMon 3.4.6 | DNSCrypt-Proxy V2
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 10141

PostPosted: Wed Jul 10, 2013 21:56    Post subject: Reply with quote
KurianOfBorg wrote:
The initial nvram settings shown by the GUI are for 100Mbps switches (vlan0ports instead of vlan1ports and port#vlans values reference vlan0 instead of vlan1). Changing anything in the GUI also sets only vlan0ports which is unused on the RT-N16.

I'm running dd-wrt.v24-21676_NEWD-2_K2.6_mini_RT-N16.trx.

I also noticed that trying to erase or blank out vlan0ports doesn't stick. It gets regenerated on boot.

That doesn't sound right. On most (all?) gigabit switches the vlan0ports variable gets generated (because of sloppy code shared with 100mbps switches) and will get recreated if you try to outright delete it (due to sanity checks) but it should not be used or matter at all.

Darkshadow confirmed the default variables for the rt-n16 a long time ago and Eko fixed it in the GUI (pretty sure the last of the fixes were just before 17000). His results included a faulty vlan0ports variable and correct vlan1ports and vlan2ports variables as are expected: http://www.dd-wrt.com/phpBB2/viewtopic.php?p=479992&highlight=#479992

Hard reset, check the default variables, use the GUI to move LAN port 4 into VLAN 2 with the WAN port, apply, check the variables again, test if LAN port 4 or 1 are acting as a WAN port, reboot and check that the variables haven't changed again and the LAN port still acts as a WAN port. If this test fails then post the variables from each step.

_________________
Read the forum announcements thoroughly! Be cautious if you're inexperienced.
Available for paid consulting. (Don't PM about complicated setups otherwise)
Looking for bricks and spare routers to expand my collection. (not interested in G spec models)
Display posts from previous:    Page 1 of 1
Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum