Announcement

Collapse
No announcement yet.

Announcement

Collapse
No announcement yet.

I want Linux reboot to be a reboot to recovery

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    I want Linux reboot to be a reboot to recovery

    If I have Linux booting from recovery and running on a SD card, is there a way to reboot to recovery when Linux reboots? Right now it reboots into Android and I have to reboot to recovery from there.

    #2
    Originally posted by R42owner View Post
    If I have Linux booting from recovery and running on a SD card, is there a way to reboot to recovery when Linux reboots? Right now it reboots into Android and I have to reboot to recovery from there.
    And how will go back to android then?
    There is way to make it to reboot in recovery (you need specially crafted misc partition), but don't see much reasdon for it.
    Try to extract misc partition from any of android upgrades, they boot in recovery first. If you can't, pm me, I will extract one for you

    Comment


      #3
      Here is what i see in android upgrade misc partition (one which boots in recovery at first boot):
      00004000 62 6F 6F 74 2D 72 65 63 6F 76 65 72 79 00 00 00 boot-recovery...
      00004010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
      00004020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
      00004030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
      00004040 72 65 63 6F 76 65 72 79 0A 2D 2D 77 69 70 65 5F recovery.--wipe_
      00004050 61 6C 6C 00 00 00 00 00 00 00 00 00 00 00 00 00 all.............

      I guess only string at 0x4000 is necessary, but you could experiment with it.
      everything else in misc partition is 0.

      Comment


        #4
        Originally posted by mmm123 View Post
        And how will go back to android then?
        There is way to make it to reboot in recovery (you need specially crafted misc partition), but don't see much reasdon for it.
        Try to extract misc partition from any of android upgrades, they boot in recovery first. If you can't, pm me, I will extract one for you
        I don't want the reboot to recovery to become the default boot. I want the Linux reboot to be reboot to recovery without changing the default boot. When powering on, the boot would be to Android in NAND so that I can shutdown to return to Android from Linux and reboot (reboot to recovery) to stay in Linux. Android already has this option in the reboot app but I'm getting the impression that the only way to make Linux reboot to recovery currently is to make it the default setting in the boot procedure.

        Comment


          #5
          Re: I want Linux reboot to be a reboot to recovery

          Why don't use linuxium multiboot? If external sdcard with Linuxrootfs is present it boots in linux, if not, it boots android.

          leolas.
          REMEMBER, YOUR FEEDBACK IS VERY IMPORTANT TO US.
          My devices:
          Minix Neo X7; Minix Neo X8-H , Minix Neo Z64W & Z64 (Sponsored by Minix)
          MK902 & MK902II(Sponsored by RKM)
          Beelink M8B & Beelink R89 (Sponsored by Beelink)
          Tronsmart VEGA S89H (Sponsored by
          Gearbest.com)
          MELE-PCG03 (Sponsored by Gearbest.com) Discount Coupon:MPCG03
          Ainol Intel Z3735 MiniPC(Sponsored by Gearbest.com)
          Thanks to them I can try to support your devices http://freaktab.com/core/images/smilies/wink.png

          Comment


            #6
            Originally posted by leolas View Post
            Why don't use linuxium multiboot? If external sdcard with Linuxrootfs is present it boots in linux, if not, it boots android.

            leolas.
            I like the multiboot procedure but I'm being lazy. I got as far as needing images that I don't have and stopped even though I know there are tools to break apart the image that I have into the required pieces. I also don't have a working recovery image for my K-R42 and am temporarily using the run from SD card in NAND. While I think about how to proceed, I've been trying to build the configuration that I want on my MK808 instead. Frequent reboots because I don't know how to restart various daemons or whatever to test configuration changes to convert from Picuntu or LXDE to Ubuntu desktop is what prompted my request. I'm also reluctant to invest too much time in multiboot since my ultimate goal is to have a workalike to my PC, ie., the K-R42 running Ubuntu desktop in NAND with the yet-to-be-developed AINT (my name for the Android equivalent of WINE even though I haven't thought of a word for the T) for running Android apps. I know the people sharing their work have other goals and I should be doing it myself but it's been over 20 years since I last compiled my own x86 kernel.

            Comment


              #7
              Originally posted by R42owner View Post
              I don't want the reboot to recovery to become the default boot. I want the Linux reboot to be reboot to recovery without changing the default boot. When powering on, the boot would be to Android in NAND so that I can shutdown to return to Android from Linux and reboot (reboot to recovery) to stay in Linux. Android already has this option in the reboot app but I'm getting the impression that the only way to make Linux reboot to recovery currently is to make it the default setting in the boot procedure.
              Still you can make simple program called "setdefaultboot" which makes choice how to boot next time.
              If you want to reboot into linux - write misc partition as I mentioned before and it will reboot into linux. When you want to go back to android, set misc partition with zeros and next reboot will be in linux.
              Still this is just a theory, I removed android from my device long ago, so I can't try if this works as expected.

              Another solution could be to find source (or simply copy) reboot program from android custom roms. It has option "reboot recovery", I guess it will work in linux too.

              Comment


                #8
                Can I put Android on the SD card?

                Originally posted by leolas View Post
                Why don't use linuxium multiboot? If external sdcard with Linuxrootfs is present it boots in linux, if not, it boots android.

                leolas.
                I think I want to reverse the location of OSes and put Linux in NAND and Android on the SD card. I haven't investigated the problems with cloning the Android fs on a SD card but I assume multiboot doesn't really care what is being booted. Are there obstacles to building an Android recovery that boots to the SD card?

                Comment


                  #9
                  Originally posted by R42owner View Post
                  I think I want to reverse the location of OSes and put Linux in NAND and Android on the SD card. I haven't investigated the problems with cloning the Android fs on a SD card but I assume multiboot doesn't really care what is being booted. Are there obstacles to building an Android recovery that boots to the SD card?
                  well in that case you need to build your own kernel for android and give it the correct parameters to boot, change all partitions (user; userdata; cache; etc...) to sdcard. I never did it, but I think that maybe it can be possible, you will have a lot of problems to do it but maybe is possible, too much work for do it.
                  So why you want to run android from sdcard and linux from nand? Sorry but it not make sense for me.
                  If we have a simple way to do something, (thanks to the great work of people like Alok, linuxium, etc...) why you want to complicate?

                  For me there is some options now:

                  You want only linux no android: You can ignore your sdcard and install linux in a external sdcard or install it in your nand and use then external sdcard like a extra storage.

                  You want linux and android: Install android in your nand and linux in your external sdcard, thanks to linuxium multiboot you can select easy the os or you can predefine with one boots.

                  You want only android:
                  ok like the minipc was designed, no need of explanations in this option.

                  leolas
                  REMEMBER, YOUR FEEDBACK IS VERY IMPORTANT TO US.
                  My devices:
                  Minix Neo X7; Minix Neo X8-H , Minix Neo Z64W & Z64 (Sponsored by Minix)
                  MK902 & MK902II(Sponsored by RKM)
                  Beelink M8B & Beelink R89 (Sponsored by Beelink)
                  Tronsmart VEGA S89H (Sponsored by
                  Gearbest.com)
                  MELE-PCG03 (Sponsored by Gearbest.com) Discount Coupon:MPCG03
                  Ainol Intel Z3735 MiniPC(Sponsored by Gearbest.com)
                  Thanks to them I can try to support your devices http://freaktab.com/core/images/smilies/wink.png

                  Comment


                    #10
                    Originally posted by leolas View Post
                    well in that case you need to build your own kernel for android and give it the correct parameters to boot, change all partitions (user; userdata; cache; etc...) to sdcard. I never did it, but I think that maybe it can be possible, you will have a lot of problems to do it but maybe is possible, too much work for do it.
                    So why you want to run android from sdcard and linux from nand? Sorry but it not make sense for me.
                    If we have a simple way to do something, (thanks to the great work of people like Alok, linuxium, etc...) why you want to complicate?

                    For me there is some options now:

                    You want only linux no android: You can ignore your sdcard and install linux in a external sdcard or install it in your nand and use then external sdcard like a extra storage.

                    You want linux and android: Install android in your nand and linux in your external sdcard, thanks to linuxium multiboot you can select easy the os or you can predefine with one boots.

                    You want only android:
                    ok like the minipc was designed, no need of explanations in this option.

                    leolas
                    The main reason I want to do this is because I am an end user and not a developer. At the moment I am not able to use a recovery kernel to run Linux on the SD card so I need to run Linux in NAND unless I build my own images for multiboot. I want to keep Android around until Linux matures a little further so want a way to boot it occasionally. I think I need to somehow patch a standard Android recovery to build the system on SD or USB. Then I could replace that recovery with a multiboot recovery that runs Linux in NAND unless it finds the Android signature on the SD or USB. I'm not keen on compiling my own system so am throwing out ideas to see if I can find the easiest solution for me among the responses.

                    Comment


                      #11
                      Re: I want Linux reboot to be a reboot to recovery

                      Ahh, ok.
                      The easier way is to maintain android in nand, and install Linux in the sdcard, you use a kr42, right?
                      Omegamoon has a working config (I think) for mk888 (is clone of yours), and waser have config for your device, you only need that someone compile a working Linux kernel for your device, I will start soon to experiment with Linux in my QX1, if wasser have no time, I will try to make a working recovery image for the kr42 using waser or omegamoon configs.

                      leolas.
                      REMEMBER, YOUR FEEDBACK IS VERY IMPORTANT TO US.
                      My devices:
                      Minix Neo X7; Minix Neo X8-H , Minix Neo Z64W & Z64 (Sponsored by Minix)
                      MK902 & MK902II(Sponsored by RKM)
                      Beelink M8B & Beelink R89 (Sponsored by Beelink)
                      Tronsmart VEGA S89H (Sponsored by
                      Gearbest.com)
                      MELE-PCG03 (Sponsored by Gearbest.com) Discount Coupon:MPCG03
                      Ainol Intel Z3735 MiniPC(Sponsored by Gearbest.com)
                      Thanks to them I can try to support your devices http://freaktab.com/core/images/smilies/wink.png

                      Comment


                        #12
                        Originally posted by leolas View Post
                        Ahh, ok.
                        The easier way is to maintain android in nand, and install Linux in the sdcard, you use a kr42, right?
                        Omegamoon has a working config (I think) for mk888 (is clone of yours), and waser have config for your device, you only need that someone compile a working Linux kernel for your device, I will start soon to experiment with Linux in my QX1, if wasser have no time, I will try to make a working recovery image for the kr42 using waser or omegamoon configs.

                        leolas.
                        I would greatly appreciate the help. I wasn't looking forward to poking around an image file with a hex editor to change paths. I guess I can go back to figuring out why sound isn't working when it should and wondering if anything can be done about improving the access to mass storage. Loading programs takes forever.

                        Comment

                        Working...
                        X