Anbox apps not working

  • Hi Everyone,

    I was able to successfully install anbox on my Oneplus One (Ubuntu 16.04). I was also able to pull apk's from my android device and push them to my ubuntu-touch device. I tried the following two methods of installation:

    • adb install my_app.apk
     sudo mv my_app.apk ~/anbox-data/data
    $ sudo lxc-console -ndefault -P /home/phablet/anbox-data/containers -t0
    $ cd ../data && pm install my_app.apk

    Both methods successfully install my_app.apk and it shows up in the app scope once I refresh it (with a swipe down). However, when I launch the newly installed apps, they just hang on the opening. For instance, spotify just shows the spotify logo. Hopper just shows a white background.

    Perhaps these were not installed successfully, but from the instructions I could find, these were the recommended ways. I'm aware that anbox is extremely experimental at this point so perhaps these apps just don't work. In that case, has anyone been able to successfully install and deploy an android app on a OPO? If so which one?

    I was curious to know, in addition to the above, if there were another way to install android apps in anbox? Thanks in advance.

  • @aclifton314 I use a Nexus 5, so I suppose is not really comparable, but in my case I had tried several android apps and some of them hung on the opening as well.
    What I seemed to work for me was to try different .apk versions, and magically (?) other versions worked.
    In the specific case of Spotify, I use the apk version 8.5.20, if you want to try 😉

  • @ThrillSeeker I will definitely try that. How were you able to download certain versions of an app? Right now I download the app on my android device from the Google Play store then transfer it to my OPO.

  • Here is a tutorial from Wayneoutthere:

    C - Getting And Installing Apps
    Go to
    Get apps on desktop (easier), rename each apk to something easy to type and remember. eg. kakaotalk 1204924012401aristar.apk -> taco.apk
    With your favourite method (Nautilus?) Move via USB over to UT device in ~/Downloads
    connect again, "adb shell"
    "cd Downloads"
    "sudo mv *.apk ~/anbox-data/data/." (yes the period should be there)
    run this (weird) , "sudo lxc-console -ndefault -P /home/phablet/anbox-data/containers -t0" (last thing is an
    (You are now IN anbox container)
    "cd data"
    "pm install APPNAME.apk" , do for each apk. Wait a few seconds between each. Output in terminal will be weird and scary but don't worry usually.
    When done installing, do CTRL+A , then press q
    Refresh/poll the ubuntu touch app scope (pull down), apps should show up. Aigoo

  • @Krille Thanks for the tutorial. I followed the instructions and let it run over night. I woke up this morning to

    EntropyMixer: writing entropy...

    Presumably it's still installing? There were also a bunch of KernelUidCpuTimeReader: failed to read uid_cputime: /proc/uid_cputime/show_uid_stat No such file or directory

  • @aclifton314 Oh no idea, maybe wrong filename or just reboot and try again would help?

  • @Krille roger that. I'll mess around with it this weekend and report back.

    As an aside, specifically with respect to Spotify, I asked a similar question on the ubports anbox github. I recall a user on here (@Ingo, I believe) saying he was able to get spotify working on his Fairphone2. From what I can gather, given two devices run the same linux kernel, if it works on one it should theoretically work on the other (all things being equal).

    I'll see if I uncover anything enlightening that might be useful to get further to the root of the issue. Thanks again for everyone's help!

  • Unfortunately I don't have Spotify on my UT phone anymore so I can't check which version it was.

    When I try to get the APK from my Lineage phone now, I get this

    > adb shell pm list packages | grep spotify
    > adb shell pm path                                                              package:/data/app/

    I'm pretty sure back when I had it working on UT, it was a single APK file, not a split APK like this.

    I guess this won't work anymore 😞

  • I was wrong, it still works 😉

    1. Pull the APKs of your Android phone
    Connect your Android phone with USB debugging enabled.

    Get the package name of Spotify:

    > adb shell pm list packages | grep spotify

    Get the file location of the APK:

    > adb shell pm path

    Pull all the files to your computer:

    adb pull /data/app/ spotify.base.apk
    adb pull /data/app/ spotify.split_config.armeabi_v7a.apk
    adb pull /data/app/
    adb pull /data/app/ spotify.split_config.xxhdpi.apk

    2. Push the APK files to the UT phone
    Now disconnect your Android phone and connect your UT phone with USB debugging enabled.

    Push the files to the phone:

    adb push spotify* /home/phablet/Downloads

    3. Install the APK files on the UT phone
    While the UT phone is still connected via USB, first open a shell on the phone:

    adb shell

    Next commands are executed on the phone!

    cd Downloads
    adb install-multiple -p spotify*

    That's it!

    Unfortunately the new app drawer (which has replaced the old app scope) doesn't refresh and I don't know how to refresh the installed app icons manually.
    So it seems you have to reboot the UT phone before you can tap on the Spotify icon and start listening to music.

  • @Ingo Thanks for those details. Whenever I run the command adb install-multiple -p spotify* on my device I get:

    Failed to create session
    Error: java.lang.IllegalArgumentException: Missing inherit package name

    However, when I did just adb install-multiple spotify*, that seemed to work successfully. I restarted the UT device and it all seems to work! Thanks a bunch for the assistance everyone!

Log in to reply