anbox on antiX

Forum Forums General Software anbox on antiX

  • This topic has 16 replies, 5 voices, and was last updated Feb 24-9:43 pm by Anonymous.
Viewing 15 posts - 1 through 15 (of 17 total)
  • Author
    Posts
  • #41621
    Member
    pipfranto

      has anyone managed to get this working?

      #41627
      Member
      seaken64
        Helpful
        Up
        0
        ::

        Can you tell us more about what you have done do far?

        Can you explain to us what the software is supposed to do?

        Have you investigated any alternatives?

        Seaken64

        #41629
        Member
        olsztyn
          Helpful
          Up
          0
          ::

          Can you explain to us what the software is supposed to do?

          If I understand your question is about the actual purpose of installing anbox (Android Box) on antiX, which I am also wondering what the purpose would be unless access to laptop hardware is mapped in such anbox, so android applications have sound, video, access to microphone, etc.
          If so then it might actually open some possibilities and antiX could be the best Linux for this thanks to least resource requirements…

          Live antiX Boot Options (Previously posted by Xecure):
          https://antixlinuxfan.miraheze.org/wiki/Table_of_antiX_Boot_Parameters

          #41630
          Member
          pipfranto
            Helpful
            Up
            0
            ::

            so far i have managed to install the required kernel modules (https://github.com/anbox/anbox-modules) and installed the program. i am starting the daemon manually and it seems to work with the following command

            sudo anbox container-manager –data-path=/var/lib/anbox

            the actual program itself wont run though, when i run

            anbox session-manager

            it just crashes

            X Error of failed request: BadWindow (invalid Window parameter)
            Major opcode of failed request: 155 (NV-GLX)
            Minor opcode of failed request: 4 ()
            Resource id in failed request: 0x5000002
            Serial number of failed request: 101
            Current serial number in output stream: 101

            i am using proprietary nvidia drivers so this might be the reason.

            anbox enables android to use linux hardware with near native performance, its good for gaming and generally running android tablet apps on a linux system. the alternative would be installing a full android emulator, but this comes with a big performance hit.

            anbox uses snap to install and this requires systemd (this is not an option obviously)

            the aim is to get full support for android games on antiX with all hardware mapped without having to install systemd.

            • This reply was modified 2 years, 7 months ago by pipfranto.
            #41634
            Anonymous
              Helpful
              Up
              0
              ::

              When I researched this at the start of this year (with intent to install f-droid under anbox), I learned that although anbox may (someday) operate correctly on a system without systemd init, libsystemd0 would need to be present (anbox utilizes sd-bus, a systemd component, to access d-bus)… and that so far no one has written an equivalent initscript for sysvinit nor runit, to replace the systemd service management unit.

              search the mxlinux forum for “anbox” to see whether someone has created or discovered a non-systemd solution in recent months.

              #42349
              Member
              pipfranto
                Helpful
                Up
                0
                ::

                would using elogind/libelogind to provide libsystemd0 work? https://github.com/elogind/elogind
                without the sysvinit script the daemon would have to be started manually every time, but antix would still be usable correct?

                #42352
                Member
                Xecure
                  Helpful
                  Up
                  0
                  ::

                  elogind is already being used in antiX. If you cannot get it to work properly, I think there is no possibility.
                  Maybe MX can get it to work, as it has a shared systemd-sysVinit “state”.

                  antiX Live system enthusiast.
                  General Live Boot Parameters for antiX.

                  #42373
                  Member
                  pipfranto
                    Helpful
                    Up
                    0
                    ::

                    i am running on old hardware so i don’t know if mx is an option, does the shared sysvinit systemd state include sd-dbus? the main issue that prevents anbox from running is a dbus error due to the systemd dbus (sd-bus) being needed. I tried using guix to install anbox using the pkill9 guix channel but ran out of space on my system partition. Is there any way to just extract the sd-dbus part out of systemd?

                    #42390
                    Anonymous
                      Helpful
                      Up
                      0
                      ::

                      Today I checked and it seems to me that anbox should be do-able on antiX 19, without any systemd stuffs.

                      I have never previously used it, and am presuming you have, and that you know to separately download an android .img and place the file in the expected location. After installing (sudo apt install anbox), within /lib/systemd/system/anbox-container-manager.service we find:

                      ConditionPathExists=/var/lib/anbox/android.img
                      ExecStartPre=/sbin/modprobe ashmem_linux
                      ExecStartPre=/sbin/modprobe binder_linux
                      ExecStartPre=/usr/share/anbox/anbox-bridge.sh start
                      ExecStart=/usr/bin/anbox container-manager –daemon –privileged –data-path=/var/lib/anbox

                      and within /usr/lib/systemd/user/anbox-session-manager.service

                      ExecStart=/usr/bin/anbox session-manager

                      In the absence of systemd, you could manually run each of the commands or place them within a shell script
                      (adding an end of line ampersand character, to background anbox-bridge.sh) and launch the script as needed.

                      Apparently, launching the anbox session-manager requires superuser privileges.
                      As a sticking point (perhaps), anbox session-manager depends on seeing $XDG_RUNTIME_DIR=/run/user/1000 in the environment… but, for security reasons the default sudoers policy in antiX is configured to drop the user’s env variables.

                      As user “demo” (userid 1000), from a terminal emulator command prompt I ran:
                      $ /sbin/modprobe ashmem_linux
                      $ /sbin/modprobe binder_linux
                      $ /usr/share/anbox/anbox-bridge.sh start
                      $ su -m
                      $ env | grep XDG_RUNTIME_DIR

                      ^—> From this point, you should be all set to launch the anbox session and/or container manager.
                      My blind testing ended here.
                      For further info, refer to /usr/share/doc/anbox/README.Debian

                      ps
                      Even though somewhere in the docs we read “blablah is a systemd service”, I searched the sourcecode and found that’s not the case. When manually launched, only “collect-info.sh” (an ancillary utility script, for debugging) expects find journalctl available. Nothing else within the anbox executables cares about systemd or its components.

                      #42606
                      Member
                      seaken64
                        Helpful
                        Up
                        0
                        ::

                        I run MX on some pretty old machines. I have it on a Pentium-III and a few P4’s. How old is your equipment? I’d give MX a try.

                        Seaken64

                        #42662
                        Member
                        pipfranto
                          Helpful
                          Up
                          0
                          ::

                          i tried the commands manually and got 3 errors:

                          ExecStartPre=/sbin/modprobe ashmem_linux
                          bash: ashmem_linux: command not found

                          ExecStartPre=/sbin/modprobe binder_linux
                          bash: binder_linux: command not found

                          ExecStart=/usr/bin/anbox container-manager –daemon –privileged –data-path=/var/lib/anbox
                          bash: container-manager: command not found
                          [1]+ Done /usr/share/anbox/anbox-bridge.sh start

                          my modules are loaded and the android.img is in /var/lib/anbox/android.img

                          #42694
                          Member
                          pipfranto
                            Helpful
                            Up
                            0
                            ::

                            i ran the script:

                            GNU nano 5.3 anbox-script.sh
                            #!/usr/bin/env bash

                            /sbin/modprobe ashmem_linux
                            /sbin/modprobe binder_linux
                            /usr/share/anbox/anbox-bridge.sh start
                            su -m
                            env | grep XDG_RUNTIME_DIR
                            sudo anbox container-manager –data-path=/var/lib/anbox –daemon
                            /usr/bin/anbox session-manager

                            then in a new terminal:
                            $ anbox launch –package=org.anbox.appmgr –component=org.anbox.appmgr.AppViewActivity
                            [ 2020-10-08 07:21:15] [daemon.cpp:61@Run] Failed to connect to DBus

                            then i put:
                            $ export $(dbus-launch)
                            $ anbox launch –package=org.anbox.appmgr –component=org.anbox.appmgr.AppViewActivity

                            then anbox starts booting up with an android logo and it says “Starting …” but it crashes and i get:

                            [ 2020-10-08 07:24:15] [launch.cpp:214@operator()] Session manager failed to become ready

                            • This reply was modified 2 years, 6 months ago by pipfranto.
                            #42699
                            Anonymous
                              Helpful
                              Up
                              0
                              ::

                              searching, I found similar reports, but no reported solution so far

                              https://www.bountysource.com/teams/anbox/issues
                              .

                              #42701
                              Anonymous
                                #42725
                                Member
                                pipfranto
                                  Helpful
                                  Up
                                  0
                                  ::

                                  After a lot of experimentation, it turns out my hardware is just too old for anbox – it requires SSE 4.2.

                                Viewing 15 posts - 1 through 15 (of 17 total)
                                • You must be logged in to reply to this topic.