Re: Repeater configurations here! Both ways, bridged and simple repeater

I've got a TP-Link WR1043ND set up as a repeater-bridge based on a combination of settings I've scratched together from various Howtos. Bottom line is that it works, but has 2 problems:
1. I can't access the router using an Ethernet cable plugged into one of the switch ports despite manually setting my PC to an IP in the correct subnet.
2. The wireless AP bit of the bridge doesn't appear until it's made its connection to the upstream AP.

Any suggestions as to what I've screwed up?

network

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0'
        option type 'bridge'
        option proto 'static'
        option netmask '255.255.255.0'
        option gateway '192.168.1.254'
        option dns '192.168.1.254'
        option ipaddr '192.168.2.103'

config switch
        option name 'rtl8366rb'
        option reset '1'
        option enable_learning '0'
        option enable_vlan4k '1'

config switch_vlan
        option device 'rtl8366rb'
        option vlan '2'
        option ports '0 5t'

config interface 'wwan'
        option _orig_ifname 'wlan0-1'
        option _orig_bridge 'false'
        option proto 'static'
        option ipaddr '192.168.1.2'
        option netmask '255.255.255.0'
        option gateway '192.168.1.254'
        option dns '192.168.1.254'

config interface 'stabridge'
        option proto 'relay'
        option ipaddr '192.168.1.2'
        option _orig_ifname 'wlan0-1'
        option _orig_bridge 'false'
        list network 'lan'
        list network 'wwan'

wireless

config wifi-device 'radio0' 
       option type 'mac80211'
        option macaddr '54:e6:fc:dc:b5:dc'
        option hwmode '11ng'
        option htmode 'HT20'
        list ht_capab 'SHORT-GI-40'
        list ht_capab 'DSSS_CCK-40'
        option country 'AU'
        option txpower '20'
        option disabled '0'
        option channel '5'

config wifi-iface
        option device 'radio0'
        option mode 'sta'
        option network 'wwan'
        option ssid 'Wineyard'
       option encryption 'psk2'
        option key '****'

config wifi-iface
        option device 'radio0'
        option mode 'ap'
        option ssid 'Boreshed'
        option encryption 'psk'
        option key '***'
        option network 'lan stabridge'

Re: Repeater configurations here! Both ways, bridged and simple repeater

Ive done option one, but my problem is I cant log into the router from its AP. not via luci or putty.

Re: Repeater configurations here! Both ways, bridged and simple repeater

forsakenrider wrote:

Ive done option one, but my problem is I cant log into the router from its AP. not via luci or putty.

The configuration has helped me a lot and it works well smile. Anyway, i can't log into my router if i don't set my ethernet ip manually to 10.0.0.2. So is there a possible to set the router to the range 192.168.0.x?

29 (edited by dabyd64 2013-02-26 15:24:17)

Re: Repeater configurations here! Both ways, bridged and simple repeater

I can enter my router perfectly.
Did you set your router's IP in 'gateway' option?

In the simple repeater mode you must use a different subnet.
Ex. router 192.168.1.1, your repeater 192.168.2.1.

If you use relayd your ap MUST use the same subnet as your main router.
Ex. router 192.168.1.1, your repeater 192.168.1.2.

Re: Repeater configurations here! Both ways, bridged and simple repeater

THANK YOU dabyd64! i'd been following steps from the openwrt documentation struggling to get mode 2 working on my tl-wr703n for 3 days! your steps worked like a charm! thanks!

31 (edited by dabyd64 2013-02-27 23:35:39)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Nice that you made it working smile

Re: Repeater configurations here! Both ways, bridged and simple repeater

Hello friends,


I have a problema, I need to do that WR1043nd a repeater of a cisco router (EA4500) that this router dont have WDS!!

Is this posible ?

Can Openwrt  connect to a router (repeater o bridge) that dont support WDS ?

Please i'm worried

Thanks in advance!
Christian

33 (edited by dabyd64 2013-03-26 15:39:54)

Re: Repeater configurations here! Both ways, bridged and simple repeater

