Hello kuniu,
Am Tue, 5 Jul 2016 23:31:36 +0100 schrieb koniu <gkusni...@gmail.com>: > On Tue, 5 Jul 2016 13:22:40 +0200 > Lars Kruse <li...@sumpfralle.de> wrote: > > "wifi down" would be an alternative approach for this problem > > (shutting down all wifi interfaces). But I do not want to interfere > > with the other wifi interfaces - thus this would not be an option for > > me. > > > > Can someone recommend a way to disable specific wifi interfaces > > (ideally based on the name of its logical network interface)? > > Not 100% sure what you mean by "logical network interface" but maybe > you're looking for: > > # wifi down radio0 This is a good start. Sadly it is not as specific as I would prefer (there are going to be multiple wireless interfaces using the same radio), but it is better than my current approach. > [..] > You could also do: > > # uci set wireless.@wifi-iface[0].disabled='1' > # wifi reload My original plan was to disable the "auto" flag of the interface and control its state via "ifup" and "ifdown" (based on events). This would allow human users to override the automatic behaviour via the above "disabled" flag of the wireless interface, if necessary. But maybe this is not too important. > If by interface you mean eg "lan" (as in iface names > in /etc/config/network) then you need to get the mapping from "lan" to > "radio0" using (for example) something like this: > > # uci show wireless.$(uci show wireless | grep lan | cut -d. -f2) |\ > grep device |cut -d= -f2 to get > > You can of course get the logical-network-iface > logical-wifi-iface > mapping in other ways (ubus, libiwinfo-lua, ...) I was hoping to learn an approach that would free me from retrieving the corresponding wireless interface(s) on my own. A simple counterpart of "ifup" would have been really nice. Anway: thank you for your time and your hints. I will follow your advice. Cheers, Lars _______________________________________________ openwrt-users mailing list openwrt-users@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-users