VLAN ID settings for Singnet Fibre Broadband [SOLVED]

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


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Thu Mar 03, 2011 15:07    Post subject: VLAN ID settings for Singnet Fibre Broadband [SOLVED] Reply with quote
I'm interested to know if anyone had successfully used DD-WRT firmware to set the VLAN ID 10, 20, 30 & 40 on the WAN/LAN side of the router for Singnet Fibre Broadband users in Singapore.

I'm using the Linksys WRT320N (converted to E2000). I've tried to follow the switched ports wiki at http://www.dd-wrt.com/wiki/index.php/VLAN_Bridging_WAN_and_a_LAN_port#Second_WAN_port but still couldn't get it right.

If someone had successfully configured this on their router, please post your experiences. Hopefully with some snap shots of your settings.

Thanks.


Last edited by scorp588 on Mon Apr 09, 2012 5:12; edited 2 times in total
Sponsor
phuzi0n
DD-WRT Guru


Joined: 10 Oct 2006
Posts: 10141

PostPosted: Thu Mar 03, 2011 19:35    Post subject: Reply with quote
Well you overlooked the part of that page that tells you that only VLAN's 1-15 are usable. There is a patched kernel module that enables more VLAN's but it requires a lot of knowledge to use and hasn't been tested much.

http://www.dd-wrt.com/phpBB2/viewtopic.php?t=86919

_________________
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)
scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Mon Mar 07, 2011 15:38    Post subject: Reply with quote
phuzi0n wrote:
Well you overlooked the part of that page that tells you that only VLAN's 1-15 are usable. There is a patched kernel module that enables more VLAN's but it requires a lot of knowledge to use and hasn't been tested much.

http://www.dd-wrt.com/phpBB2/viewtopic.php?t=86919


Hi phuzi0n,

I've picked up some tips form the above link and try several commands to get the VLAN ID 10 to work. Unfortunately it still doesn't get thru. I've telnet some commands to see if the WAN port get tagged. I've attached a file here. Could you please take a look at the file and advice if I have done something wrong.

Here is the command lines that I've used for activating the robo switch.

rmmod switch-robo
insmod /jffs/switch-robo.ko
echo "0t 3 8" >/proc/switch/eth0/vlan/10/ports
echo "0t 8" >/proc/switch/eth0/vlan/20/ports
echo "0* 8" >/proc/switch/eth0/vlan/2/ports
vconfig add eth0 10
ifconfig vlan10 up
vconfig add eth0 20
ifconfig vlan20 up
nvram set wan_ifname=eth0.10
startservice wan



Data dump.doc
 Description:

Download
 Filename:  Data dump.doc
 Filesize:  37 KB
 Downloaded:  919 Time(s)

weitjong
DD-WRT Novice


Joined: 05 Apr 2012
Posts: 3
Location: 新加坡 Singapore

PostPosted: Thu Apr 05, 2012 17:56    Post subject: Reply with quote
I just upgraded to Singtel Fibre Optic last week and happen to own a WRT610N. I had a similar issue with the original poster where I need to figure how to configure WRT610 to work with VLANs. After numerous try and error, I finally got it working with the stocked dd-wrt firmware. I thought I should share it here as my first post in the forum.

Although the dd-wrt limits to the first 15 VLANs as written by phuzi0n, the limit does not bother me because I only subscribe to the Internet service (VLAN ID 10) and not the IPTV (VID 20) & VOIP (VID 30). If I were, I would probably use the modified switch-robo.ko kernel module compiled by tangsoft or cron2.