This configs have no relation with WDS. So don't worry.
The config #2 will work for sure, but you will be in a different network.
If you use the config #1 (bridged), the it depends on the main router. A few routers I tried (Hitron brand), didn't like to give more DHCP addresses than the repeater's.
You will have to check yourself, but must routers works with the bridged mode withouyt any problem.

Re: Repeater configurations here! Both ways, bridged and simple repeater

Is there a way to configure the repeater unit to use different wireless channel from the main router? I believe that using the same channel will cause some interference. Thx

35 (edited by dabyd64 2013-03-29 05:29:12)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Nope, it's a hardware limitation, one radio--> same channel for all wireless networks, client or ap.

Re: Repeater configurations here! Both ways, bridged and simple repeater

Of course it causes interferences... it can be fixed by buying another router, set one as client and the other as AP in a far channel.
I have that setup and works great

Re: Repeater configurations here! Both ways, bridged and simple repeater

Mode 2 works like advertised. :-)

Did anyone successfully add a VPN configuration to this mode?
I'm using StrongVPN with PPTP and cant get the configuration to work.

Cheers

Re: Repeater configurations here! Both ways, bridged and simple repeater

I suppose you must add port forwarding for that, and you must forward in the main router to the openwrt's IP, and then on openwrt to the computer's IP.

Re: Repeater configurations here! Both ways, bridged and simple repeater

Gave up trying to get the Asus WL-330N3G to work using either mode, however i bought the TL-MR3040 and was able to eventually successfully install openwrt and configure using repeater mode 2 as above and its working okay thus far.

Thanks to everyone who took time to help me out and advice me...you guys are great...appreciated big_smile

40 (edited by des245 2013-04-21 07:46:25)

Re: Repeater configurations here! Both ways, bridged and simple repeater

guys, this may seem a silly question but can one have more than one client in repeater mode?

see pic below -

http://t2.stooorage.com/thumbs/2113/8520177_repeater_mode_edit.jpg

41 (edited by dabyd64 2013-04-24 14:57:54)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Nope, only one client, as far as I know.

42 (edited by Culex 2013-05-08 22:53:47)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Thanks for this post. I finally figured out how to do it in the Web Gui. Apparently you "join a network" it only adds the client under network>wifi.

Apparently in the latest trunk, you have to add the access point or "master" record for it to start bridging 2 lan segments. the

edit:
I just tested the wireless. Apparently it can connect and access the internet. I can access devices on both lans.

"Computers won't see each other between networks, DHCP is given by openwrt's router."

is slightly incorrect. DHCP is given by repeater to be clear. I can see all computers and devices on both lans from repeater lan and wireless devices.

However the main lan can't see the repeated lan. I have internet access and can ping the router hosting the internet, but the router cannot ping me back. Maybe it's a route issue and doesn't know what to do with 10.x addresses?

Re: Repeater configurations here! Both ways, bridged and simple repeater

Yes, the DHCP is given by the repeater (that was I tried to mention as "openwrt's router").
Of course, computers on the repeater networks can see the main network computer, as it is routed by the repeater to the main router.
But not reverse, as the main router doesn't know any other adresses than its own network's. Any address request not being part from the main network would go "outside", to the internet.
If you want that, you must do the briged repeater setup, in that mode all the DHCP request are forwarded to the main router, and anyone can talk with everyone.

Re: Repeater configurations here! Both ways, bridged and simple repeater

Wouldn't it be simpler to setup a WDS bridge as in http://wiki.openwrt.org/doc/recipes/atheroswds ?

45 (edited by dabyd64 2013-05-16 15:12:12)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Maybe, but depends on the main AP that must support WDS, and it even may not work due manufacturer specific configurations.
Also, I read lot of times that WPA+WPS usually doesn't work.
The non-bridged repeater works with any AP, any security mode(none, WEP, WPA, WPA2...) smile.
The bridged mode works with most of routers, a few don't like forwarded DHCP request.

46 (edited by snorp 2013-09-07 16:15:03)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Hello,

As I am having the same problem as RusselK, I just wanted to know if there's a solution.

RusselK wrote:

2. The wireless AP bit of the bridge doesn't appear until it's made its connection to the upstream AP.

When shutting down the modem's AP (to which OpenWrt acts as client), I cannot access the repeater-WLAN (mastered by OpenWrt) anymore.

