How to do mobile broadband from command line

Dan Williams dcbw at redhat.com
Fri Mar 14 09:47:36 PDT 2014


On Fri, 2014-03-14 at 11:42 +0100, Aleksander Morgado wrote:
> Hey Yegor,
> 
> On Fri, Mar 14, 2014 at 11:34 AM, Yegor Yefremov
> <yegorslists at googlemail.com> wrote:
> > I have some questions regarding NetworkManager<->ModemManager integration.
> >
> > 1. how do I create a connection in nm, that is later referenced by its
> > id in "nmcli connection up"? I saw examples with "edit" command but nm
> > 0.9.8.8 says: Error: 'con' command 'edit' is not valid.
> >
> 
> Try using nm-connection-editor (GTK+ based UI app). Don't know in
> which version the nmcli support for editing connections was added.
> Dan?

The direct edit functionality was added to NM 0.9.9, so no, it's not
available in 0.9.8 and lower.

For example, here's a minimal WWAN connection, which should go
into /etc/NetworkManager/system-connections/ and be mode 0600 and owned
by root:

[connection]
id=wwan
uuid=15d742f1-2b5a-421e-9f27-fcb1fc26d72c
type=gsm
autoconnect=false

[ipv4]
method=auto

[gsm]
number=*99#
username=blahblah
password=blahblah
apn=internet

Then you can use "nmcli con up wwan" and "nmcli con down wwan".

Dan

> > 2. nm invokes daemon() to detach from console, i,e. become a daemon in
> > the start scripts. Is this functionality planned for mm? Or should one
> > only use start-stop-daemon or alike?
> 
> Yeah, NetworkManager becomes a daemon by default unless --no-daemon is
> used, ModemManager never becomes a daemon by default. You can likely
> use start-stop-daemon for that if you want; or rely on DBus
> auto-activation; or let systemd handle the lifecycle for you, whatever
> you prefer. I don't think we'll add the daemonizing logic within MM,
> truth be told, not sure how helpful will that be.





More information about the ModemManager-devel mailing list