UBports Robot Logo UBports Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Readonly Filesystem (Nexus 5) and broken power button

    Scheduled Pinned Locked Moved Google Nexus 5
    31 Posts 5 Posters 4.2k Views 2 Watching
    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.
      • C Offline
        Creuzdos
        last edited by Creuzdos

        Here is a little update.
        Day 3 : I have installed multiple times android, paranoid android and ubuntu touch
        I have used twrp recovery img and modified /system/usr/keylayout/gpio-keys.kl
        as I said yesterday it works absolutely as expected on paranoid android but everytime I come back to ubuntu-touch (even when I uncheck every checkbox inside the ubport-installer )
        the file /system/usr/keylayout/gpio-keys.kl is the default read-only file.

        If anyone has a tip to help me set the /system partition writable or replace this file one way or another. If it is not possible, what i'm going to do next is probably go try paranoid android to play with in the next few days / weeks.

        Is it possible to get a zip with the ubuntu touch ROM for NEXUS 5, so i can install it through twrp like i did with the other android systems ?

        Thank you all for your help and keep up the good work.

        AntiDroidA KenedaK 2 Replies Last reply Reply Quote 0
        • AntiDroidA Offline
          AntiDroid @Creuzdos
          last edited by

          @creuzdos I may be wrong but couldn't you boot into TWRP, use

          adb push path/to/new/file /sdcard
          

          from your host to get the new file on the device and then use the file manager under advanced in TWRP to replace the one that keeps being over written with the one you placed in /sdcard?

          OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
          OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

          KenedaK 1 Reply Last reply Reply Quote 0
          • KenedaK Offline
            Keneda @AntiDroid
            last edited by

            @antidroid
            Go to \system with file manager, after image made writable with UTTT, then check infos for folders and files in here : all is read only, you will not be able to paste anything here, you can copy files from, then paste in writable folder like "downloads", but that's all.

            2015-2023 : Meizu MX4 ☠️⚰️✝️
            2023-2024 : Nexus 5 ☠️⚰️✝️
            2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
            🇲🇫🇬🇧

            AntiDroidA 1 Reply Last reply Reply Quote 0
            • KenedaK Offline
              Keneda @Creuzdos
              last edited by Keneda

              @creuzdos said in Readonly Filesystem (Nexus 5) and broken power button:

              @dobey In recovery mode, the /system directory contains only a lost+found directory and i can't find the file /system/usr/keylayout/gpio-keys.kl

              Did you try acces this file with ADB from recovery after enabling Developer Mode from system settings under Ubuntu Touch? (System settings -> About -> Developer mode -> enable -> adb reboot recovery -> adb shell)

              2015-2023 : Meizu MX4 ☠️⚰️✝️
              2023-2024 : Nexus 5 ☠️⚰️✝️
              2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
              🇲🇫🇬🇧

              1 Reply Last reply Reply Quote 0
              • AntiDroidA Offline
                AntiDroid @Keneda
                last edited by

                @keneda said in Readonly Filesystem (Nexus 5) and broken power button:

                @antidroid
                Go to \system with file manager, after image made writable with UTTT, then check infos for folders and files in here : all is read only, you will not be able to paste anything here, you can copy files from, then paste in writable folder like "downloads", but that's all.

                That I why I gave instructions for doing it via the file manager in TWRP. Because in TWRP everything can be written over.

                OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
                OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

                KenedaK 1 Reply Last reply Reply Quote 0
                • KenedaK Offline
                  Keneda @AntiDroid
                  last edited by Keneda

                  @antidroid said in Readonly Filesystem (Nexus 5) and broken power button:

                  That I why I gave instructions for doing it via the file manager in TWRP. Because in TWRP everything can be written over.

                  First sorry i misreaded you and though you were asking him to do that with uTouch file manager.

                  Second, are you sure he will be able to do that without enabling dev mode first?

                  2015-2023 : Meizu MX4 ☠️⚰️✝️
                  2023-2024 : Nexus 5 ☠️⚰️✝️
                  2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
                  🇲🇫🇬🇧

                  AntiDroidA 1 Reply Last reply Reply Quote 0
                  • AntiDroidA Offline
                    AntiDroid @Keneda
                    last edited by

                    @keneda Once you have the bootloader unlocked I thought you could do whatever you want to the file system once booted into TWRP and that is why people want to encrypt stuff. But I have not modified actual UT files this way so you may be correct that you need to enable developer mode before entering TWRP. I also do not know how you would find the actual location since in TWRP you see the entire file system including Android bits and partitions. And again I may be entirely wrong.

                    OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
                    OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

                    KenedaK 1 Reply Last reply Reply Quote 0
                    • KenedaK Offline
                      Keneda @AntiDroid
                      last edited by Keneda

                      @antidroid I don't have anything in recovery (no twrp nor any other menu thing), so i don't know neither, only way on MX4 is adb.

                      We'll see when he answers ^^

                      Edit : if i refer to thread and Dobey, \system is part of androïd stuff.

                      2015-2023 : Meizu MX4 ☠️⚰️✝️
                      2023-2024 : Nexus 5 ☠️⚰️✝️
                      2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
                      🇲🇫🇬🇧

                      AntiDroidA 1 Reply Last reply Reply Quote 0
                      • AntiDroidA Offline
                        AntiDroid @Keneda
                        last edited by AntiDroid

                        @keneda Sorry I assumed most people flashing things would know about TWRP.

                        TWRP stands for Team Win Recovery Project and they have a recovery for almost every Android device out there. You download the correct TWRP for your device (Check XDA for recommended one) then while in fastboot from the command line you run

                        # change path and TWRP to match your file location and name
                        fastboot boot path/to/TWRP.img
                        

                        It will boot the device into TWRP recovery where you can do all kinds of stuff like flash new roms or edit files or wipe directories. (DO NOT install TWRP when it asks you to. that is for Android only)

                        EDIT: These are the versions of TWRP for hammerhead but you will likely need a certain one that was made for the Android version your UT is based on and by the look of this Halium page. it is Android 5.1 . This where you need to check XDA to find out which one goes with Android 5.1.

                        OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
                        OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

                        KenedaK 1 Reply Last reply Reply Quote 0
                        • KenedaK Offline
                          Keneda @AntiDroid
                          last edited by Keneda

                          @antidroid
                          I know XDA, i've been a long time there for that device : https://forum.xda-developers.com/f/lg-optimus-3d.1073/
                          That's because of that device not being updated by LG that i dumped androïd and went to uTouch with my actual MX4.
                          I know TWRP, there is not one for MX4.

                          I have a canonical MX4, made for utouch, with bootloader unlocked (unlike ALL others MX4, wich bootloader is quite un-unlockable), and specific custom recovery (not the same as flyme one).

                          In this canonical custom uTouch MX4 recovery, nothing else than adb is possible.

                          I will not try to do anything to this phone software, other than updating uTouch, i don't want to mess with it.

                          Anyway, we're going off topic.

                          2015-2023 : Meizu MX4 ☠️⚰️✝️
                          2023-2024 : Nexus 5 ☠️⚰️✝️
                          2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
                          🇲🇫🇬🇧

                          1 Reply Last reply Reply Quote 1
                          • C Offline
                            Creuzdos
                            last edited by

                            Update Day 4 : I installed e OS (from e foundation). Everything works well as expected.
                            But when i read @AntiDroid 's comment I had to try to push the file with TWRP.
                            So I wiped eveything again, reinstalled UT using ubports-installer, went to developper mode, reboot in recovery with TWRP.
                            And ... I can push my gpio-keys.kl to /sdcard but when i go to the file manager in TWRP, again i can only see a lost+found directory under /system when i mount System in TWRP (i tried different versions of TWRP).

                            AntiDroidA 1 Reply Last reply Reply Quote 0
                            • AntiDroidA Offline
                              AntiDroid @Creuzdos
                              last edited by

                              @creuzdos Sorry to hear it did not work as expected but I have had issues after running /e/os on my Oneplus 6T. The 6T uses A/B slots so may be different but I had to install a stock Android before UT to get everything to work. This makes me wonder if maybe /e/os has done something strange to the partitions. If you are up to it I would try stock Android then UT then see if things are as you expect them to be.

                              Have you simply tried to put the file where you expect it to be even if it doesn't already exist? It may be that it looks in multiple locations for the file and it will work from where you expect it to be?

                              OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
                              OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

                              C 1 Reply Last reply Reply Quote 0
                              • C Offline
                                Creuzdos @AntiDroid
                                last edited by

                                @antidroid said in Readonly Filesystem (Nexus 5) and broken power button:

                                Have you simply tried to put the file where you expect it to be even if it doesn't already exist? It may be that it looks in multiple locations for the file and it will work from where you expect it to be?

                                Yes i did adb push gpio-keys.kl /system/usr/keylayout/
                                It created the different directories and pushed the file but after a reboot on UT, the /system was exactly the same.
                                I wonder if there is a /system used by TWRP and a /system used by UT.
                                I don't know, I may not fully understand what I've done through these 4 days.
                                Anyways I learnt a lot of things playing with ROMS and recovery imgs. And the result is ... I 'm giving up Ubuntu touch for now but I have a fully fonctionning e/OS where I can lock / unlock the screen with my volume buttons. I did not reach my original goal but I am already satisfied with what I have done 🙂
                                This is thanks to you guys.

                                AntiDroidA KenedaK 2 Replies Last reply Reply Quote 0
                                • AntiDroidA Offline
                                  AntiDroid @Creuzdos
                                  last edited by

                                  I have often wondered if one could make a small circuit that plugged into a micro usb port to wake the device. It would be tiny, just a capacitor and diode to store I tiny bit of power from the usb port while it is awake then a tiny button to send that same power back to the port to wake it. If the usb port does not provide current while on it could also use a small battery or super capacitor and work inline with a usb cable while charging the phone to charge itself for the next days use.

                                  If enough people were interested in such a device I could prototype a PCB. The major cost from where I live though would be shipping. I could have thousands of tiny PCBs made for a couple of dollars and components would be pennies a piece but shipping to me makes that cost jump by 2000%. Then shipping each one would cost $20+ each to ship to someone outside my country using reliable traceable shipping.

                                  So if anyone lives in a manufacturing hub with good outgoing shipping systems that make it easy for small businesses to ship you may want to look into making these.

                                  OnePlus One with UT OTA-15 daily driver. I would be testing the Halium 7.1 port if I could roll back to OTA-15
                                  OnePlus 6T PostmarketOS Custom Gnome on Mainline Kernel

                                  1 Reply Last reply Reply Quote 0
                                  • KenedaK Offline
                                    Keneda @Creuzdos
                                    last edited by Keneda

                                    @creuzdos
                                    Did you try with dev mode on in uTouch then with adb shell?

                                    And alternatively i just saw an other thread that could help you with terminal inside uTouch.
                                    I'll quote here :

                                    @craig said in How to install PIA VPN on UT (Working!):

                                    When running the script, you may get a message that the script was not able to write to /etc/openvpn. If so, do this before you execute the script:

                                    sudo -i
                                    sudo mount -o remount,rw /
                                    sudo chmod 777 /etc/openvpn
                                    exit
                                    

                                    After you run the script, set permission back:

                                    sudo chmod 755 /etc/openvpn
                                    

                                    You could try the chmod 777 with \system folder.

                                    2015-2023 : Meizu MX4 ☠️⚰️✝️
                                    2023-2024 : Nexus 5 ☠️⚰️✝️
                                    2024-***** : FPOS Fairphone 5 waiting UT for freedom 😉
                                    🇲🇫🇬🇧

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