dhcpcd: raw-ip support
Dan Williams
dcbw at redhat.com
Wed Aug 21 21:16:45 UTC 2019
On Mon, 2019-08-19 at 16:20 +0200, Yegor Yefremov wrote:
> On Mon, Aug 19, 2019 at 2:57 PM Bjørn Mork <bjorn at mork.no> wrote:
> > Yegor Yefremov <yegorslists at googlemail.com> writes:
> > > On Mon, Aug 19, 2019 at 10:49 AM Bjørn Mork <bjorn at mork.no>
> > > wrote:
> > > > Yegor Yefremov <yegorslists at googlemail.com> writes:
> > > >
> > > > > I have a project where I'm using dhcpcd client. It is working
> > > > > without
> > > > > any problems with older modems like Quectel UC20 etc. But now
> > > > > we want
> > > > > to switch to SIM7600G-H and it is working in raw-ip mode. So
> > > > > far only
> > > > > udhcpc can handle such MAC address-less interfaces.
> > > > >
> > > > > Do you know what is so special about udhcpc compared to other
> > > > > DHCP
> > > > > clients?
> > > >
> > > > It's mostly L2 agnostic, meaning that it will work on non-
> > > > ethernet
> > > > interfaces.
> > > >
> > > > "Fixing" this for other clients isn't really that hard, if
> > > > required. I
> > > > did this proof-of-concept for ISC dhclient for example:
> > > >
> > > >
> > > > https://mail.gnome.org/archives/networkmanager-list/2015-December/msg00044.html
> > >
> > > Thanks for the patch. But looks like it hasn't been upstreamed
> > > yet :-(
> >
> > Upstreaming anything to ISC is not possible in my experience. See
> > https://lists.isc.org/pipermail/dhcp-users/2011-August/013926.html
> >
> > Or at least not worth the extra effort required.
> >
> > And I don't think raw-ip support is all that useful, to be
> > honest. The
> > DHCP server in the modem is a hack anyway. You should use the
> > modem
> > management channel to get IP config from the modem. I.e. QMI.
>
> How one supposed to set the IP configuration via QMI? I can connect
> using:
>
> qmicli --device=/dev/cdc-wdm0 --device-open-proxy
> --wds-start-network="ip-type=4,apn=www.bla.com"
> --client-no-release-cid
>
> and get IP config via:
>
> # qmicli -d /dev/cdc-wdm0 --device-open-proxy
> --wds-get-current-settings --client-cid=17
> [/dev/cdc-wdm0] Current settings retrieved:
> IP Family: IPv4
> IPv4 address: 10.33.151.131
> IPv4 subnet mask: 255.255.255.248
> IPv4 gateway address: 10.33.151.132
> IPv4 primary DNS: 62.109.121.17
> IPv4 secondary DNS: 62.109.121.18
> MTU: 1430
> Domains: none
>
> How can these settings be automatically applied to wwan0? Am I
> missing
> related MM options here?
The thing that tells ModemManager to start the connection is usually
what is responsible for applying the IP configuration. That would
either be something like NetworkManager or custom scripting.
Dan
> Yegor
>
>
> > But DHCPv6 support on PPP links is something else. It's an
> > essential
> > feature for a DHCPv6 client. As you may or may not know, IPV6CP is
> > very
> > different from IPCP when it comes to address negotiation. It will
> > only
> > negotiate an interface-id and leave the remaining address config to
> > the
> > normal autoconf protocols. I.e. you need to run SLAAC and/or
> > DHCPv6 on
> > the link if you want a global address.
> >
> > Somewhat off-topic here. Unless you have a modem with support for
> > IPv6
> > over PPP, which I recently learned actuall exists:
> > https://forum.openwrt.org/t/ipv6-with-ppp-with-3g-modem/39071
> >
> > I'll stop babbling now
> >
> >
> > Bjørn
> _______________________________________________
> ModemManager-devel mailing list
> ModemManager-devel at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/modemmanager-devel
More information about the ModemManager-devel
mailing list