Hello Guys,
iam a trainee in a IT and in my second year and want to build a testlap. For this i bought the Asus RT-AC85P and flashed it with open WRT.
My Testlap should have this VLAN/IP Table
Client
Wlan 2 Ghz.
Wlan 5 Ghz
VLAN 10
10.0.10.0/24
Server
VLAN 100
10.0.100.0/24
Kept it rly simple is just a testlap
I already read this [OpenWrt Wiki] VLAN
But for a noob it can be be confusing. Printed you out ubus call system board, ls -l /sys/class/net, cat /etc/config/network,
Iam alright that lan1 to lan4 are physical ports? or are they just logical? Even i read the article i don't know what to do. I need to add VLAN ID to the Ports and WLAN i wanna use for client and server and add the ip address on layer 3 to them. Atm i just have experience with cisco switches.
Can you show me just one example if i wanna take port 3 & 4 into Server VLAN 100
and give both ports the ip address 10.0.100.1?
root@OpenWrt:~# ubus call system board
{
"kernel": "5.10.161",
"hostname": "OpenWrt",
"system": "MediaTek MT7621 ver:1 eco:3",
"model": "ASUS RT-AC85P",
"board_name": "asus,rt-ac85p",
"rootfs_type": "squashfs",
"release": {
"distribution": "OpenWrt",
"version": "22.03.3",
"revision": "r20028-43d71ad93e",
"target": "ramips/mt7621",
"description": "OpenWrt 22.03.3 r20028-43d71ad93e"
}
}
root@OpenWrt:~# ls -l /sys/class/net
lrwxrwxrwx 1 root root 0 Jan 3 00:25 br-lan -> ../../devices/virtual/net/br-lan
lrwxrwxrwx 1 root root 0 Jan 1 1970 eth0 -> ../../devices/platform/1e100000.ethernet/net/eth0
lrwxrwxrwx 1 root root 0 Jan 1 1970 lan1 -> ../../devices/platform/1e100000.ethernet/mdio_bus/mdio-bus/mdio-bus:1f/net/lan1
lrwxrwxrwx 1 root root 0 Jan 1 1970 lan2 -> ../../devices/platform/1e100000.ethernet/mdio_bus/mdio-bus/mdio-bus:1f/net/lan2
lrwxrwxrwx 1 root root 0 Jan 1 1970 lan3 -> ../../devices/platform/1e100000.ethernet/mdio_bus/mdio-bus/mdio-bus:1f/net/lan3
lrwxrwxrwx 1 root root 0 Jan 1 1970 lan4 -> ../../devices/platform/1e100000.ethernet/mdio_bus/mdio-bus/mdio-bus:1f/net/lan4
lrwxrwxrwx 1 root root 0 Jan 1 1970 lo -> ../../devices/virtual/net/lo
lrwxrwxrwx 1 root root 0 Jan 1 1970 wan -> ../../devices/platform/1e100000.ethernet/mdio_bus/mdio-bus/mdio-bus:1f/net/wan
lrwxrwxrwx 1 root root 0 Jan 3 00:25 wlan0 -> ../../devices/platform/1e140000.pcie/pci0000:00/0000:00:00.0/0000:01:00.0/net/wlan0
lrwxrwxrwx 1 root root 0 Jan 3 00:25 wlan1 -> ../../devices/platform/1e140000.pcie/pci0000:00/0000:00:01.0/0000:02:00.0/net/wlan1
root@OpenWrt:~# cat /etc/config/network
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 packet_steering '1'
option ula_prefix 'fd7e:fc5a:ef1f::/48'
config device
option name 'br-lan'
option type 'bridge'
list ports 'lan1'
list ports 'lan2'
list ports 'lan3'
list ports 'lan4'
config interface 'lan'
option device 'br-lan'
option proto 'static'
option ipaddr '192.168.1.1'
option netmask '255.255.255.0'
option ip6assign '60'
config interface 'wan'
option device 'wan'
option proto 'dhcp'
config interface 'wan6'
option device 'wan'
option proto 'dhcpv6'