Basic setup RB411AR router [solved]

I am trying to do a basic setup for my RB411AR router.

It has one ethernet connection, ether1. It has one wireless, wlan1.
I would like to have a static ip for ether1. ether1 is connected to my LAN, 192.168.1.0/24.


Here is the script I am using:

/ip address
add address=192.168.1.201/24 disabled=no interface=ether1
add address=192.168.0.1/24 disabled=no interface=wlan1
/ip pool
add name=dhcp_pool1 ranges=192.168.1.2-192.168.1.254
add name=dhcp_pool2 ranges=192.168.0.2-192.168.2.254
/ip dhcp-server
add address-pool=dhcp_pool1 disabled=no interface=ether1 lease-time=3d name=dhcp1
add address-pool=dhcp_pool2 disabled=no interface=wlan1 lease-time=3d name=dhcp2
/ip dhcp-server config
set store-leases-disk=5m
/ip dhcp-server network
add address=192.168.1.0/24 dns-server=4.2.2.2 gateway=192.168.1.1
add address=192.168.0.0/24 dns-server=4.2.2.2 gateway=192.168.0.1
/system ntp client
set enabled=yes mode=unicast primary-ntp=50.19.122.125
/interface wireless
set wlan1 band=2ghz-b/g default-authentication=yes disabled=no mode=ap-bridge
#/ip dhcp-client
#add interface=ether1 disabled=no
/ip firewall nat
add chain=srcnat out-interface=ether1 action=masquerade src-address=192.168.0.0/24 to-addresses=0.0.0.0
/ip neighbor discovery
set wlan1 discover=yes
/ip route
add disabled=no distance=1 dst-address=0.0.0.0/0 gateway=192.168.1.1 scope=255 target-scope=10


When I try to connected a wireless client, the wireless client indicates that it has been connected, but I am unable to get to the internet. The wireless client, in this case, is a laptop computer running windows 7.

What am I doing wrong?

Thanks for your help.

Don James

Obvious error:

/ip pool
add name=dhcp_pool2 ranges=192.168.0.2-192.168.2.254

That pool is invalid for your setup - it is larger than your provided network mask supports on that interface.

I do not understand the need for having a DHCP server on the WAN side:

/ip dhcp-server network
add address=192.168.1.0/24 dns-server=4.2.2.2 gateway=192.168.1.1

Also, I am not sure if you must set the output interface as it will be selected according to the default route:

/ip firewall nat
add chain=srcnat out-interface=ether1 action=masquerade src-address=192.168.0.0/24 to-addresses=0.0.0.0

Hi Karma,

I followed your advice and changed my setup to:

/ip address
add address=192.168.1.201/24 disabled=no interface=ether1
add address=192.168.0.1/24 disabled=no interface=wlan1
/ip pool
add name=dhcp_pool1 ranges=192.168.1.2-192.168.1.254
add name=dhcp_pool2 ranges=192.168.0.2-192.168.0.254
/ip dhcp-server
add address-pool=dhcp_pool1 disabled=no interface=ether1 lease-time=3d name=dhcp1
add address-pool=dhcp_pool2 disabled=no interface=wlan1 lease-time=3d name=dhcp2
/ip dhcp-server config
set store-leases-disk=5m
/ip dhcp-server network
add address=192.168.0.0/24 dns-server=4.2.2.2 gateway=192.168.0.1

/system ntp client
set enabled=yes mode=unicast primary-ntp=50.19.122.125
/interface wireless
set wlan1 band=2ghz-b/g default-authentication=yes disabled=no mode=ap-bridge

/ip firewall nat
add chain=srcnat out-interface=ether1 action=masquerade src-address=192.168.0.0/24 to-addresses=0.0.0.0
/ip neighbor discovery
set wlan1 discover=yes
/ip route
add disabled=no distance=1 dst-address=0.0.0.0/0 gateway=192.168.1.1 scope=255 target-scope=10


Now it works.

Thanks a bunch for your help.

Don James

Good to hear.