Anyway, here is the two steps to setup the VLAN.
1. In the VLANs tab, tagged the WAN port and then select VLAN10 and unselect VLAN2 (for my case). Apply setting and wait for a while.
2. In the Networking tab, assign VLAN10 as the VLAN for WAN. (If you don't see VLAN10 in the drop down list, it means you have not wait long enough in step 1. Cycle to other tab first and come back to check again). Apply setting. See attachment below.

My WAN connection type is set to "Automatic Configuration - DHCP". After applying the setting in step 2, the VLAN10 interface is up, WAN IP is assigned automatically from Singtel ISP. At this point, the internet surfing is possible.

Unfortunately, I believe there is a bug in the firmware. VLAN assignment setting for WAN does not survive the power cycle. It always reverts back to VLAN2 for my case. To me, this looks like the same bug reported in this post: http://www.dd-wrt.com/phpBB2/viewtopic.php?t=56868
If it is true, this bug is not fixed since then until today. I have tried the latest BS build (b18777) and I believe I am observing the same problem. I hope the Gurus here agree it is a bug and have it fixed soon. I don't have enough karma to fix it myself Very Happy.

All is not lost though as I figure out another way to workaround the problem. Here is my workaround, YMMV.

1. Enable the JFFS2 support.
2. Telnet/ssh into router and execute these commands:

Code:
mkdir -p /jffs/etc/config
echo '#!/bin/ash
PATH="/sbin:/usr/sbin:/bin:/usr/bin:${PATH}"
nvram set wan_iface=vlan10
nvram set wan_ifname2=vlan10
nvram set wan_ifname=vlan10
nvram set wan_ifnames=vlan10
nvram commit
startstop wan
ifconfig vlan2 down' >/jffs/etc/config/vlan10.startup
chmod 750 /jffs/etc/config/vlan10.startup


Above commands generate a folder containing new startup script that runs every time the router reboots. It basically reassigns the vlan10 as the VLAN for the WAN and restart the WAN service.

BTW, for those out there that still uses the old firmware builds that do not have the working webGUI for VLAN setup, you may want to try below instead to setup the VLANs via command line.

Code:
nvram set port0vlans="10 16"
nvram set port5vlans="1 10 16"
nvram set new_vlan2ports=
nvram set new_vlan2hwname=
nvram set vlan10ports="0t 8"
nvram set vlan10hwname=et0
nvram commit


I hope this help someone else with similar requirement. I also hope I am not too late for the original poster Smile.



VLAN10forWAN.png
 Description:
 Filesize:  49.71 KB
 Viewed:  30360 Time(s)

VLAN10forWAN.png


scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Sat Apr 07, 2012 2:49    Post subject: Reply with quote
This is Cool. Will give it a try when time permits. Thanks Pal!
scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Sat Apr 07, 2012 14:09    Post subject: Reply with quote
Hi weitjong,

I've tried your method and I've managed to get the WAN IP from Singtel ISP. As you have metioned, after rebooting, the WAN Port Assignment switches back to vlan2.

Next step, I Enabled the JFFS2 support and Telnet. However, after rebooting, the WAN Port Assignment switches back to vlan2 again. I'm not sure what has gone wrong. I've taken a snapshot of what I have done in the picture below. Hope to hear for a viable solution. Thanks.



Telnet1.png
 Description:
 Filesize:  169.59 KB
 Viewed:  30269 Time(s)

Telnet1.png


weitjong
DD-WRT Novice


Joined: 05 Apr 2012
Posts: 3
Location: 新加坡 Singapore

PostPosted: Sat Apr 07, 2012 15:14    Post subject: Reply with quote
From the error message that you got, I can think of two possibilities:

1. You have not enabled the jffs correctly.
2. Your router may use different mount point than my WRT610N does.

Can you check the output of this command "df -h". Mine is something like this.

Code:
# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root                    5.6M      5.6M            0 100% /
/dev/mtdblock/4         1.1M    324.0K   828.0K   28% /jffs


If you only see one entry in the output then you have not enabled the new file system correctly. If you see two entries then check what is your system mount point for JFFS. As you can see mine is "/jffs".

Another way to test is by manually go to the "/jffs" or what have you, and try to create a temporary file for testing. You will only be able to do so when the JFFS is enabled correctly. You can do the test like this.

Code:
touch /jffs/test123 && ls /jffs && rm /jffs/test123


You should see "test123" being listed out as the output in the above test, if the filesystem is mounted properly.
scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Sun Apr 08, 2012 8:32    Post subject: Reply with quote
Hi weitjong,

I started with a clean slate (hard reset) and installed the latest build of 18946M. Did exactly per the wiki to enable jffs from: http://www.dd-wrt.com/wiki/index.php/Journalling_Flash_File_System

However, I'm getting the same results. Tried couple things as show in the picture below. Hmmm... still can't get through.



WinSCP result.png
 Description:
 Filesize:  174.52 KB
 Viewed:  30231 Time(s)

WinSCP result.png


scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Sun Apr 08, 2012 8:48    Post subject: Reply with quote
Here is another snapshot attached.


Telnet1.png
 Description:
 Filesize:  106.87 KB
 Viewed:  30228 Time(s)

Telnet1.png


LOM
DD-WRT Guru


Joined: 28 Dec 2008
Posts: 7647

PostPosted: Sun Apr 08, 2012 8:58    Post subject: Reply with quote
http://www.dd-wrt.com/wiki/index.php/JFFS#Directions_for_.28normal.29_users:_using_Web-GUI_Interface
_________________
Kernel panic: Aiee, killing interrupt handler!
weitjong
DD-WRT Novice


Joined: 05 Apr 2012
Posts: 3
Location: 新加坡 Singapore

PostPosted: Sun Apr 08, 2012 9:37    Post subject: Reply with quote
Thanks LOM. I am about to point out the same section Smile.

scorp588, you have to follow the steps in the wiki as close as possible. I am also new to the dd-wrt world and it took me a few attempts to get it right at first. I use the same wiki page, btw. When it says wait, it really means it.

I can see you are not that familiar with Linux, but it does not matter. Both your test outputs show you have not enabled the JFFS correctly. So, that is the reason why you failed to create the vlan10.startup script.
scorp588
DD-WRT Novice


Joined: 22 Jan 2011
Posts: 19
Location: N 1 17.684 E 103 51.533

PostPosted: Mon Apr 09, 2012 5:27    Post subject: VLAN ID settings for Singnet Fibre Broadband [SOLVED] Reply with quote
Thanks weitjong & LOM.

I have re-flashed the router with the firmware “dd-wrt.v24-18946_NEWD-2_K2.6_std_usb_nas-nv60k.bin” and now all looks good. The jffs worked as it should be.

I was using the “big” version of build 18946 previously. I guess it doesn’t work well with E2000 router for enabling jffs. May be there is a hardware limitations.

PS: weitjong - A very big thank you to you pal. Another Problem Solved!
sync
DD-WRT User


Joined: 18 Nov 2006
Posts: 61

PostPosted: Sun Nov 02, 2014 10:47    Post subject: Reply with quote
weitjong wrote:
I just upgraded to Singtel Fibre Optic last week and happen to own a WRT610N. I had a similar issue with the original poster where I need to figure how to configure WRT610 to work with VLANs. After numerous try and error, I finally got it working with the stocked dd-wrt firmware. I thought I should share it here as my first post in the forum.

Although the dd-wrt limits to the first 15 VLANs as written by phuzi0n, the limit does not bother me because I only subscribe to the Internet service (VLAN ID 10) and not the IPTV (VID 20) & VOIP (VID 30). If I were, I would probably use the modified switch-robo.ko kernel module compiled by tangsoft or cron2.

Anyway, here is the two steps to setup the VLAN.
1. In the VLANs tab, tagged the WAN port and then select VLAN10 and unselect VLAN2 (for my case). Apply setting and wait for a while.
2. In the Networking tab, assign VLAN10 as the VLAN for WAN. (If you don't see VLAN10 in the drop down list, it means you have not wait long enough in step 1. Cycle to other tab first and come back to check again). Apply setting. See attachment below.

My WAN connection type is set to "Automatic Configuration - DHCP". After applying the setting in step 2, the VLAN10 interface is up, WAN IP is assigned automatically from Singtel ISP. At this point, the internet surfing is possible.

Unfortunately, I believe there is a bug in the firmware. VLAN assignment setting for WAN does not survive the power cycle. It always reverts back to VLAN2 for my case. To me, this looks like the same bug reported in this post: http://www.dd-wrt.com/phpBB2/viewtopic.php?t=56868
If it is true, this bug is not fixed since then until today. I have tried the latest BS build (b18777) and I believe I am observing the same problem. I hope the Gurus here agree it is a bug and have it fixed soon. I don't have enough karma to fix it myself Very Happy.

All is not lost though as I figure out another way to workaround the problem. Here is my workaround, YMMV.

1. Enable the JFFS2 support.
2. Telnet/ssh into router and execute these commands:

Code:
mkdir -p /jffs/etc/config
echo '#!/bin/ash
PATH="/sbin:/usr/sbin:/bin:/usr/bin:${PATH}"
nvram set wan_iface=vlan10
nvram set wan_ifname2=vlan10
nvram set wan_ifname=vlan10
nvram set wan_ifnames=vlan10
nvram commit
startstop wan
ifconfig vlan2 down' >/jffs/etc/config/vlan10.startup
chmod 750 /jffs/etc/config/vlan10.startup


Above commands generate a folder containing new startup script that runs every time the router reboots. It basically reassigns the vlan10 as the VLAN for the WAN and restart the WAN service.

BTW, for those out there that still uses the old firmware builds that do not have the working webGUI for VLAN setup, you may want to try below instead to setup the VLANs via command line.

Code:
nvram set port0vlans="10 16"
nvram set port5vlans="1 10 16"
nvram set new_vlan2ports=
nvram set new_vlan2hwname=
nvram set vlan10ports="0t 8"
nvram set vlan10hwname=et0
nvram commit


I hope this help someone else with similar requirement. I also hope I am not too late for the original poster Smile.


hi weitjong,

i have a wrt350n

i have the same problem but i use a vpn build which doesn't have jffs

could you write a script for me to put in the startup command?

at the moment i have some vpn scripts in the start up command which works fine,

so all i need is the script to switch the vlan2 to vlan10 and restart the wan services before my vpn script kicks in
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