openwrt中br-lan,eth0,eth0.1,eth0.2

CPU是QCA9558 有两个以太网接口 这个好像没有外接交换机直接印出来的

openwrt中br-lan,eth0,eth0.1,eth0.2

https://blog.csdn.net/f2157120/article/details/119460852

这个哥用的是 链接: DomyWifi DW33D 路由器

CPU是QCA9558 有两个以太网接口

因为CPU没集成千兆交换,所以需要有独立的千兆交换机芯片,型号是QCA8337。

eth1 是接上了交换机芯片

eth0 是接上了WAN

同时这个划分了VLAN WAN属于eth0.2

同时这个划分了VLAN LAN属于eth1.1

bash 复制代码
root@OpenWrt:~# cat /etc/config/network 

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

config globals 'globals'
	option ula_prefix 'fdfd:dcb6:dfdc::/48'

config interface 'lan'
	option type 'bridge'
	option ifname 'eth1.1'
	option proto 'static'
	option netmask '255.255.255.0'
	option ip6assign '60'
	option ipaddr '192.168.11.1'

config interface 'wan'
	option ifname 'eth0.2'
	option proto 'dhcp'

config interface 'wan6'
	option ifname 'eth0.2'
	option proto 'dhcpv6'

config switch
	option name 'switch0'
	option reset '1'
	option enable_vlan '1'

config switch_vlan
	option device 'switch0'
	option vlan '1'
	option ports '2 3 4 5 6t'  ## 感觉这个顺序有点问题

config switch_vlan
	option device 'switch0'
	option vlan '2'
	option ports '1 0t'  ## 感觉这个顺序有点问题

root@OpenWrt:~# 
root@OpenWrt:~# 
root@OpenWrt:~# cat /etc/config/wireless 

config wifi-device 'radio0'
	option type 'mac80211'
	option channel '36'
	option hwmode '11a'
	option path 'pci0000:00/0000:00:00.0'
	option htmode 'VHT80'
	option country 'US'
	option legacy_rates '1'

config wifi-iface 'default_radio0'
	option device 'radio0'
	option network 'lan'
	option mode 'ap'
	option ssid 'DW33D-5G'
	option encryption 'psk2'
	option key 'lsgxwifilink'

config wifi-device 'radio1'
	option type 'mac80211'
	option channel '11'
	option hwmode '11g'
	option path 'platform/qca955x_wmac'
	option htmode 'HT20'
	option country 'US'
	option legacy_rates '1'

config wifi-iface 'default_radio1'
	option device 'radio1'
	option network 'lan'
	option mode 'ap'
	option ssid 'DW33D-24G'
	option encryption 'psk2'
	option key 'lsgxwifilink'

接口详情

bash 复制代码
root@OpenWrt:~# ifconfig 
br-lan    Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DD  
          inet addr:192.168.11.1  Bcast:192.168.11.255  Mask:255.255.255.0
          inet6 addr: fe80::163d:f2ff:fecb:9add/64 Scope:Link
          inet6 addr: fdfd:dcb6:dfdc::1/60 Scope:Global
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:3790087 errors:0 dropped:0 overruns:0 frame:0
          TX packets:6492932 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1301078776 (1.2 GiB)  TX bytes:6703438607 (6.2 GiB)

eth0      Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DE  
          inet6 addr: fe80::163d:f2ff:fecb:9ade/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:7156095 errors:0 dropped:0 overruns:75 frame:0
          TX packets:4787213 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:2503390857 (2.3 GiB)  TX bytes:1442610380 (1.3 GiB)
          Interrupt:4 

eth0.2    Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DE  
          inet addr:192.168.1.7  Bcast:192.168.1.255  Mask:255.255.255.0
          inet6 addr: fe80::163d:f2ff:fecb:9ade/64 Scope:Link
          inet6 addr: fe80::163d:f2ff:fecb:9ade/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:7156071 errors:0 dropped:0 overruns:0 frame:0
          TX packets:4787198 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:6669546570 (6.2 GiB)  TX bytes:1423460094 (1.3 GiB)

eth1      Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DD  
          inet6 addr: fe80::163d:f2ff:fecb:9add/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34693 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:3854512 (3.6 MiB)
          Interrupt:5 

eth1.1    Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DD  
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34685 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:3714764 (3.5 MiB)

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:2466 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2466 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1 
          RX bytes:196065 (191.4 KiB)  TX bytes:196065 (191.4 KiB)

wlan0     Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DF  
          inet6 addr: fe80::163d:f2ff:fecb:9adf/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:4411547 errors:0 dropped:33393 overruns:0 frame:0
          TX packets:6527097 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:1391076302 (1.2 GiB)  TX bytes:6837481031 (6.3 GiB)

wlan1     Link encap:Ethernet  HWaddr 14:3D:F2:CB:9A:DC  
          inet6 addr: fe80::163d:f2ff:fecb:9adc/64 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:34682 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:0 (0.0 B)  TX bytes:4338526 (4.1 MiB)

root@OpenWrt:~# 
root@OpenWrt:~# 
root@OpenWrt:~# brctl show
bridge name	bridge id		STP enabled	interfaces
br-lan		7fff.143df2cb9add	no		eth1.1
							wlan0
							wlan1
root@OpenWrt:~# 
相关推荐
Ether IC Verifier1 小时前
TCP三次握手与四次挥手详解
网络·网络协议·tcp/ip·计算机网络
星寂樱易李8 小时前
iperf3 + Python-- 网络带宽、网速、网络稳定性
开发语言·网络·python
随身数智备忘录12 小时前
什么是设备管理体系?设备管理体系包含哪些核心模块?
网络·数据库·人工智能
第五文修12 小时前
手机OTG转TTL网口实现ping功能
网络·智能手机
云边云科技_云网融合12 小时前
企业大模型时代的网络架构五层演进:从连接到智能的范式重构
网络·重构·架构
xhbh66614 小时前
代理ARP (Proxy ARP) 是如何实现跨网段通信的?在Linux下如何配置?
服务器·网络·智能路由器·端口映射·映射
数智化管理手记15 小时前
精益生产3步实操,让现场从混乱变标杆
大数据·运维·网络·人工智能·精益工程
XiYang-DING16 小时前
【Java EE】TCP—可靠传输
网络·tcp/ip·java-ee
沃虎电子16 小时前
片式网络变压器:从“手工品”到“SMD元件”的产业跨越
网络·片式网络变压器
神奇小梵16 小时前
关于finalshell的使用
linux·服务器·网络