On a Buffalo WZR-HP-AG300H which is, I believe, a non-DSA device, running 23.05.5, I have (not changed from defaults really):
# swconfig dev mdio.0 show
Global attributes:
enable_vlan: 1
ar8xxx_mib_poll_interval: 0
ar8xxx_mib_type: 0
enable_mirror_rx: 0
enable_mirror_tx: 0
mirror_monitor_port: 0
mirror_source_port: 0
arl_table: address resolution table
Port 0:
mib: ???
pvid: 0
link: port:0 link:up speed:1000baseT full-duplex txflow rxflow
Port 1:
mib: ???
pvid: 1
link: port:1 link:up speed:100baseT full-duplex auto
Port 2:
mib: ???
pvid: 1
link: port:2 link:down
Port 3:
mib: ???
pvid: 1
link: port:3 link:down
Port 4:
mib: ???
pvid: 1
link: port:4 link:down
VLAN 1:
vid: 1
ports: 0t 1 2 3 4
How can I disable/toggle the link status on port 1 here?
On a DSA device it would have been a straightforward ip link set lan1 down|up
or similar, but I can't find the corresponding swconfig
or other command line, if one exists, here.
Edit: I somehow managed to miss the doc. Unfortunately it seems this isn't supported on this switch?
# swconfig dev mdio.0 port 1 set disable 1
Unknown attribute "disable"
# swconfig dev mdio.0 help
switch0: mdio.0(Atheros AR8316), ports: 5 (cpu @ 0), vlans: 128
--switch
Attribute 1 (int): enable_vlan (Enable VLAN mode)
Attribute 2 (none): reset_mibs (Reset all MIB counters)
Attribute 3 (int): ar8xxx_mib_poll_interval (MIB polling interval in msecs (0 to disable))
Attribute 4 (int): ar8xxx_mib_type (MIB type (0=basic 1=extended))
Attribute 5 (int): enable_mirror_rx (Enable mirroring of RX packets)
Attribute 6 (int): enable_mirror_tx (Enable mirroring of TX packets)
Attribute 7 (int): mirror_monitor_port (Mirror monitor port)
Attribute 8 (int): mirror_source_port (Mirror source port)
Attribute 9 (string): arl_table (Get ARL table)
Attribute 10 (none): flush_arl_table (Flush ARL table)
Attribute 11 (none): apply (Activate changes in the hardware)
Attribute 12 (none): reset (Reset the switch)
--vlan
Attribute 1 (int): vid (VLAN ID (0-4094))
Attribute 2 (ports): ports (VLAN port mapping)
--port
Attribute 1 (none): reset_mib (Reset single port MIB counters)
Attribute 2 (string): mib (Get port's MIB counters)
Attribute 3 (none): flush_arl_table (Flush port's ARL table entries)
Attribute 4 (int): pvid (Primary VLAN ID)
Attribute 5 (unknown): link (Get port link information)