原版openwrt配置
原创2026年1月12日大约 1 分钟
原版openwrt配置
双网卡&IPv6配置
cat /etc/config/network
注意:eth0为内网网卡,虚拟的局域网网卡,eth1为外网网卡可以上网的网卡
对应net0为内网网卡,net1为外网网卡
下面配置本版本只修改了option ipaddr '172.16.1.1'这一项
config interface 'loopback'
option device 'lo'
option proto 'static'
option ipaddr '127.0.0.1'
option netmask '255.0.0.0'
config globals 'globals'
option ula_prefix 'fd69:b7e9:1122::/48'
config device
option name 'br-lan'
option type 'bridge'
list ports 'eth0'
config interface 'lan'
option device 'br-lan'
option proto 'static'
option ipaddr '172.16.1.1'
option netmask '255.255.255.0'
option ip6assign '60'
config interface 'wan'
option device 'eth1'
option proto 'dhcp'
config interface 'wan6'
option device 'eth1'
option proto 'dhcpv6'配置完成之后重启
service network restart
插件安装
- luci-i18n-base-zh-cn
从软件中心可安装记得先更新 - luci-theme-argon https://github.com/jerrykuku/luci-theme-argon 我安装的是 `luci-theme-argon_2.3.2-r20250207_all.ipk
luci-theme-argon-2.4.3-r20250722.apk无法安装
基础配置(后台页面配置)
- 设置密码,设置登录
- 配置防火墙,外网访问(要给OpenTwr一个固定的内网IP)
其他插件安装
Passwall2
Passwall2
https://github.com/xiaorouji/openwrt-passwall2
我安装的是https://github.com/Openwrt-Passwall/openwrt-passwall2/releases/tag/26.1.1-1
opkg update
# 上传到服务器,文件 passwall_packages_ipk_x86_64.zip luci-i18n-passwall2-zh-cn_26.1.1_all.ipk luci-app-passwall2_26.1.1-r1_all.ipk
mkdir Passwall2
cd Passwall2
unzip passwall_packages_ipk_x86_64.zip
# 安装所有包
opkg install *.ipk
opkg install *.ipk
opkg install luci-app-passwall2_26.1.1-r1_all.ipk
opkg install luci-i18n-passwall2-zh-cn_26.1.1_all.ipk
## 有错误记得查看日志额okpg update
oopkg remove dnsmasq
opkg install dnsmasq-full