-
Notifications
You must be signed in to change notification settings - Fork 325
Advanced Network Configuration
Starting with Gluon v2022.1 /etc/config/network
is regenerated on every gluon-reconfigure
(at least run during every upgrade).
Configuration has to be done via the gluon
config (stored the /etc/config/gluon
file).
Some infos can be found in the docs: Wired mesh - Commandline
Depending on the Switch Type there are diffrent degrees of freedom for configuring network interfaces.
You can see the type your device uses by calling gluon-info
and looking for the Switch type
value.
DSA: Switch Logic is hidden and every physical port is it's own logical interface. Allows for a high degree of flexibility.
swconfig: Old way of doing switch configuration. No option to permanently alter the default port config. Port roles can be switched.
none: No managable switch chip. Can mean that there is an unmanaged switch or all network ports have their own phy (seperate network cards).
Caveat: Gluon v2023.2.3 and below fail to identify swconfig devices and falsely report none
for swconfig devices (see #3309).
What you want is either a device with DSA or only physical PHYs.
For the time beeing roles of configured Network Interfaces can be changed via the web interface in the setup mode. Hoewer it's not possible to delete or create interfaces via the config mode. This has to be done via the console.
There are diffrent default interfaces:
On single Port devices:
gluon.iface_single with the name option /single
On devices with multiple Ports:
gluon.iface_wan with the name option /wan
gluon.iface_lan with the name option /lan
Those sections have to remain. They will be recreated by gluon-reconfigure
if you delete them.
To unconfigure them just delete all roles from them:
uci delete gluon.iface_single.role # or
uci delete gluon.iface_wan.role # or
uci delete gluon.iface_lan.role
You can figure out the interface names by looking at the output of the ip l
command.
Network cards usually appear as eth0
, eth1
, ...
DSA Ports are in the form lan1@eth0
lan2@eth0
or on some other device it might be wan@switch
, ... the latter part is common and the front differs. The labels are based on the print on the device.
For the config you have to use the part before the @
.
The 7530/7520 is part of the ipq40xx-generic target. This target has been migrated from swconfig to DSA with Gluon v2023.2 (OpenWrt 23.05). This means all four lan ports can now be configured with independent roles.
Hoewer the default is and will stay that all ports are bridged LAN Ports by default.
It is hoewer possible to override the default port configuration:
# unconfigure all roles for the LAN Ports, those would interfere with the new sections
uci delete gluon.iface_single.role
# add section for lan1 as with the uplink role
uci set gluon.iface_lan1=interface
uci set gluon.iface_lan1.name="lan1"
uci add_list gluon.iface_lan1.role="uplink"
# add sections for lan2, lan3, lan4 with the client role
uci set gluon.iface_lan2=interface
uci set gluon.iface_lan2.name="lan2"
uci add_list gluon.iface_lan2.role="client"
uci set gluon.iface_lan3=interface
uci set gluon.iface_lan3.name="lan3"
uci add_list gluon.iface_lan3.role="client"
uci set gluon.iface_lan4=interface
uci set gluon.iface_lan4.name="lan4"
uci add_list gluon.iface_lan4.role="client"
# generate new network config and apply it by rebooting
gluon-reconfigure
reboot
-
Usage
-
Community
-
Development
- Device Integration
- Roadmap
- Release-life-cycle
- Protocols
- Meeting 2024/06
- Meeting 2024/05
- Meeting 2024/03
- Meeting 2024/02
- Meeting 2024/01
- Meeting 2023/06
- Meeting 2023/05
- Meetup-CCCamp
- Meeting 2023/04
- Meeting 2023/03
- Meeting 2023/02
- Meeting 2023/01
- Meeting 2022/06
- Meeting 2022/05
- Meeting 2022/04
- Meeting 2022/03
- Meeting 2022/02
- Meeting 2022/01
- Meeting 2021/01
- Meeting 2019/01
- Meeting 2018/03
- Meeting 2018/02
- Meeting 2018/01
- Meeting 2017/01
- Concepts
- Release Process
-
Debugging