# 添加并且使能vlan接口(vlanId分别为: 45、100) ip link add link eth0 name vlan45 type vlan id 45 ip link set vlan45 up ip link add link eth0 name vlan100 type vlan id 100 ip link set vlan100 up
# 添加并且使能网桥(br0是自带的, 不用添加) brctl addbr br1 ip link set br1 up
# seems like eapd reads config from these # no need to set lan_ifname since it's already there nvram setlan_ifnames="eth0 eth1 eth2 eth3 eth4 eth5 vlan45" #下面这一行br0的可以不用 nvram setlan_ifname="br0" nvram setbr0_ifnames="eth0 eth1 eth2 eth3 eth4 eth5 vlan45" #下面这一行br0的可以不用 nvram setbr0_ifname="br0"