OsmAnd on FP4 keeps crashing at startup

Hi there,

I just installed /e/OS on a FP4 and everything is working really fine except OsmAnd, which keeps crashing at startup. On Fairphone’s forum, people with FairphoneOS seem to use OsmAnd successfully so at first sight it looks specific to /e/OS.

Anyone else experiences this?

2 Likes

In general, perhaps. But there are several mentions of OsmAnd not working on the Fairphone 4 with /e/OS there. I’ve seen no workaround or solution so far.

Otherwise (on other Fairphones) OsmAnd works fine with /e/OS. Since it’s not a Google-dependent App it’s rather puzzling why it wouldn’t.


Organic map works

There is so much that crashes on my FP4, i’m actually a little bit shocked.

  • Aegis installing is OK, setting up crashes every time, so not working at all
  • spotify crashes regularly
  • f-droid keeps “hanging” at 2/3 oft the screen after keyboard closes
  • other apps are noticeably too slow responding/loading

I’m not done setting up everything, maybe there will be more.
I also used this phone for some weeks now with the originally installed Android and had absolutley no problems.
I also do the exact same things with same apps and settings than in previous e-installations (3 different phones) for 2 years now and never had such problems.

I’m unsure what the best place is to discuss this? Maybe its me, maybe its my phone but i dont think so right now because of the points mentioned.

correct

not here. all fine

not here. all fine

not here. all fine

2 Likes

please remember; this is the first shot for the FP4
I think that in the following updates will be added.

that’s only if you want to set up additional protection. if you just use it without password or biometrics (which of course is less secure and not an optimal way), you can set it up and make it work.

same here with OsmAnd and Aegis (fresh install FP4 /e/). I also get app-crashes with Signal, when I try to send video. adb logcat gives me similar messages in all cases:

01-17 09:27:09.501 20067 20083 I net.osmand.plu: Clamp target GC heap from 41MB to 36MB
01-17 09:27:09.501 20067 20083 I net.osmand.plu: Alloc concurrent copying GC freed 3561(219KB) AllocSpace objects, 2(44KB) LOS objects, 0% free, 35MB/36MB, paused 26us total 132.838ms
01-17 09:27:09.501 20067 20081 I net.osmand.plu: WaitForGcToComplete blocked Background on HeapTrim for 605.764ms
01-17 09:27:09.502 20067 20111 I net.osmand.plu: WaitForGcToComplete blocked Alloc on HeapTrim for 894.870ms
01-17 09:27:09.502 20067 20111 I net.osmand.plu: Starting a blocking GC Alloc
01-17 09:27:09.502 20067 20067 I net.osmand.plu: WaitForGcToComplete blocked Alloc on HeapTrim for 606.137ms
01-17 09:27:09.502 20067 20067 I net.osmand.plu: Starting a blocking GC Alloc
01-17 09:27:09.502 20067 20111 E AndroidRuntime: FATAL EXCEPTION: RenderingBaseImage
01-17 09:27:09.502 20067 20111 E AndroidRuntime: Process: net.osmand.plus, PID: 20067
01-17 09:27:09.502 20067 20111 E AndroidRuntime: java.lang.OutOfMemoryError: OutOfMemoryError thrown while trying to throw an exception; no stack trace available
01-17 09:27:09.502 20067 20080 I net.osmand.plu: WaitForGcToComplete blocked Alloc on HeapTrim for 613.274ms
01-17 09:27:09.502 20067 20080 I net.osmand.plu: Starting a blocking GC Alloc
01-17 09:27:09.504 20067 20093 I net.osmand.plu: WaitForGcToComplete blocked Alloc on HeapTrim for 171.459ms
01-17 09:27:09.504 20067 20093 I net.osmand.plu: Starting a blocking GC Alloc
01-17 09:27:09.505 20067 20117 I net.osmand.plu: WaitForGcToComplete blocked Alloc on HeapTrim for 175.748ms
01-17 09:27:09.505 20067 20117 I net.osmand.plu: Starting a blocking GC Alloc
01-17 09:27:09.505 20067 20117 E AndroidRuntime: FATAL EXCEPTION: Initializing app
01-17 09:27:09.505 20067 20117 E AndroidRuntime: Process: net.osmand.plus, PID: 20067
01-17 09:27:09.505 20067 20117 E AndroidRuntime: java.lang.OutOfMemoryError: OutOfMemoryError thrown while trying to throw OutOfMemoryError; no stack trace available

With every crash I get the java.lang.OutOfMemoryError.

2 Likes

Did you consider to report it as an issue in gitlab?

can you show what the java vm has in memory limits on the FP4? looks to be 36m

adb shell getprop | grep -P 'dalvik.*(heap|dex)'

I can’t really follow the .mk includes to the fp4 device… looking for vendor repo / common SoC upstream?, I only see the boottime values but obviously it’s loading more. I’m blind.

right you are:

❯ adb shell getprop | grep -P 'dalvik.*(heap|dex)'
[dalvik.vm.dex2oat-Xms]: [64m]
[dalvik.vm.dex2oat-Xmx]: [512m]
[dalvik.vm.dex2oat-max-image-block-size]: [524288]
[dalvik.vm.dex2oat-minidebuginfo]: [true]
[dalvik.vm.dex2oat-resolve-startup-strings]: [true]
[dalvik.vm.dex2oat-updatable-bcp-packages-file]: [/system/etc/updatable-bcp-packages.txt]
[dalvik.vm.dexopt.secondary]: [true]
[dalvik.vm.heapsize]: [36m]
[dalvik.vm.image-dex2oat-Xms]: [64m]
[dalvik.vm.image-dex2oat-Xmx]: [64m]

looks like that could account for a lot of app troubles.

I filed an issue in gitlab now: FP4: Apps crash with AndroidRuntime out of Memory ( java.lang.OutOfMemoryError) (#4649) · Issues · e / Backlog · GitLab

2 Likes

yep, heapsize 512m would be normal. You can mark Rohit in gitlab as he’s done the porting to notice your issue

I wonder what RAM size you have - here it is 8GB
checked memory usage: Avg 2.4 GB of 7.9 GB
Another thing worth mentionig is that I do not use is e-cloud / use my own Mail/Caldav/Carddav
The apps I use the most are browser, (K9) mail, Calendar, Signal, VB (Banking) app, password safe
Nearly forgot I use a non standard Micro G (for contact tracing) - shared by @Cabnedor FP4: Install of microG Exposure Notification fails - #9 by Cabnedor

And all the issues (Aegis, OsmAnd) work perfect here on my FP 4. had not a single crash since I installed

maybe any of this can help

The cause of the issue was identified and the fix is on the way according to the GitLab link given a few posts above.
Until then there’s a workaround given here … DAVx5 and Nextcloud Contacts: OutOfMemoryError - #16 by tcecyk.

2 Likes

News: Today there is a new stable release of e/OS/: with this release OsmAnd on FP4 will run again as we are used to.

3 Likes

This issue now seems fixed for me…