UBports Robot Logo

    UBports Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search

    Unsolved How can I share files from my Ubuntu Touch host with Waydroid?

    Waydroid
    4
    13
    558
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • T
      triguy last edited by

      Hello. I am using Ubuntu Touch OTA 24 with the latest Waydroid (installed today). It works decently on my Google Pixel 3a, outside of the home, back, app switcher buttons being out of reach. I primarily installed it to use Signal, along with possibly other social media apps. However, I noticed that user files such as Downloads, Pictures, Videos, etc. do not sync between Ubuntu Touch and Waydroid. I found a Waydroid FAQ article addressing this issue, but it does not work. If I run # ls -a ~/.local/share/waydroid/data/media/0/Pictures, in UT Terminal, for instance, I can see that the files are mounted there. However, Waydroid's file manager cannot see any of these files. Is anyone familiar enough with UT and/or Waydroid to help me sync/symlink or mount folders from my UT host so that Waydroid can see them? I'd love to be able to share a Downloads folder and a Photo gallery. Any help is appreciated!

      Keneda C 2 Replies Last reply Reply Quote 1
      • Keneda
        Keneda @triguy last edited by Keneda

        @triguy
        Check there maybe ^^

        @triguy said :

        I found a Waydroid FAQ article addressing this issue, but it does not work.

        I believe this faq is for waydroid on linux desktop systems, but UT is not one of them, it doesn't work the same way concerning files management and apps (confined), plus waydroid is a particular case, it runs a lineage in a contener.

        2015-Now : Meizu MX4 (Stable) for daily use
        Spare : Nexus 5 (Stable)

        T 1 Reply Last reply Reply Quote 0
        • T
          triguy @Keneda last edited by

          @keneda Thank you. Yeah, it definitely seems to handle the filesystem differently, which is understandable. I'll try the Termux hack for now, I suppose. Thanks again!

          Keneda C 2 Replies Last reply Reply Quote 0
          • Keneda
            Keneda @triguy last edited by Keneda

            @triguy
            You're welcome 😉
            What is the "Termux hack" if that can help other waydroid users ?

            2015-Now : Meizu MX4 (Stable) for daily use
            Spare : Nexus 5 (Stable)

            C 1 Reply Last reply Reply Quote 2
            • C
              chris_bavaria @triguy last edited by

              @triguy
              Hi, can you explain the "Termux hack"?
              Thanks!

              from SFOS 2 UbuntuTouch with Legion5 (Ubuntu/Gnome)

              1 Reply Last reply Reply Quote 1
              • C
                chris_bavaria @triguy last edited by chris_bavaria

                @triguy

                So far I haven't been able to find a way to link Waydroid to UbuntuTouch. This post is still set to unresolved. If someone has posted a solution it would be nice if it could be linked here.

                Tried a lot and came up with the following dirty solution to be able to exchange at least a few files.

                $sudo ln -s /home/phablet/.local/share/waydroid/data/media/0/Download /home/phablet/waydroid/Download
                $ls -la
                lrwxrwxrwx  1 phablet phablet   57 Feb 11 03:45 Download -> /home/phablet/.local/share/waydroid/data/media/0/Download
                chmod -R 777 /home/phablet/.local/share/waydroid/data/media/0/Download
                reboot
                $sudo su
                #cd /home/phablet/waydroid/Download
                #ls
                FilesfromWaydroid.*
                

                What do you think about this idea?

                Edit: I use a script for syncing this folder with sudo rsync -a to a local folder.

                from SFOS 2 UbuntuTouch with Legion5 (Ubuntu/Gnome)

                1 Reply Last reply Reply Quote 0
                • C
                  chris_bavaria @Keneda last edited by

                  @keneda
                  Is this the "Termux hack"?
                  https://forums.ubports.com/topic/7820/share-data-between-ub-and-waydroid/7

                  from SFOS 2 UbuntuTouch with Legion5 (Ubuntu/Gnome)

                  Keneda 1 Reply Last reply Reply Quote 0
                  • Keneda
                    Keneda @chris_bavaria last edited by

                    @chris_bavaria
                    My post ?!?
                    I don't think so lol.

                    2015-Now : Meizu MX4 (Stable) for daily use
                    Spare : Nexus 5 (Stable)

                    C 1 Reply Last reply Reply Quote 0
                    • C
                      chris_bavaria @Keneda last edited by

                      @keneda
                      No, 1 post above from user isndwx 😁
                      Have you tried this "hack"?

                      from SFOS 2 UbuntuTouch with Legion5 (Ubuntu/Gnome)

                      Keneda 1 Reply Last reply Reply Quote 0
                      • Keneda
                        Keneda @chris_bavaria last edited by

                        @chris_bavaria
                        Non i didn't try it.
                        And yes, it looks like it is the "termux hack" thing.

                        2015-Now : Meizu MX4 (Stable) for daily use
                        Spare : Nexus 5 (Stable)

                        P 1 Reply Last reply Reply Quote 1
                        • P
                          patlefort @Keneda last edited by

                          This post is deleted!
                          1 Reply Last reply Reply Quote 0
                          • P
                            patlefort last edited by

                            Adding mount entries to the lxc containers doesn't work properly either because of permission problems. The folder can only be accessed as root inside the container even if all have read and execute permission.

                            I have tried to map user and group id from the container to the host (32011 -> 1023) which seem like it could resolve permission issues but I couldn't make it work.

                            What I did:

                            • Remount root: sudo mount -o remount,rw /
                            • Install uidmap: sudo apt update && sudo apt install uidmap.
                            • Adding a line phablet:1023:1 to /etc/subuid and /etc/subgid. Not sure if it should be a 1 or 0 as I want to map only one id.
                            • Add lines lxc.idmap = u 1023 32011 0 and lxc.idmap = g 1023 32011 0 to /var/lib/waydroid/lxc/waydroid/config. Not ideal because it get reset on reboot.

                            It result in the following error: lxc-start: waydroid: conf.c: lxc_map_ids: 3668 newuidmap failed to write mapping "newuidmap: uid range [1023-1023) -> [32011-32011) not allowed": newuidmap 3312 1023 32011 0. I don't know what is missing.

                            P 1 Reply Last reply Reply Quote 0
                            • P
                              patlefort @patlefort last edited by

                              Update:
                              The correct lines in /etc/subuid and /etc/subgid is root:32011:1.

                              However it still won't work with this error:
                              lxc-start: waydroid: cgroups/cgfsng.c: cgfsng_chown: 1353 No such file or directory - Error requesting cgroup chown in new user namespace.

                              I can't make it work on my desktop either with the same error.

                              1 Reply Last reply Reply Quote 0
                              • First post
                                Last post