[Networkmanager] Prevent activation of network connection
thaller at redhat.com
Tue Dec 20 10:02:59 UTC 2022
On Mon, 2022-12-19 at 16:31 -0700, Orion Poplawski wrote:
> Is it possible to prevent activation of a connection via a dispatcher
> script or similar? I'm trying to recreate the effect of the Windows
> Simultaneous Connection to Non-domain and Domain" GP setting -
> Thank you.
I think not. Well, you can call `nmcli connection down` from a
dispatcher script. But then activation already stated. Also, it will
block future autoconnect.
If you have a more complex policy about autoconnect, I think that you
would disable "connection.autoconnect" in the profile, and let your
scripts/tool handle the activation.
It seems what you ask for, is a more elaborate policy about how
profiles can autoconnect, and moreover, how they conflict. That would
be an interesting feature, but relatively hard to design correctly.
More information about the Networkmanager