Active PDP context and DHCP acquired IP address

Hi Everyone,

I am facing an “out of sync IP address” issue with EM7455 under Linux.

The interface IP address gets acquired by udhcpc. Most of the time the acquired IP address matches with the IP address shown in “Active PDP Context”.

But there were some instances of mismatch in uchcpc acquired IP address and the IP address shown in “Active PDP Context”.
This mismatch results in communication failure.

IP Address: Subnet Mask:
Active PDP Context:

I have tried “AT!CUSTOM=“DHCPRELAYENABLE”,1”. I am not sure if this is the right solution.

Please provide your inputs.


Does the network operator assign new ip address from time to time?

This prepaid SIM does not have any static IP address assigned. By interpreting the Active PDP result it seems that the network operator assign a new IP address time to time. I want to maintain an instant sync of an IP address change. (exact match of Active PDP IP address to DHCP client acquired IP address)

When you found mismatch, if you use udhcpc, can it solve the problem?

udhcpc is always running. The problem gets resolved after few minutes or after the operator changes its IP address. I want to reduce this delay and somehow minimize the frequency of the IP address change.

Do you mran during the few minutes, at+cgpaddr has changed ip address, but udhcpc still get old ip address?

Then you can’t use DHCP. The DHCP mapping is bound to be imperfect. The address your operator assigns has no guranteed lease time. It is valid as long as the session lasts, and is immediately invalidated when the session ends. You can’t model this with DHCP (at least not without a lot of additional stuff around the DHCP session). The modem has to give the DHCP client some fake, short, least time. But however short - there will be the sort of breakage you describe

So don’t use DHCP. Get the address from the connection manager, and reconfgure your IP interface whenever the session is (re-)established.

In this case of static IP setting, How do I monitor the Cellular IP address change? Do I need to continuously check the Active PDP context?

Do you see any network dropped notification when setting at+cgreg=1