Re: disable auto-connect



On Tue, 2018-01-02 at 21:00 +0100, Belisko Marek wrote:
Hi Thomas,


One more question maybe. When I set some configuration for e.g. wifi
network it is possible to overwrite existing connection
configuration?

I think I don't understand your question :)

If you have a connection (profile), you can modifiy it. Via libnm API
for example via nm_remote_connection_commit_changes_async().

See also the python examples in
https://cgit.freedesktop.org/NetworkManager/NetworkManager/tree/examples/python/gi
They use libnm via GObject introspection.

Or see what nmcli does:
https://cgit.freedesktop.org/NetworkManager/NetworkManager/tree/clients/cli/connections.c?id=b936ccd2837199d5851388122c2e44951bf20012#n7938


I tried to use same name for connection but it seems that NM always
create new one with UUID at the end.


It is possible somehow to delete previous configuration (stored in
/etc/NetworkManager/system-connections/? I basically always want to
use only one even user will setup connection to 2 different wifi
networks. I'm using libnm for my program. Thanks.

yes, you can also delete profiles. See the D-Bus API
https://developer.gnome.org/NetworkManager/stable/spec.html
or libnm API:
https://developer.gnome.org/libnm/stable/index.html

most imporantly in this case, the functions on the NMRemoteConnection:
https://developer.gnome.org/libnm/stable/NMRemoteConnection.html


best,
Thomas

Attachment: signature.asc
Description: This is a digitally signed message part



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]