UT is ram-hungry



  • At the present, I have only one app opened (morph) and just this page opened on it. And yet top tells me my phone (FP2) is currently using circa 95% of it's 2gb memory. I thought I had got rid of random reboots by patching the firmware a while ago, but I had three (unity8 reboots, that is) reboots in ten minutes of checking mails and surfing the internet. I was coming to terms with the idea of using the FP2 without flashlight but this renders it fully unusable. How come ? I've had Ubuntu 16 desktop versions running better on computers with that much ram (and I mean DDR2 crap ) - it didn't run seamless but at least didn't crash the Gui ! plus the swap partition is almost always full which I guess means swapiness is set on 10 which given the default size of the swap partition is ludicrous. I will eventually set a more appropriate swap size and trigger myself but my understanding is that ut should stay read-only and I would like to know the rationale behind these settings... But, mostly I wonder: why this ram usage ? and why does it lead to unity restarting ? What I like about Linux in general is its conservative use of ressources and this looks weird to me.



  • I have noticed this too. Ubuntu on my desktop with Firefox and VSC running has a similar footprint to UT freshly booted.

    I assume it has to do with having an Android system running underneath Ubuntu on the phone. Both of those things need ram as opposed to just one on the desktop.



  • I've noticed that the new UT is more resource-hungry than the old version (I'm on dev). Particularly on the browser (which flashes through black sometimes) and uMastonauts.

    The battery drain has been much better recently though... perhaps the devs have optimized things a bit...?



  • I have a 2GB swap partition and I survive with many programs opened and prevented from suspending. It rarely reboots now.



  • @mihael Ok then, all hail the swap ! I'll do that. But it highlights the two main seemingly inextricable problems of touch: being read-only, and depending on android...



  • @dobey "Phones/tablets do not have much (if any) swap enabled by default, because flash based storage has a limited number of writes in its lifetime, and using swap on such storage can greatly reduce the lifespan of the storage when apps get shoved into swap" Here is why I don't wan't to do it in the end. I bought a fairphone to have a low impact on the ecosystem. If I kill memory just to be able to use the phone it just means the OS is not ready, and this phone is going to sit still until this founds a fix...



  • @Emphrath I have been using it like this for more than three years now...



  • @mihael Nice ! But modifying swap settings involves remounting the filesystem in writable, right ? Did you have to reinstall everything after each new OTA or did it go smoothly ?



  • @Emphrath Everything smooth...



  • For what it is worth, with the new changes to Unity8 in the dev channel it seems UT is less ram hungry. Plus I'm getting far fewer OOM crashes than on stable. Not sure what has changed, but the OS keeps getting better.



  • @Emphrath so the dependency on Android is something we cannot change if we want to have devices out there that work.
    As you might know, so far no hardware vendor came up with any device that is on par with an Android-Hardware device regarding power consumption, robustness/stability of the drivers and in the same way performance for nice UX and effects (something you need for consumers at a certain point).

    Librem5 is not finished with their power management issues and a lot of doubt if they ever will be - In fact sending the CPUs to stop in 90% of the time of operation creates huge problems when events occur. Thats nothing that will be easy achieved.

    Pinephone we dont know yet, but could have similar issues. So, as it seems we do not have any alternative hardware at end, do you suggest to have no hardware at all is better than to have one that is backed by low-level Android?

    As for the 2nd part, being read-only in the root file system has 2 main reasons, which were reiterated in the forum, in the supergroup so many times already:

    1. UT doe not use apt-based upgrading since it should be superstable so that the delivered binaries will 100% fit together - you dont want to install one package with apt that in the next moment crashes your display manager and you cannot use your phone anymore. Its not a PC! You cannot just switch to text mode, connect a wired keyboard and fix it yourself. Mobile devices have a much higher level of demand for resilience than your desktop PC. Also, image-based upgraded can use deltas to help downloading only whats changed in an efficient way - No need to run apt and compare all the lists of stuff.

    2. Security: Unlike a normal Linux distro a mobile OS invites a lot of 3rd party apps to the system. In fact its the whole point of it: Your Debian and Ubuntu deliver 90% of what you need from their repos, but in UT its maybe 10%. So with so many 3rd party code enabled you definitely do not want to have a writable root partition and also the Android container is protected that way.

    People please stop thinking that UT is "Ubuntu on a phone", its not and it also makes no sense to demand it. If this would be so desireable, Canonical would have done it, and not scratch their head to implement this much different logic.


Log in to reply