Arguing with ofonod, neverending story

Now I’m a fresh user of a Xperia 10 III, and the story continues. As ever, for 8 years now.

Background: living in Germany wich has, as well nown, a poor mobile network infrastructure. Oftenly, some networks are available, but all of them with weak signal strength.

Since the beginning with the Jolla phone something goes wrong under this conditions. The phone tries to change the connections, chokes on sth., normally gets it, but in some cases eventually gives up and leaves me disconnected.
Back in the days I had to restart the ofono service manually then and need this to do that often, that there was an app once in one of the stores (so I guess I wasn’t the only one with this problem).
Later, with the Xperia X, I used a script, see here.
(It might be noteworthy at this point that on the X even journald crashed and disappeared…)

Now, with the more powerful Xperia 10 III (without any manipulations so far) there are still short disconnects. But the connection ‘respawns’, and all is well… all? No. It’s not.
Something accumulates, and after a couple hours I’ll find the ofonod process using a significant amount of CPU power. This morning it was 13% constantly. Device was warm.

So, the well known procedure: systemctl restart ofono
Not surprising: ofonod’s cpu load went back to ~0%, according to Lighthouse. Phone fully working, battery use back to normal.

Disappointing, somehow. First, there is (must be) some basic bug in the OS that impedes the usage of the device as phone. Literally. It’s not just there, it’s there for 8 years. Constantly. But it’s not reproducable, unless you live in Germanys low mountain range.
And now I don’t even know anymore how to reset the service automatically like I did with the X.
I wonder what’s next.

Any useful hints appreciated.

Michael

I´m also living in Germany and using blau.de (Eplus) on my Sony X Compact with newest SailfishOS 4.4.0.64. I experienced the ofono-cpu-guzzling since the first version i using that Device (4.1).

It seems it occurs once a session and after perform “systemctl restart ofono” it doesn´t seems to happen until warm/cold reboot.

It´s also hard to find what triggers this. There is another Thread here in the Forum where we try to find the reason for it Ofonod CPU guzzling

What is not working with your script, i treid it and got a message about missing dbus plugin. Installed python3-dbus package and script seems to work.

It’s not about my script. The script checks the connection state, not the cpu guzzling. Thanks anyway.

Okay, thanks, didn’t see this. I’ll watch it.

Just asking because you wrote “And now I don’t even know anymore how to reset the service automatically like I did with the X.”

Could you explain waht your script does exactly?

It tried to find out the mobile connection state and restarts the ofono service, if bad. One of the problems was, that the device indicated a mobile carrier available, but was disconnected anyway. The script had to be called frequently by an external instance (cron or timer) to take effect.
If a connection is working, the script does nothing. Detecting cpu guzzling is a different thing and has nothing to do with the script, that’s why I moaned. :crazy_face:

1 Like

Ah, ok. Thank you for the explanation.

There’s this: https://github.com/sysstat/sysstat it compiles nicely on the XIII (probably worth adding to chum)
pidstat can give you average cpu usage for a process over given time period:

pidstat 40 -ru -p <pid>

In this example over 40 seconds. Could compare when ofono is non-guzzling vs when it’s guzzling to trigger the original script maybe?

2 Likes

Looks promising. Thanks!

FYI I have pushed sysstat to chum yesterday.

4 Likes

Just curios - what is your network preference 4G/3G/2G/auto?

I was loosing connection when I had 4G and since I put it to 3G some years ago I do not have any issues. I am living in Austria, which has a better coverage than Germany, but still it might be related to your issue.
What I found out that phone stopped ringing (may be because of ofono - never had time to investigate). This happened when I move from one area where I had 4G in another area where there was poor 4G coverage, so the issue seemed to be related with switching network. It was Sailfish 3.x back then.

4G. 3G is now deprecated here and going out of service.
Yes, I’m also sure it is related to switching networks. I live in a small basement flat, and “Situations”-app once counted more than 20 cells (for defining “home-zone”), but all are weak. I’d say I’m crossing at least 5 cells when just going from terrace to bathroom, even when it’s less than 8 meters.
(Interestingly, the 10 III seems to have less good connectivity compared with the X. No network on the sofa anymore… :unamused: )

An observation I made is the following (both phones on SFOS 4.4.0.64):

While sleeping I switch my phones to flight mode. In the morning I turn off flight mode.

The Sony Xperia 10 searches long for mobile network (up to 1 minute), then connects to 2G network and stays there until I switch on data connection. On switching on data connection, X10 changes to 4G.

The Volla phone, in this situation, connects immediately to 4G and needs only 1-2 seconds to find the network.