Thanks in advance.

Topology:

  [Client 1]   ...   [Client n]
 192.168.2.X1       192.168.2.Xn
        \              /           LAN (ethernet and wifi bridged)
         192.168.2.1/24
     [TP-WR1043ND, OpenWrt]
           192.168.1.Y
                |                  WWAN (wifi)
         192.168.1.1/24
    [Modem, proprietary OS]
            IP by ISP

Re: Repeater configurations here! Both ways, bridged and simple repeater

The only way to fix that problem is to use two routers and put them as client and ap

Re: Repeater configurations here! Both ways, bridged and simple repeater

Thanks you dabyd64 for your assistance with these configurations. However, I'm seeing a different issue on each.

First for the relayd bridged repeater, things work well, except that devices on the master network can't ping/connect to the repeater router. However, if I first connect to repeater network and then switch back or use an IP scanning tool, then devices on the master network can ping the repeater router. So it seems to be some sort of not know it is there/not being able to route to it issue that I'm not sure the cause of. Any ideas? I can certainly list my configs if that is of use.

Secondly, for the repeater on different networks. I got it such that I can ping google.com from the repeater router. However, clients of the repeater router cannot access the Internet. My wireless, network and dhcp configs are listed below. I disabled the firewall.

wireless

config wifi-device  radio0
        option type     mac80211
        option channel  1
        option hwmode   11ng
        option path     'platform/ar933x_wmac'
        option htmode   HT20
        list ht_capab   SHORT-GI-20
        list ht_capab   SHORT-GI-40
        list ht_capab   RX-STBC1
        list ht_capab   DSSS_CCK-40

config wifi-iface
        option ssid 'MasterSSID'
        option encryption psk2
        option device radio0
        option mode sta
        option network wwan
        option key 'password1'

config wifi-iface
        option device   radio0
        option network  lan
        option mode     ap
        option ssid     RepeaterSSID
        option encryption psk2
        option key      'password2'

network

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config interface 'lan'
        option ifname 'eth0'
        option type 'bridge'
        option proto 'static'
        option netmask '255.255.255.0'
        option ipaddr '192.168.10.1'

config interface 'wwan'
        option proto 'dhcp'

dhcp

config dnsmasq
        option domainneeded     1
        option boguspriv        1
        option filterwin2k      0  # enable for dial on demand
        option localise_queries 1
        option rebind_protection 1  # disable if upstream must serve RFC1918 addresses
        option rebind_localhost 1  # enable for RBL checking and similar services
        option local    '/lan/'
        option domain   'lan'
        option expandhosts      1
        option nonegcache       0
        option authoritative    1
        option readethers       1
        option leasefile        '/tmp/dhcp.leases'
        option resolvfile       '/tmp/resolv.conf.auto'

config dhcp lan
        option interface        lan
        option start    100
        option limit    150
        option leasetime        12h
        option ignore   0

config dhcp wan
        option interface        wan
        option ignore   1

Re: Repeater configurations here! Both ways, bridged and simple repeater

It seems a firewall issue. Post /etc/config/firewall  to check it.

50 (edited by SharkAttack99 2013-09-27 23:40:38)

Re: Repeater configurations here! Both ways, bridged and simple repeater

Thanks for the response. I had other things in the firewall as well and I just went for a straight up copy and paste of your example.

config defaults
    option syn_flood '1'
    option input 'ACCEPT'
    option output 'ACCEPT'
    option forward 'REJECT'

config zone
    option name 'lan'
    option network 'lan'
    option input 'ACCEPT'
    option output 'ACCEPT'
    option forward 'REJECT'

config zone
    option name 'wan'
    option input 'REJECT'
    option output 'ACCEPT'
    option forward 'REJECT'
    option masq '1'
    option mtu_fix '1'
    option network 'wan wwan'

config forwarding
    option src 'lan'
    option dest 'wan'

When on the client network I can ping both IP's of the repeater router, it's self supplied one and the one supplied by the master router on a different subnet. But no Internet and can't ping the master router.
Edit: Oh, and I can still ping the master router from the repeater router. And disabling the firewall didn't seem to help either.