路由器LAN-LAN互联

需求:两个路由器连光猫网口,各自拨号上网。

一个路由器merlin固件,内网ip 192.168.1.1 ,
一个lede固件两个ip,broadcom wifi芯片。

配置lede固件路由器,/etc/config/network

config interface 'lan'
    option type 'bridge'
    option ifname 'eth0.1'
    option proto 'static'
    option netmask '255.255.255.0'
    option ip6assign '60'
    list ipaddr '192.168.2.10/24'
    list ipaddr '192.168.1.16/24'

参考https://lede-project.org/docs/user-guide/basic-ipv4-configuration最后段落。

这样,wifi进入merlin的无线网络后,可以通过192.168.1.16与lede的路由器进行交互。

注意如果采用最后Specifying multiple interfaces sharing the same device的方式,指定两个接口类型为bridge,不可行。
如果保持lan接口不变,第二个lan1口不设定type,路由器可以起来,但上网走的是merlin固件(待确认?)

tips:
升级lede,通过管理界面。升级的时候一定不能keep配置,不然导致系统起来的时候wifi不可用。

Webmentions

Loading...

When you post a tweet with a link to this post it will automatically show up here! (refreshed every 30 minutes) 💯

A small favor

Was anything I wrote confusing, outdated, or incorrect? Please let me know! Just write a few words below and I'll be sure to amend this post with your suggestions.

Follow along

If you want to know about new posts, add your email below. Alternatively, you can subscribe with RSS.

More from 格物治用

实践、探索、思考.

View all posts