Kernel with loop device support - G Tablet General

Wanting to run Ubuntu with JB , f anyone can tell me if there is a kernel out there currently that supports loop devices.
thanks in advance
Dan

gddan said:
Wanting to run Ubuntu with JB , f anyone can tell me if there is a kernel out there currently that supports loop devices.
Click to expand...
Click to collapse
If you can successfully move apps to an SD card on your ROM, then the ROM kernel will have loop device support: the move-apps-to-SD card feature requires it.
However, some kernels, notably the older TeamDRH ICS kernels, have been mis-compiled, so you should check directly for loop device support in the kernel:
Code:
$ [B]fgrep loop /proc/devices[/B]
7 loop
$
However, if you plan to run Ubuntu in parallel with Android, then it's better to use a Linux kernel than an Android one.

Thank you,
I have managed to get it running but am having a serious lag with the JB ROM, still able to run commands through terminal but when I try to vnc in I barely am able to load the desktop, am assuming I should drop down to a lighter ROM like a froyo. Maybe a little over clock will help.

Related

[Q&A] Ubuntu on the Transformer (eMMC install)

This thread is for help and support related to ubuntu on the eeepad transformer, all questions not related to development should be asked here, please be friendly and do not flame each other or I will request the thread be closed.
Download links are in the third post.
There is a wiki entry here that has a bit more detailed explanation. Please note though that as it is a wiki information
quoted in there may or may not be entirely accurite.
you will need to download an nvflashable rom, like prime.
Please read the README before attempting this. The readme is below as well as in the kit, YOU WILL LOSE DATA.
Download links are in the second post.
OLiFE for the ASUS transformer
------------------------------------------------------------------
(c) 2011 Steven Barker <[email protected]>
This package should have only been linked to from xda-developers
or rootzwiki if you got the links to this package from anywhere
but those sites please send an email to the above email
address with the subject: "unauthorised posts"
DISCLAIMER
------------------------------------------------------------------
Steven Barker (lilstevie) nor anybody will take any responsibility
for any damage, data loss, fire, death of a loved one, or loss of
data resulting from using this mod for your device. Using this mod
may void your warranty.
NVFLASH
------------------------------------------------------------------
nvflash is the intellectual property of nvidia, and remains the
property of nvidia. Any questions or queries regarding the usage
and licence of nvflash should be directed to nvidia.
abootimg
------------------------------------------------------------------
abootimg is by Gilles Grandou <[email protected]> and is
unmodified. The source is available from online at
http://gitorious.org/ac100/abootimg
usage
------------------------------------------------------------------
Usage has changed since the release of the last kit, please read
these instructions carefully, as the install method is a little
more complex, (but easier once you use it).
If you downloaded OLiFE.tar.gz you will need to inject the android
rom and ubuntu image. You can use any nvflashable rom with this.
I recommend that you use prime as that is the configuration that
I have tested myself, and the ROM that I support for use with this
device. You can download the ubuntu image from
http://lilstevie.geek.nz/ports/ubuntu.img.gz.
If you downloaded OLiFE-Prime-Edition.tar.gz you will not need to
download the ubuntu image or an nvflash rom as they are seeded into
the image.
Install instructions:
1) Download the specific flavour of OLiFE that you want to use, and
extract it with "tar xvf <filename>".
2) If needed inject android rom and ubuntu image.
3) From the directory that OLiFE was extracted in run the main script
with the command ./OLiFE.sh.
4) Read the text that comes up and answer the question it asks.
5) Follow the menu to the option you want (below is a breakdown of
what each menu item is) and follow the instructions prompted. (also below
is instructions on how to get into the modes requested).
Menu items:
1) Backup Menu:
1) Full Backup (stock)
- Full backup (stock) takes a full backup of a stock
android system. This gives you an option to also back
up your user data(this will take a while).
2) Full Backup (ubuntu)
- Full backup (ubuntu) takes a full backup of a system
that dualboots android and ubuntu, this backs up your
system, and the ubuntu image. This gives you an option
to also back up your user data(this will take a while).
3) User data only
- This backs up the user data partition on your device.
(This option takes a while)
4) Android ROM
- This option backs up the android system only. This
option generates all the files (minus bootloader, and BCT)
required to flash a rom via nvflash.
5) Ubuntu Install
- This option backs up the ubuntu install on your device.
2) Flash Device:
1) Dualboot:
- This option will install ubuntu to your device in a
dualbooting configuration with android. During the
installation process it asks you which OS you would like
to boot by default.
2) uboot (linux only):
- This option will install ubuntu with u-boot and the
ChromeOS kernel that supports acceleration. This option
is currently unavailable, but should be available soon.
3) asus boot (linux only):
- This option will install ubuntu with the asus bootloader
with this configuration you will use all the eMMC for ubuntu
and there will be no android system installed on your device.
4) stock:
- This option will partition the device in a stock way and
install the android system that is in ./images. Use this
option if you no longer want ubuntu on your device.
3) Update Device:
1) Android Kernel:
- This option will update the android kernel on your device
with the boot.img from ./images/. This allows you to install
your own kernel on the device for android rather than the one
that comes with your chosen rom.
2) Ubuntu/Linux Kernel:
- This will update the ubuntu kernel on your device to the version
included in this flashkit. This option is for updating just the
kernel with nvflash rather than using the blob method. This method
is also good for if you flash a bad ubuntu kernel to the device.
3) Android ROM:
- This option will update the android rom on the device with the
one from ./images/. This is good for if the ROM you use is updated
or you would like to change ROMs and there is an nvflash image for it.
This option does not destroy your data.
4) Ubuntu Rootfs:
- This will update your ubuntu image on the device. This is destructive
to data stored in the ubuntu image.
5) Advanced (Unsupported):
- Any option in this menu is not supported and should be considered
unstable. There may be bugs in these options and they are not maintained
at this point in time.
1) Flash ChromeOS Kernel (Primary Boot):
- This option will flash the ChromeOS kernel to the primary boot
partition. This option may not currently work in it's current
configuration.
2) Flash ChromeOS Kernel (Secondary Boot):
- This option will flash the ChromeOS kernel to the secondary boot
partition. This option may not currently work in it's current
configuration.
3) Update Uboot Partition:
- This option will update the u-boot boot partition that u-boot
reads the kernel and boot script from. This option does work if
you have installed u-boot by compiling it from source and installed
it yourself.
4) Flash ClockworkRecoveryMod:
- This option allows you to temperarily flash CWR to the device so
you can update the installed rom. It backs up the current kernel in
the recovery kernel position and then flashes CWR. When you have finished
using CWR you then push any key and put the device back in APX mode and
it will restore the kernel that was in that position. (This only works if
android is your primary boot option at this time).
4) Inject Firmware:
1) Bluetooth firmware (default install):
- This option will inject the Bluetooth firmware from the
android ROM located at ./images/ in to the ubuntu of your
currently running system.
2) Bluetooth firmware (CrOS Kernel):
- This option will inject the Bluetooth firmware from the
android ROM located at ./images/ in to the ubuntu of your
currently running system and flashes the proper u-boot kernel
if you no longer need adb support.
5) Onscreen Keyboard:
- This runs OnBoard so that you can run through oem-config properly
you only need to use this option if you do not have a keyboard dock
and on the first boot.
1) Standard Kernel:
- This will invoke oem-config on the standard kernel installed
on the device.
2) ChromeOS Kernel:
- This will invoke oem-config on the u-boot kernel that is
installed on the device and flashes the proper u-boot kernel
if you no longer need adb support.
Device Modes:
APX Mode:
-This mode is used by nvflash to write files to the eMMC device.
To boot in this mode you press Power and Vol-Up.
Recovery Mode:
- This mode is where CWR or Asus recovery normally lives, but is
replaced by the secondary OS in the dualboot configuration.
To boot in this mode you press Power and Vol-Down, then Vol-Up when prompted.
Normal Boot:
-This mode is where android normally lives.
To boot in this mode you press the Power button until the screen turns on.
Changelog
------------------------------------------------------------------
1.2a - Release name: Odyssey
* New name for kit: OLiFE
* New menu system
* Updated README
* Better handling of platform detection
* Bluetooth support in ubuntu.img
* Preliminary support for ChromeOS kernel
* Preliminary support for uboot
* Fixed touchpad
* Fixed network manager
* Updated to ubuntu oneiric
* More options for flashing and updating
* OTB Wireless support (No more injecting)
* Smaller ubuntu.img for faster upload to device
* Auto resizing of rootfs on first boot
* Larger partition size (6GB) for ubuntu
* Refactored to more easily between devices
* Maybe something else I have missed
1.1 - Release name: Daedalus
* Firmware injector for BT and wifi firmwares
1.0 and silent updates - Release name: Prometheus
* Support for x86_64 linux distributions
* Updated README for release on xda-developers
* Fixes to install scripts
* Initial Release
Downloads:
RootFS md5sum(1a9fa8a698e4a96245a3c08511841eb4)
OLiFE md5sum(c30263fd8271a23bb211fd9fdd69fa45)
OLiFE Prime Edition md5sum(767779ccfa200e5e00b2f1e33a3d73a9)
Sources:
http://gitweb.lilstevie.geek.nz
To clone the repos "git clone git://lilstevie.geek.nz/$(name of repo).git"
lilstevie said:
This is running natively and from the eMMC so no µSD card required,
The video is a class2 µSD card and speeds are not an example of speeds from this kit.
Click to expand...
Click to collapse
Thanks for your hard work, but I'm a bit confused by those 2 statements, contradicting each other :/
Also, if I understood properly, there is no CWM after selecting dual boot
Finally, is this a final release, or for testing purpose only ?
If final, a step by step guide would be very welcome
Edit : Just saw there is the tag [DEV] so forget about my last question (guide)
Wow, amazing work here. Haven't been able to do much to my Transformer as of late (due to uni starting up again, and been seeing how the TF goes as a substitute for my usual netbook), but absolutely can't wait to try this out when I got some time.
And yeah, I'm a tad confused here as well. I'm assuming that you mean the video was of Ubuntu running of your microSD drive using Jhinta's scripts but now this allows us to run it off the internal drive... am I right?
And how is the speed difference so far, running off internal vs class 2 microSD?
EDIT: Also, I'm assuming the same things that didn't work on Jhinta's aren't working on this (network-manager gui, touchpad etc)? Or have you changed things up a bit? And the tegra ppa you talk about; that contain the proprietary 3D drivers you were talking about having a lack of in the video?
Nice to see the post in XDA Good work !
bud77 said:
Thanks for your hard work, but I'm a bit confused by those 2 statements, contradicting each other :/
Also, if I understood properly, there is no CWM after selecting dual boot
Click to expand...
Click to collapse
The video was taken before I was stable enough to even think about using internal memory, where as this kit is not using the µSD
and yeah you lose recovery after selecting dual boot, not much we can do about that for the time being.
poltak11 said:
Wow, amazing work here. Haven't been able to do much to my Transformer as of late (due to uni starting up again, and been seeing how the TF goes as a substitute for my usual netbook), but absolutely can't wait to try this out when I got some time.
And yeah, I'm a tad confused here as well. I'm assuming that you mean the video was of Ubuntu running of your microSD drive using Jhinta's scripts but now this allows us to run it off the internal drive... am I right?
And how is the speed difference so far, running off internal vs class 2 microSD?
EDIT: Also, I'm assuming the same things that didn't work on Jhinta's aren't working on this (network-manager gui, touchpad etc)? Or have you changed things up a bit? And the tegra ppa you talk about; that contain the proprietary 3D drivers you were talking about having a lack of in the video?
Click to expand...
Click to collapse
I started back at uni this week myself, and have been using my transformer as a netbook replacement with ubuntu. The video is using my stuff but before I had it running on the internal memory.
speed diference is massive between the class2 and internal. It was so great of a difference that I forget that it is arm now that it is on internal
the PPA will have things such as kernel updates, bluetooth enabler and all that. as for what is working in the release, things are pretty similar to Jhintas release, touchpad does not work correctly network manager gui doesn't work, I have something to enable bluetooth, that works nicely, but it isn't in the fs or up on the ppa yet. 3D drivers are a work in progress, still no EGL and the likes with the L4T releases, so it is really just acceleration for normal use, I have been working on them but as of yet no dice.
So using the PPA, in theory we won't have to flash the device again (at least for the ubuntu part), it will be able to auto-update itself ?
ErGo_404 said:
So using the PPA, in theory we won't have to flash the device again (at least for the ubuntu part), it will be able to auto-update itself ?
Click to expand...
Click to collapse
yes, that is the plan anyway
lilstevie said:
the PPA will have things such as kernel updates, bluetooth enabler and all that. as for what is working in the release, things are pretty similar to Jhintas release, touchpad does not work correctly network manager gui doesn't work, I have something to enable bluetooth, that works nicely, but it isn't in the fs or up on the ppa yet. 3D drivers are a work in progress, still no EGL and the likes with the L4T releases, so it is really just acceleration for normal use, I have been working on them but as of yet no dice.
Click to expand...
Click to collapse
Ah lovely idea with the PPA. When new 3.2 based Prime gets released, I'll try to get a few hours to myself to get this all working together.
Just a few quick questions first:
How do your scripts change the eMMC layout? Does eMMC work the same as a standard HDD/SSD partitioned with a GPT? As in, have you made separate partitions for Android and Ubuntu, or is it somehow shared?
And also related, how much room will it take up on the eMMC (as I've only got a 16GB TF)?
And finally, since you've been using yours at uni running Ubuntu, have you got any idea of the battery life running Ubuntu? I'm assuming it'd be pretty similar to stock, but yeah the battery indicator wasn't working last time I was playing around with Ubuntu from the microSD. Also, does the second keyboard battery work?
poltak11 said:
Ah lovely idea with the PPA. When new 3.2 based Prime gets released, I'll try to get a few hours to myself to get this all working together.
Just a few quick questions first:
How do your scripts change the eMMC layout? Does eMMC work the same as a standard HDD/SSD partitioned with a GPT? As in, have you made separate partitions for Android and Ubuntu, or is it somehow shared?
And also related, how much room will it take up on the eMMC (as I've only got a 16GB TF)?
And finally, since you've been using yours at uni running Ubuntu, have you got any idea of the battery life running Ubuntu? I'm assuming it'd be pretty similar to stock, but yeah the battery indicator wasn't working last time I was playing around with Ubuntu from the microSD. Also, does the second keyboard battery work?
Click to expand...
Click to collapse
The second battery does work, unless you get one of those dodged ones that just randomly stops charging which happened to me, with the dock connected and the battery in it refusing to charge my battery lasted 6 hours.
the layout is different to standard, UDA(User DAta partition) is 4.2GB smaller than what it was, so you have 9.99gb for android and 4.2 for ubuntu, the kernel and recovery kernels are moved up to the end of the flash as well so that they are accessible through /dev
Just finished installing it. Yea, from internal memory it's working much faster. ~20 second boot time!(I didn't have timer with me, so I counted in the head) That's like my laptop with SSD + 10 second bios booting. With a dock it feels like a true netbook. I think I'll even dare to test c/c++ IDE on this thing. Good job!
Used online timer. It's 21 seconds.
Hmm how do I start wifi? eth0 is not even showing in the list of devices.
aligatro2010 said:
Just finished installing it. Yea, from internal memory it's working much faster. ~20 second boot time!(I didn't have timer with me, so I counted in the head) That's like my laptop with SSD + 10 second bios booting. With a dock it feels like a true netbook. I think I'll even dare to test c/c++ IDE on this thing.
Used online timer. It's 21 seconds.
Hmm how do I start wifi? eth0 is not even showing in the list of devices.
Click to expand...
Click to collapse
Sorry forgot to mention in the first post, firmwares are not included in this release due to potential licensing issues, you can push the wifi firmware via adb to /lib/firmware and also the nvram, they are located in /system/vendor/fw_bcm4329.bin and /system/etc/nvram.txt on your android system, the module will autoload on boot once you have the firmware in place, and the interface will be named wlan0
lilstevie said:
Sorry forgot to mention in the first post, firmwares are not included in this release due to potential licensing issues, you can push the wifi firmware via adb to /lib/firmware and also the nvram, they are located in /system/vendor/fw_bcm4329.bin and /system/etc/nvram.txt on your android system, the module will autoload on boot once you have the firmware in place, and the interface will be named wlan0
Click to expand...
Click to collapse
nvram.txt to /etc right? I copied them straight from android partition, but it still doesn't load. Could it be because of the bcm4329_sta.bin or nvram should be placed in /lib/firmware ?
It works now.
So basically we will be able to dual boot Windows 7 and Android?
liorry said:
So basically we will be able to dual boot Windows 7 and Android?
Click to expand...
Click to collapse
No, Windows 7 doesn't have arm version. Windows 8 maybe in future, long future ....
aligatro2010 said:
nvram.txt to /etc right? I copied them straight from android partition, but it still doesn't load. Could it be because of the bcm4329_sta.bin or nvram should be placed in /lib/firmware ?
It works now.
Click to expand...
Click to collapse
the wifi firmware should be called fw_bcm4329.bin and nvram.txt should be in /lib/firmware, I probably should have been a little clearer, but I posted that just before going to bed, and was a little tired
lilstevie said:
the wifi firmware should be called fw_bcm4329.bin and nvram.txt should be in /lib/firmware, I probably should have been a little clearer, but I posted that just before going to bed, and was a little tired
Click to expand...
Click to collapse
"bcm4329_sta.bin" was already there before I even copied 2 modules and it was also loaded as module when I did modprobe. (not 100% sure about the second)That's why I thought it was conflicting with android's modules.
Wow, great work! Can't wait to try it.
Sent from my Transformer TF101 using XDA Premium App
I've probably missed something obvious.. But I get this.
file not found: linux.img
failed executing command 2147483647 NvError 0x4
command failure: create failed
rm: cannot remove `linux.img': No such file or directory
Click to expand...
Click to collapse
After like 5 minutes of NvFlash installing stuff.

[PATCHES] Kexec syscall support, boots kernels from SD or USB (11/6/11, GB support)

11/6/11 Update: Added statically-linked kexec to kexec_patches.tar.gz and example update.zips. Now works in stock recovery and CM7 CWM (with a kexec-patched kernel).
10/19/11 Update: Added patches for the recently released GB sources to kexec_patches.tar.gz.
Attached is a set of patches (kexec_patches.tar.gz) against EC05, and the recently released GB sources, to implement kexec syscall support in the Epic's kernel. kexec enables the booting of kernels "directly" from the SD card or over USB without having to flash them to the device first. This allows us to easily use, test, and switch between many kernels, not just the one (two with recovery) there's room for on flash.
When used in conjuction with modified init.rc scripts, this allows entire ROMs (with their own kernels) to run from SD card. In short, this allows us to run custom-kernel ROMs (e.g,. CyanogenMod) alongside each other or a stock kernel without having to flash back and forth.
Also attached is a modified version of the kexec userspace tool (also in kexec_patches.tar.gz, along with source and patches) that facilitates the proces of loading and kexecing a kernel image. Finally, attached is a demo EC05 kernel with kexec enabled (demo_kernel.tar.gz; mostly stock: RFS support only, testkeys recovery w/adbd, but does inlcude the keyboard patches), example update.zips that kexec an SD-card kernel from recovery--either as a normal boot (boot_zImage.zip) or recovery boot (boot_zImage_recovery.zip), and a script (patch_decomp_cachebufram.sh) to binary patch unmodified kernels to kexec boot faster.
Note, this thread is primarilly intended for kernel developers. Kexec probably won't be of great utility to end users until commonly-used kernels are patched. Also, although stock kernels can be kexec'd, they need some init.rc modifications boot an entire ROM from SD card. Hopefully the fine folks here will come up with a user-friendly implementation of this work that's easy for everyone to use.
Instructions:
Flash a kexec-enabled kernel (e.g., the attached demo kernel) to either /dev/block/bml7 or /dev/block/bml8. For testing purposes, this kernel needs either "ro.secure=0" or "ro.debuggable=1" set in default.prop, and also needs recovery.rc/fota.rc modified to spawn the adbd service, so that an adb root shell is available while in recovery. Also copy the attached kexec tool to a convenient location on the device (e.g., /data/local/tmp/kexec).
Reboot into recovery. If the kexec kernel is installed to bml7, run "adb reboot recovery" while the phone is running. If installed to bml8, power down and boot into recovery by holding the volume-down, camera, and power buttons.
Make sure adb is running as root. If it's not, try running "adb root".
Find the kernel (zImage) you wish to boot. These can be extracted from a kernel update.zip or Odin .tar file, or use the demo kernel again.
Push the zImage into RAM (tmpfs) with:
Code:
adb push zImage /tmp
Now, open an adb root shell with "adb shell" and run the commands:
Code:
mount -ro remount /dev/block/stl6 /mnt/.lfs
mount -ro remount /dev/block/stl9 /system
mount -ro remount /dev/block/stl10 /data
mount -ro remount /dev/block/stl11 /cache
/data/local/tmp/kexec --load-hardboot --mem-min=0x50000000 --append="console=ttySAC2,115200 loglevel=4" /tmp/zImage
sync
/data/local/tmp/kexec -e
after which the phone will reboot, show the SAMSUNG logo, and eventually boot the kexec'd kernel. Do note that when booting unmodified kernels (see below), the SAMSUNG logo will persist for ~30 seconds longer than usual.
Also note that kexec performs an "abrupt" reboot, i.e., it doesn't shutdown the system normally. Hence it's important to kexec from recovery where few services are running. It's also prudent to remount file systems read-only and sync them to avoid any potential (although unlikely) of corruption.
In the future, kexec could be better integrated into the Android framework to allow for a clean shutdown. Otherwise, probably the best way to deploy kexec is through an update.zip file that boots a kernel from the SD card. See the attached example update.zips.
Technical details:
kexec is feature of Linux that allows it to directly execute (boot) a new kernel in place of itself, allowing Linux to effectively serve as its own bootloader.
The kexec procedure is two step. The first "kexec" command loads a zImage from disk, constructs parameters (e.g., the kernel command line), and stages it in memory, after which Linux continues to run as normal. The second "kexec" command tells Linux to execute (boot) the staged kernel.
In the standard implementation, Linux "soft boots" kexec'd kernels. That is, on "kexec -e" the running instance of Linux shuts-down all devices, drivers, and goes through the process of unloading itself as it does during a normal reboot. However, instead of invoking a hardware reboot, Linux, at the final stage of unloading itself, jumps to start executing the new kernel.
This soft boot process requires that Linux hardware drivers are fully capable of unloading, reloading, and reinitializing the associated hardware without hardware-reboot or bootloader assistance. Since, for many built-in drivers, this capability is only used by kexec, hardware is often left in an unexpected or unknown state on unload, and thus the kexec'd kernel hangs on boot. Unfortunately this is the case with the Epic kernel, and soft booting doesn't work.
To work around this, the attached patches implement a "hard boot" method for kexecing kernels. Here, we use kexec to stage a kernel in memory as usual. On "kexec -e", Linux shuts-down as before, and at the very end of the unloading process it does two things: (i) scribble some information on how to boot the kexec'd kernel to a "special place" in memory, and (ii) performs a hardware reboot, invoking the Epic bootloader as a normal reboot does.
On reboot, the bootloader loads the (previously-running) bml7 or bml8 kernel and starts executing it. Here, the hardboot patch modifies the Linux the zImage decompressor code to check the "special place" in memory to see if we're actually kexecing a different kernel. If so, it switches over to the other kernel, already staged elsewhere in memory.
Known Issues:
Kernel Command Line:
Kexec (via hardboot) can boot stock or non-kexec-modified custom kernels. However, unless the copy_atags patch is applied, they can only use the kernel command line provided by the bootloader, as opposed to the custom command line provided by kexec. Although this isn't a problem when kexecing from a bml7 boot kernel, kexecing from a bml8 kernel runs recovery (fota.rc) instead of a normal boot (init.rc).
With the copy_atags patch, the command line for the kexec'd kernel must be provided by with kexec's --append option. These are the command lines provided by the bootloader in normal boot and recovery scenarios, any of which may be used:
Code:
Normal boot (init.rc):
console=ttySAC2,115200 loglevel=4
"adb reboot recovery" (recovery.rc):
bootmode=2 console=ttySAC2,115200 loglevel=4
Three-finger recovery boot (fota.rc):
bootmode=3 console=ttySAC2,115200 loglevel=4
Slow Booting:
Kexec booting of a stock or non-kexec-modified custom kernel is known take significantly longer than a regular boot, sitting at the SAMSUNG logo for 35 seconds instead of 8. The decomp_cachebufram patch resolves this issue for modified kernels. In addition, the attached patch_decomp_cachebufram.sh script will binary patch the decompressor code for any (to my knowledge) Epic kernel.
Many more details on the patches themselves are in the accompanying READMEs.
Mirror links:
Kernel & kexec-tools patches: kexec_patches.tar.gz
Kexec EC05 demonstration kernel: demo_kernel.tar.gz
Recovery script to boot /sdcard/zImage (normal boot): boot_zImage.zip
Recovery script to boot /sdcard/zImage (recovery boot): boot_zImage_recovery.zip
Script to binary patch decompressor code: patch_decomp_cachebufram.sh
Is this different in function than rodderik's dual boot support?
I know his didn't include usb booting support, but sdcard booting appears to be the same...although this seems a little cleaner, possibly
Sent from my SPH-D700 using xda premium
squshy 7 said:
Is this different in function than rodderik's dual boot support?
I know his didn't include usb booting support, but sdcard booting appears to be the same...although this seems a little cleaner, possibly
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
His uses a modified init, which then choses to load which init.rc, the one names init.rc.sdcard or normal init.rc. This (kexec method) reminds me A LOT like how they ran linux/android on winmo devices...it shuts down android and then runs the kernel they want (if I read correctly).
squshy 7 said:
Is this different in function than rodderik's dual boot support?
I know his didn't include usb booting support, but sdcard booting appears to be the same...although this seems a little cleaner, possibly
Sent from my SPH-D700 using xda premium
Click to expand...
Click to collapse
Yes. The genocide implementation allows a ROM to boot from the sd card as long as the kernel on the main ROM supports the sd ROM. this means you cannot dual boot a gingerbread and a froyo ROM because the need different kernels .
With this patch that limitation is removed as the sd based ROM can use its own separate kernel. This you may run stock ec05 and keep cyanogen or a gingerbread on the sd card to test and play with.
Great work mkasick
Sent from my SPH-D700 using Tapatalk
I was never interested in the dual boot feature since that was ROM's only and itwas limited by kernel support.
But now this really interest me, can't wait till we see some developers take advantage of this.
Sent from my SPH-D700 using xda premium
All I have to say is hope you stick with the epic your amazing
Sent from my SPH-D700 using Tapatalk
Yes, this is complementary to Rodderik's dual boot. Kexec allows one to load a different kernel, but it still defaults to booting the ROM stored in flash. Which is great for kernel testing, but not of much use otherwise.
It's easy enough to modify a kernel to load a ROM only from SD, but then we'll start seeing a divide between "bml kernels" and "SD kernels", when really it'd be nice to have init scripts that support both. That's where Rodderik's work comes in.
Probably the best is to have a kernel command line parameter that specifies where the ROM is located, so it can be passed in. Something like "console=ttySAC2,115200 loglevel=4 systemfs=mmcblk0p2 datafs=mmcblk0p3 cachefs=mmcblk0p4". These would default to stl9, stl10, stl11 respectively if unspecified. The kernel command line is available to init through "/proc/cmdline", and it's easy enough to parse in a shell script.
But yes, keeping a working ROM on flash while testing/debugging CyanogenMod was my primary motivation, since I need a working phone "during the day" and can't touch CyanogenMod otherwise.
formula84 said:
All I have to say is hope you stick with the epic your amazing
Click to expand...
Click to collapse
Thanks!
I'm much of a year out on a full upgrade, and I'm not considering a new device sooner as long as my Epic still works.
Edit: An obvoius limitation is modem compatibility. I've avoided the GB leaks thus far, so I'm not sure what's the status with that. But if GB supports the EC05 modem, then you can dual boot EC05 and GB-whatever. Same if EC05 supports newer modems.
Speaking of which, anyone know what GB modem compatibilty is like?
mkasick said:
Yes, this is complementary to Rodderik's dual boot. Kexec allows one to load a different kernel, but it still defaults to booting the ROM stored in flash. Which is great for kernel testing, but not of much use otherwise.
It's easy enough to modify a kernel to load a ROM only from SD, but then we'll start seeing a divide between "bml kernels" and "SD kernels", when really it'd be nice to have init scripts that support both. That's where Rodderik's work comes in.
Probably the best is to have a kernel command line parameter that specifies where the ROM is located, so it can be passed in. Something like "console=ttySAC2,115200 loglevel=4 systemfs=mmcblk0p2 datafs=mmcblk0p3 cachefs=mmcblk0p4". These would default to stl9, stl10, stl11 respectively if unspecified. The kernel command line is available to init through "/proc/cmdline", and it's easy enough to parse in a shell script.
But yes, keeping a working ROM on flash while testing/debugging CyanogenMod was my primary motivation, since I need a working phone "during the day" and can't touch CyanogenMod otherwise.
Thanks!
I'm much of a year out on a full upgrade, and I'm not considering a new device sooner as long as my Epic still works.
Edit: An obvoius limitation is modem compatibility. I've avoided the GB leaks thus far, so I'm not sure what's the status with that. But if GB supports the EC05 modem, then you can dual boot EC05 and GB-whatever. Same if EC05 supports newer modems.
Speaking of which, anyone know what GB modem compatibilty is like?
Click to expand...
Click to collapse
As far as I know, and from experience, modems are a free for all except for bonsai. Ec05 modem works on gb, leaked modems work on ec05.
this is definitely very cool, thanks mkasick!
Sent from my SPH-D700 using XDA Premium App
mkasick you never cease to amaze me...i'll definately play with this, this week if i have the time!
Rodderik said:
mkasick you never cease to amaze me...i'll definately play with this, this week if i have the time!
Click to expand...
Click to collapse
Great!
If you run into something not particularly straight forward, or think there's something I can clarify, please ask. I've been playing around with this long enough that I fear I might've overlooked documenting a detail or two that would be helpful for others.
So to patch any kernel u just point the script to the zImage?
sent from my epic 4g. with the key skips.
ugothakd said:
So to patch any kernel u just point the script to the zImage?
Click to expand...
Click to collapse
The script only implements one patch, it allows any kernel to boot ~30 seconds faster when kexec'd.
But yes, "./patch_decomp_cachebufram.sh zImage" modifies that zImage to boot faster. It requires the xxd hexdump tool that's packaged with vim.
Kexec support itself, along with the slew of other source patches, has to be applied to a kernel source tree, from which a new kernel must be built to take advantage of them.
mkasick said:
The script only implements one patch, it allows any kernel to boot ~30 seconds faster when kexec'd.
But yes, "./patch_decomp_cachebufram.sh zImage" modifies that zImage to boot faster. It requires the xxd hexdump tool that's packaged with vim.
Kexec support itself, along with the slew of other source patches, has to be applied to a kernel source tree, from which a new kernel must be built to take advantage of them.
Click to expand...
Click to collapse
I see...so its a no-go for gb. Or at least quick gingerbread.
sent from my epic 4g. with the key skips.
ugothakd said:
I see...so its a no-go for gb. Or at least quick gingerbread.
Click to expand...
Click to collapse
You should be able to kexec a GB kernel, but you'd need an EC05-ish /system on flash to boot recovery. Unless GB recovery is compatible with Froyo kernels.
If you're going to boot a GB kernel, you'd probably want to repackage the initramfs with an init.rc that loads the rest of the GB ROM off SD. It's actually not a bad way to keep EC05 around for a stable, working phone, and to test GB leaks as they happen. Which, hopefully, shouldn't be much longer.
wow mkasick, you never cease to amaze me bro...
I wish I wasn't working so many damned hours now, with your patches, I really want the dual boot now. Like you, the need for a working phone at all times is what keeps me from flashing more ROMs, including EpicCM and the gb leaks...
I hope Rodderik figures this out pretty quickly, as most of my dev time is spent on the IRC channels, and he's usually around to help and answer questions.
Once I can get my Clean Kernel working with this, I'll be stoked... I have had a tough time dealing with patches thus far, I usually git cherry-pick and/or manually edit, so I need to figure out how to use the patches correctly.
Anyways, gotta go to work now (I'm working 50+ hour weeks now, hence the time constraints), but hopefully I can get the time to get it into my kernel.
Thanks, mkasick!
Sent from my Samsung Epic4G
DRockstar said:
I have had a tough time dealing with patches thus far, I usually git cherry-pick and/or manually edit, so I need to figure out how to use the patches correctly.
Click to expand...
Click to collapse
What environment (OS, etc.) are you using? Is the "patch" utility working for you?
The patches are split up based on functionality. In each patch directory there's a "series" file that lists the order they should be applied. There's a program, quilt that can help manage them but it's not necessary. If you're running a bourne shell (e.g., bash) in the "Kernel" directory of the kernel sources, you should be able to apply the patches with:
Code:
while read i; do patch -p 1 < "/path/to/kexec_patches/kernel-EC05/$i"; done < "/path/to/kexec_patches/kernel-EC05/series"
Whether they'll apply cleanly or not is a different story, but that's the general idea.
And yeah, time ....
Thank you mkasick, that's a great explanation, I think I can handle that, much appreciated!
For the record, I compile by ssh into dev boxes donated for dev use. They all run linux in different distros. I find this most convenient since I can do most everything from the command line using your brilliant connectbot for epic
Sent from my Samsung Epic4G
With those recovery scripts, doesn't Clockwork Mod have to have kexec set up?
ugothakd said:
With those recovery scripts, doesn't Clockwork Mod have to have kexec set up?
Click to expand...
Click to collapse
You mean for boot_zImage_recovery.zip to work?
The CWM kernel doesn't need full kexec support in order to be booted via kexec. But it does need the copy_atags patch in order to respect the "bootmode=3" kernel argument.
Actually, you can take any existing Epic kernel and somewhat-easily fix it to be bootable via kexec. Steps are:
1. Extract EC05 kernel sources. Or use the GB sources, it doesn't matter, it doesn't even have to match the version of the kernel you're fixing.
2. Apply "decomp_cachebufram" and "decomp_copy_atags" patches.
3. Build a kernel. Config options don't matter much since this kernel is going to be thrown away.
4. Find the zImage for the kernel you want to fix. Run:
Code:
skip=`grep -Fabom 1 $'\x1f\x8b\x08' zImage | head -n 1 | cut -d : -f 1`
dd if=zImage bs=1 skip="$skip" | gunzip > Image
cp Image arch/arm/boot/Image
which extracts the decompressed kernel payload from the zImage, and replaces the "Image" that was previously built with the one you've extracted.
5. Run "make" in the kernel source directory again. You might have to append a "CROSS_COMPILE=" path to match the one used in a build script. The output should be:
Code:
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CALL scripts/checksyscalls.sh
CHK include/linux/compile.h
Kernel: arch/arm/boot/Image is ready
GZIP arch/arm/boot/compressed/piggy.gz
AS arch/arm/boot/compressed/piggy.o
LD arch/arm/boot/compressed/vmlinux
OBJCOPY arch/arm/boot/zImage
Kernel: arch/arm/boot/zImage is ready
Building modules, stage 2.
MODPOST 13 modules
which shows that the build process took the existing, extracted Image, compressed it, and attached a new kexec-compatible decompressor to it.
The resulting "arch/arm/boot/zImage" can be kexec'd, and command line arguments should be respected, e.g., if you want to boot into CWM recovery.

[DEV] unofficial ClockworkMod Recovery 5 for Ingenic JZ4770/JZ4760 tablets

this is a work-in-progress development project for porting ClockworkMod Recovery 5 to Ingenic JZ4770/JZ4760 tablets.
this is not perfect at all. and I'm very busy. progress will be very very slow. I may not be able to answer your question/request. if you have some idea for improvement, please do it freely.
there is no support from any makers/vendors. you must agree all risks by installing non-supported files, it may brick your tablet, and you may lose official support/warranty.
* YOU MUST READ CAREFULLY POST#1, #2, AND #3!
* DO NOT USE IF YOUR TABLET IS NOT LISTED BELOW. IT WILL BRICK YOUR TABLET!
* project page
http://androtab.info/mips/ingenic/clockworkmod/
* supported tablets
ainol NOVO7 Basic and Paladin
Velocity Micro Cruz T100 series (Android 2.2 updated model and Android 2.0 PT701i model)
Velocity Micro Cruz T301
ronzi A3
* changelog
refer git log
* resources
http://developer.mips.com/android/
https://github.com/naobsd/cm_bootable_recovery/compare/ics...ics-mips-naobsd
https://github.com/naobsd/mips_build/compare/mips-ics-mr1...mips-ics-clockworkmod
https://github.com/naobsd/mips_external-busybox/compare/ics...ics-mips
* How to install ClockworkMod Recovery 5 (for ainol NOVO7 Basic/Paladin, Cruz T100 series, Cruz T301)
1. download recovery-signed.zip for your tablet (DO NOT USE FILES FOR OTHER TABLETS!)
2. (if you are using stock recovery)rename it to update.zip, then put it on root of SD card
3. install update.zip from recovery
on stock recovery, update.zip will be installed automatically. on ClockworkMod Recovery, you need to select menu item manually.
* How to install ClockworkMod Recovery 5 (for ronzi A3)
1. download recovery.zip for your tablet (DO NOT USE FILES FOR OTHER TABLETS!), then extract recovery.cpio.img from it
2. make backup of stock recovery
Code:
adb remount
adb shell mv /system/recovery.cpio.img /system/recovery.cpio.img.bak
3. copy recovery.cpio.img into your tablet, then flash it
Code:
adb shell inand_flash_image recovery recovery.cpio.img
* How to boot recovery
push & hold VOL+ while power on
* How to boot recovery (alternative)
Code:
adb reboot recovery
*How to control ClockworkMod Recovery 5
VOL-/HOME: down, VOL+: up, POWER/MENU: select, BACK: back
* Superuser, su, and busybox
it can be installed from ClockworkMod Recovery 5
- Superuser, su, and busybox for JZ4770 ICS
- Superuser, su, and busybox for JZ4760 Froyo
* random notes
- stock recovery
if you installed update.zip from stock recovery, stock recovery image should be renamed as /system/recovery.cpio.img.bak. (unless you didn't remove /system/recovery.cpio.img)
it can be flashed by "inand_flash_image" command. (use "flash_image" command for T100 series except PT701i model)
- mbr, xboot, boot, and recovery areas
backup/restore doesn't work for mbr, xboot, boot, and recovery areas
- time for reboot/poweroff (NOVO7 Basic)
I don't know why but reboot/poweroff take long time (as same as stock rom). you should wait 1 minute. if nothing is happened in 10 minutes, use reset hole
for now I'm preparing to push my changes to github. I'm very busy so it needs some time.
if you made some.zip file to do something for MIPS Android (e.g. superuser.apk with su binary for MIPS), please tell me. I'll add link to post#1.
if you have some idea for next work, please tell me too. (but, as I wrote, I may not be able to answer your request. sorry)
Thanks for your starting thread and project.
I bought a Advanced model but they send us a Basic Novo7.
All we know the incompatibilites using a cpu MIPS, that doesnt allow to run a lot of Android software that for default its compiled for ARM processors.
Im getting a bundle pack of apps running under our device.
Kashamalaga said:
Thanks for your starting thread and project.
I bought a Advanced model but they send us a Basic Novo7.
All we know the incompatibilites using a cpu MIPS, that doesnt allow to run a lot of Android software that for default its compiled for ARM processors.
Im getting a bundle pack of apps running under our device.
Click to expand...
Click to collapse
thank you. I understand your condition.
but here is dev thread for clockworkmod for novo7 basic. if you want to talk about apps which support mips android and/or any general things about novo7b, I recommend you to make new thread for it.
fun_ said:
thank you. I understand your condition.
but here is dev thread for clockworkmod for novo7 basic. if you want to talk about apps which support mips android and/or any general things about novo7b, I recommend you to make new thread for it.
Click to expand...
Click to collapse
I will do as you said
This is great news. If you are wanting to test any work with users on Velocity Cruz t301's which also run an ingenic processor (JZ4760) .
UPDATE: Tried running CWM for the hell of it on the t301 . Stuck at boot screen was able to get back to original recovery however. I'm guessing it might be due to the entry point into the kernel . Since the t301 is ancient Froyo. Would love to take a look at the source
Also here SHOULD be a working SU for MIPs. It work's on the cruz tablets
vanduhl said:
This is great news. If you are wanting to test any work with users on Velocity Cruz t301's which also run an ingenic processor (JZ4760) .
UPDATE: Tried running CWM for the hell of it on the t301 . Stuck at boot screen was able to get back to original recovery however. I'm guessing it might be due to the entry point into the kernel . Since the t301 is ancient Froyo. Would love to take a look at the source
Click to expand...
Click to collapse
I couldn't read what you did exactly. if you flashed my image w/o modification, it must not work. as I wrote, DO NOT USE file for other tablet.
please explain what you did, and please explain detail about your tablet before any random work.
fun_ said:
I couldn't read what you did exactly. if you flashed my image w/o modification, it must not work. as I wrote, DO NOT USE file for other tablet.
please explain what you did, and please explain detail about your tablet before any random work.
Click to expand...
Click to collapse
Attempted using the above stated method(understanding you said DO NOT US file on other tablet) I was curious to see as what kind of error would or may of come up. I'm interested in modifying this for the Velocity Cruz T301 tablet(running a JZ4760 processor) as that community of tablet users has been left under the dust. Now with the novo coming out it will further pile under the dust. I have not yet made any modifications to it, although I would very much like to.
vanduhl said:
Attempted using the above stated method(understanding you said DO NOT US file on other tablet) I was curious to see as what kind of error would or may of come up.
Click to expand...
Click to collapse
kernel must not work because it's for NOVO7B. in general, kernel can't be shared among different products.
key assign, and partition layout may be different too. but currently I have no idea how to fix them because I don't have any detail about your tablet...
http://en.ingenic.cn/product.aspx
it seems JZ4760 is NOT MIPS32R2. then I need to recompile userland binaries.
anyway, technical detail is required to support other tablets.
http://bbs.imp3.net/thread-10520163-1-2.html
it seems source code for xboot, android 2.2 and (part of?)kernel source for NOVO7B is released. I don't try to compile them yet so I may be wrong.
I'll check them later.
Is it possible that someday this recovery will be also ported for ainol novo7 Advanced ?
endrju100 said:
Is it possible that someday this recovery will be also ported for ainol novo7 Advanced ?
Click to expand...
Click to collapse
http://forum.xda-developers.com/showthread.php?t=1378594
you should use search engine before post a question.
vanduhl said:
This is great news. If you are wanting to test any work with users on Velocity Cruz t301's which also run an ingenic processor (JZ4760) .
UPDATE: Tried running CWM for the hell of it on the t301 . Stuck at boot screen was able to get back to original recovery however. I'm guessing it might be due to the entry point into the kernel . Since the t301 is ancient Froyo. Would love to take a look at the source
Click to expand...
Click to collapse
How did you get back to your stock recovery image on the T301? I think I borked mines on a T105 accidentally with ROM Manager. I accidentally pressed the screen too many times while 'exploring' and the delayed input caused ROM Manager to start flashing a recovery. Now I can't boot into recovery. I just see black nothing.
EDIT:
Disregard - My stock recovery boots. I was performing the boot into recovery procedure incorrectly. Also, because the recovery.cpio.img was in /system I assume it was flashed on each power cycle.
Apologize: I have read the complete topic and now understand that at present it is only for Novo.
Please dont use this thread to talk for another devices that arent be Novo7 Basic.
Asi cant start a new thread yet, here is my thread at spanish forum comunity with a full starter packs of mips app + games and a guide to be root.
htcmania. co m/showthread.php?t=303749
I´ve got successfully get a compiled MIPS version of Titanium backup that works like a charm for our device Novo7 Device! Checkout at the link upside.
Regards. (I will open a new thread when i´ve got 50 messages...)
fun_ said:
it seems source code for xboot, android 2.2 and (part of?)kernel source for NOVO7B is released. I don't try to compile them yet so I may be wrong.
I'll check them later.
Click to expand...
Click to collapse
what other info would you like?

Recovery BootStrap (TWRP) - Motorola Defy\Bravo

Recovery BootStrap (TWRP) - Motorola Defy\Bravo
Version: 4.0
Install Recovery BootStrap (TWRP) for Motorola Defy\Bravo via a USB cable. For computers running the Windows\Linux (port version) operating system.
Download: (Windows: MEGA / Google Drive) | (Linux: port by nastys post>>)
Install Recovery BootStrap (TWRP) you can right out stock firmware (without custom recovery) with superuser.
Recovery BootStrap (TWRP) - for the recovery say thank Quarx, after installation, you can install the rom CyanogenMod from Quarx for December 2014 (but do not forget about resize.zip).
Can be installed on Defy (MB525), Defy Plus (MB526), Bravo (MB520).
Requirements for smartphone:
Enable USB debugging
Superuser (ROOT)
Free space on the memory card of 100 megabytes
Instructions:
1. Download the archive
2. Unpack it somewhere else with a short path, for example D:\andro
3. Connect your phone via USB cable ("debugging on USB" should be included)
4. Run the install_bootstrap.cmd
5. When you see the label "Let's Start? =)", press any key
6. If the superuser ask permission for full access "ADB Shell", allow.
7. After installing the smart phone will automatically restart
!IMPORTANT! after restarting the Stock firmware will not start!, but you will have BootStrap (TWRP) so you can safely install custom firmware\rom
Change log:
V3:
Changed how the script
Fixed installation errors recovery on Android 4.x and later
V4:
The script changed drastically
After installation removes trash from the memory card (so far only on Android 4.x and later)
Made for normal (mortals) users , before you start the installation script checks (by model) which smartphone connected to the computer, if your smartphone is not supported script report it and stop installation, if supported will give something "Device: MB525".
Serviceability checked on the Chinese 231 (Defy) firmware with superuser (what say thank borndead), and on the Asian 231 (Defy)
Questions\FAQ:
Error "[ERROR] Verify device!", what to do?
Error "[ERROR] Verify device!", it is may mean the following:
1. You have not enabled USB debugging
2. Your smartphone does not support this Recovery. (only for MB525, MB526, MB520)
3. You need to confirm the action ADB on your smartphone
4. Or you have some other connection problems
Stock transition to CyanogenMod 11 of Quarx
Stock transition to CyanogenMod 11 (firmware and find all necessary files can be here) of Quarx in short (generally as described on the website Quarx, only simpler and under Windows)
1. Install Recovery BootStrap (TWRP) via USB
2. Enter Recovery install resize.zip
3. Restart your smartphone
4. Install CyanogenMod 11 and GApps
Good work, comrade! I flashed CM11 on the Moto Defy - everything works!
We did observed some cases, where a "new life (resized)" Defy is not booting anymore. Only solution was to reflash SBF and start from scratch.
Does this mean, it is possible to recover TWRP from PC? That would be a step a head!
This is amazing! Everytime I needed to reflash the stock ROM I needed to install cm10, then cm11, then new bootsrap etc...
Unfortunately I don't use Windows...
 @Octanium91 Would you mind if I port your script to GNU/Linux?
starbright_ said:
We did observed some cases, where a "new life (resized)" Defy is not booting anymore. Only solution was to reflash SBF and start from scratch.
Does this mean, it is possible to recover TWRP from PC? That would be a step a head!
Click to expand...
Click to collapse
I tried to do something like that, is not yet happened. Perhaps in the future even try
nastys said:
This is amazing! Everytime I needed to reflash the stock ROM I needed to install cm10, then cm11, then new bootsrap etc...
Unfortunately I don't use Windows...
@Octanium91 Would you mind if I port your script to GNU/Linux?
Click to expand...
Click to collapse
Maybe. If Iunderstand with GNU/Linux scripts
The new version, V4
The new version, V4
Changes:
The script changed drastically
After installation removes trash from the memory card (so far only on Android 4.x and higher)
More debugging: Now the script itself is not closed, and tells the user exactly what happened.
Sorry debris removal only works on Android 4.x and later.
Linux port done!
@Octanium91 I ported it to C++ (for Linux only at the moment). Please add it to the first post . Here is the link: MediaFire | MEGA
On Ubuntu just mount the ISO as image (not archive) then click 'Run' (or you can also extract the ISO and run the executable directly). It works on x86 (32 bit) and x86_64 (64 bit) CPUs. The source code is also included in the ISO. Tested on Ubuntu 14.10 and 16.04 (64 bit).
I tested it with both stock 2.3.6 rooted and CM11. It seems that the stock ROM won't boot after flashing the new bootstrap, but the recovery works fine
Also your version has a very bad bug: it flashes Defy bootstrap even on Bravo!!! It should flash Motorola Bravo specific bootstrap instead. My version only works for Motorola Defy and Defy+ at the moment, but you can edit the source code. EDIT: they are the same file with different names. I updated my version to support MB520.
After run the command script, when i boot in TWRP SDcard shows 0mb.
Already tried flashing the SBF recommended by quarx and after that the root SBF, but the result is always the same.
With CM recovery i can see the SDcard properly, but after the resize, or bootstrap, i always get 0mb at SDcard.
Any help?
Thanks!
evilinheaven said:
After run the command script, when i boot in TWRP SDcard shows 0mb.
Already tried flashing the SBF recommended by quarx and after that the root SBF, but the result is always the same.
With CM recovery i can see the SDcard properly, but after the resize, or bootstrap, i always get 0mb at SDcard.
Any help?
Thanks!
Click to expand...
Click to collapse
Format your SD card (to FAT32) or use another one.
Octanium91 said:
The new version, V4
Changes:
The script changed drastically
After installation removes trash from the memory card (so far only on Android 4.x and higher)
More debugging: Now the script itself is not closed, and tells the user exactly what happened.
Sorry debris removal only works on Android 4.x and later.
Click to expand...
Click to collapse
nastys said:
@Octanium91 I ported it to C++ (for Linux only at the moment). Please add it to the first post . Here is the link: https://www.mediafire.com/folder/candnhxj8aovj/Defy_Bootstrap_Installer_for_Linux
On Ubuntu just mount the ISO as image (not archive) then click 'Run'. It works on x86 (32 bit) and x86_64 (64 bit) CPUs. The source code is also included. Tested on 14.10 x86_64.
I tested it with both stock 2.3.6 rooted and CM11. It seems that the stock ROM won't boot after flashing the new bootstrap, but the recovery works fine
Also your version has a very bad bug: it flashes Defy bootstrap even on Bravo!!! It should flash Motorola Bravo specific bootstrap instead. My version only works for Motorola Defy and Defy+ at the moment, but you can edit the source code.
Click to expand...
Click to collapse
Greetings guys, I'm a user from the Atrix 2 section and a part of the current device supporters there. It's a pleasure to finally post here, 'the domain of Quarx' haha.
I was wondering if this recovery is able to flash and boot android Lollipop 5.0 roms yet? If so, then is there some way to port it from source to my or other similar Moto devices in the OMAP bracket with locked bootloaders?
I'm an Android novice, but I'm experienced in building custom recoveries and roms, as well as beginner git commands, so no need to hold anything back, lol. I appreciate the work you're all doing here, please continue to make the difference. Thanks for reading this and take care!
answer
Aceofzeroz said:
Greetings guys, I'm a user from the Atrix 2 section and a part of the current device supporters there. It's a pleasure to finally post here, 'the domain of Quarx' haha.
I was wondering if this recovery is able to flash and boot android Lollipop 5.0 roms yet? If so, then is there some way to port it from source to my or other similar Moto devices in the OMAP bracket with locked bootloaders?
I'm an Android novice, but I'm experienced in building custom recoveries and roms, as well as beginner git commands, so no need to hold anything back, lol. I appreciate the work you're all doing here, please continue to make the difference. Thanks for reading this and take care!
Click to expand...
Click to collapse
Hi!
flash and boot android Lollipop 5.0 roms - just can not say, but it is theoretically possible (need to check).
If so, then is there some way to port it from source to my or other similar Moto device - No, this is not possible (specifically, in this case). BUT this method you can set recovery to another smartphone (it is theoretically, need to try)
Here recovery that are in the public domain, I think that they can install Lollipop 5.0 roms - TWRP2 \ Safestrap
Moto devices in the OMAP bracket with locked bootloaders? - Most likely will not work, but no one stops to try
Octanium91 said:
Hi!
flash and boot android Lollipop 5.0 roms - just can not say, but it is theoretically possible (need to check).
If so, then is there some way to port it from source to my or other similar Moto device - No, this is not possible (specifically, in this case). BUT this method you can set recovery to another smartphone (it is theoretically, need to try)
Here recovery that are in the public domain, I think that they can install Lollipop 5.0 roms - TWRP2 \ Safestrap
Moto devices in the OMAP bracket with locked bootloaders? - Most likely will not work, but no one stops to try
Click to expand...
Click to collapse
Many thanks for the prompt and well ordered reply! I'll look into your suggestions and I'm aware that there aren't many available recovery software for our locked bootloader phones.
We were actually trying to get Safestrap working on our device since last month, but it's failing to work correctly in booting our kexec roms. So I thought I'd ask here since the Defy works by using the 2nd boot like us, but it's still under investigation. Thanks again for your assistance, we're not out of the game yet and we'll get things rolling eventually. Take care!:thumbup:
Sent from the Ace's MB865 using Tapatalk
Error. More than one device and emulator
what am i doing wrong?
LoeWn said:
Error. More than one device and emulator
what am i doing wrong?
Click to expand...
Click to collapse
Perhaps you have not enabled USB debugging
Requirements for smartphone:
Enable USB debugging
Superuser (ROOT)
Free space on the memory card of 100 megabytes
I did enable usb debugging
LoeWn said:
I did enable usb debugging
Click to expand...
Click to collapse
You can send us a screenshot?
I had a successful installation of a december build and twrp 2,6x installed, everything ran just fine. But when the CM tells me there is a update and i download it does not install from recovery, get errormsg. Also apps like rom manager pro tells my phone is not compatible with any updates, and that i should install CWM recovery. So is it possible to install a real CWM on a defy mb526?
Hi, I flashed Recovery BootStrap v4 on the Defy MB525, but its not working. After flash and reboot, phone starts booting, but it ends up with the following screen.
Doesn't matter if I choose Recovery or continue. I can press the menu button (to choose recovery) and nothing happen, till the 3rd press. Than display goes black and thats all .
Any idea where could be the problem or what I'm doing wrong?
Edit: maybe its related to the bootloader version, which is 09.10
Haldy said:
Hi, I flashed Recovery BootStrap v4 on the Defy MB525, but its not working. After flash and reboot, phone starts booting, but it ends up with the following screen.
Doesn't matter if I choose Recovery or continue. I can press the menu button (to choose recovery) and nothing happen, till the 3rd press. Than display goes black and thats all .
Any idea where could be the problem or what I'm doing wrong?
Edit: maybe its related to the bootloader version, which is 09.10
Click to expand...
Click to collapse
Based on first screenshots, Recovery installed. Now you need to install system.
Than display goes black and thats all - maybe have to wait
marcooleo said:
I had a successful installation of a december build and twrp 2,6x installed, everything ran just fine. But when the CM tells me there is a update and i download it does not install from recovery, get errormsg. Also apps like rom manager pro tells my phone is not compatible with any updates, and that i should install CWM recovery. So is it possible to install a real CWM on a defy mb526?
Click to expand...
Click to collapse
In principle it is possible, but it does not make sense.

Looking for a complete/real Linux on my Nexus 5

Hello everybody,
I've been trying to get a complete Linux (for example Debian or Ubuntu) on my old Nexus 5 (NOT Ubuntu-Touch). All the Linux commands ("sudo" etc.) should work and I need to install Python.
Since I would like to use the Nexus 5 only for network stuff and bots at home, I don't really need Android anymore on the device.
I have no additional equipment (for exemple Bluetooth keyboard / mouse or USB to HDMI adapter) and I would prefere not buy any equipment.
Windows 10 would be enough as well on the Nexus 5 (I read it should work with some Android devices).
I got TWRP recovery on the phone.
What I've tried so far:
1.
The Maru ROM (Android + Linux parallel running). However, for the first configuration on the Linux-Desktop it seems like I need an adapter + Bluetooth keyboard & mouse, since the first configuration has to be done on the desktop
But have no corresponding periphery.
After the initial configuration of the Linux Desktop/Interface, via USB to HDMI adapter, you can access the Linux system on the Nexus 5 via SSH or VNC.
Apparently it's also possible to do the first configuration of the Linux interface via VNC. But I have not succeeded. I've followed various instructions and tried from Android by using terminal emulator to acces the parallel running Linux. VNC Viewer Apps were also used. Everything did not work out. Either there were error messages that the system is not "listening" on the port or that the access was denied. Is there an idiot-safe step by step guide for this?
2.
Next I flashed "[NEXUS 5][N7.1.2] - Pure Nexus"
I tried to to configur the terminal emulator and Termux with BusyBox and the "sudo installer app" to behave as if the terminal would be a real Linux. I also failed (couldn't get sudo command and other commands to work).
3.
Finally, I've used the "Complete Linux Installer" app. However, it turned out that my kernel does not support "loop device" (which is a prerequisite). So I tested the Franco Kernel and another custom kernel (name forgotten), which also did not work. I haven't found a custom kernel which is explicit "loop device" supported.
What ROM / Kerel Combo is required to use "Complete Linux Installer"?
Since I need no Android it would be the simplest thing to flash Linux (or Win10) with TWRP on to the Nexus 5. Is there some pure Linux ROM for the N5?
Otherwise an idiot-safe step by step guide for the N5 for the method 1 (Maru ROM via VNC without HDMI adapter), or for the method 3 ("Complete Linux Installer") would be great!
If someone has a full functional Linux or Win10 on the Nexus 5 (without additional peripherals) please report! Thanks in advance!
really no one an idea?
A ROM/Kernel Combination for the Nexus 5 with "Loop Device" support would be enough! (see 3. "Complete Linux Installer")
playerkirk1 said:
The only way I could imagine installing Ubuntu or any form of Linux based OS other than android would involve using EFIDroid, which isn't hard to install at all.
Here's the link to that.
I'd imagine you'd have to find a way to efi boot a version of Ubuntu arm or Debian arm, because the Nexus 5 is an arm device. As for Windows 10, IIRC Microsoft still hasn't released Windows 10 arm out yet, so we can't find out if we can port it back to arm32 or lower end Snapdragon devices like the Nexus 5.
Click to expand...
Click to collapse
Ok nice thx! I'll try it with EFIDroid.
Unfortunately I have not much time most recently... So it will have to wait.
I'll report if I manage to run any Linux version on the N5.
One more Question:
Is it easy to find an arm version of Debian or Ubuntu? Haven't searched yet.
Why use EFIDroid?
I built Gentoo linux on my htc hd2 a yaer ago (and lost the image a few weeks ago). It's not really hard to install a full native linux system on your phone and boot to it DIRECTLY (without android).
All you need is
a custom kernel with support for loop devices (may need some changes later for the display, or some dirty hacks)
a base system for gentoo and some linux knowledge
creating a loopback device and using it for the system storage
working from within android in the beginning on the loopback device, until the base system is installed, configured, bootable and has SSH ENABLED via ethernet, with custom ip address (this is tricky, as it's the only way to use the phone before a gui is installed)
working from the pc using ssh, installing all needed packages
failing too many times until everything works
Edit: while installing the system, you must maintain an ssh connection via usb, as i said earlier, and to reach the internet, you must use iptables from the host pc to share the connection and configure your phone to get to the internet using the host.
As i said, i had done it in the past for the HTC HD2, but never posted it (due to ****ty internet connection). I had done all the system compiling directly on the HD2. On such a slow device (1ghz single core, 512mb ram, class 4 sd card) it took about 2 weeks for the GUI to be working.
What i did later was take the same base system and run it on the HTC M8. while it works, display never worked correctly. I had to use a program i compiled to refresh the screen all the time, which consumed cpu quickly.
Anyway, it can be done on any phone. There's no such thing as impossible.
A shot of the end result gui on hd2 (i know, horrible gui and wtf is that resolution )
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
tl;dr: Install Gentoo linux
@ playerkirk1
Ok thanks. Maybe this way leads to a solution for me.
@ gilbert32
Impressive! That seems to me like pretty advanced work! I'm afraid my Linux knowledge is fare under yours...
But like I thought, it's possible! Thanks for sharing!
gilbert32 said:
a custom kernel with support for loop devices (may need some changes later for the display, or some dirty hacks)
Click to expand...
Click to collapse
So again it depends on the custom Kernel with loop device suport. I couldn't find one explicitly supporting "loop device" for the N5.
If I had, I would have used the "complete Linux installer" app.
(Check out 3. on my first post)
shomu said:
So again it depends on the custom Kernel with loop device suport. I couldn't find one explicitly supporting "loop device" for the N5.
If I had, I would have used the "complete Linux installer" app.
(Check out 3. on my first post)
Click to expand...
Click to collapse
It's not that hard to get it working
Should be about downloading the source code of any kernel you want to use, make menuconfig, adding loop device support and compiling the kernel. it's about 5-6 commands.
I honestly didn't know this was even possible, but this is amazing. I just thought you'd need EFIDroid and an ISO to boot off of, but that seems way too complicated to do reliably. I'll definitely try this myself because it sounds awesome. Thank you, you rock!
Click to expand...
Click to collapse
Yes, it is very possible. In the old days before android (where developers used to port linux to windows mobile devices, using HaRet), it was about compiling a working kernel, adding a ramdisk that prepares the loop device and mounts it, then changing the root to the loop device. In another way, to achieve it on a new phone:
Build the os for your phone, or install it. You must have a working loop device in the end, containing the root filesystem
Create the init file to use with the ramdisk later
compile a kernel that supports all features required by the OS
package the ramdisk and kernel into a bootable image, that you can fastboot boot or flash
On The M8, This is what happens:
Bootloader boots boot.img. I use fastboot boot boot.img since i don't want to override my boot image
kernel boots and runs my init. Which is a series of shell commands.
The commands mount the required partitions, then mount the loopback device to somelocation
init calls for switch_root, which turns somelocation into the new root filesystem, and launches the appropriate init script (IIRC /sbin/init in gentoo)
the new init starts its work, calls for OpenRC, etc etc etc
As i said before, i got it booting on the HTC M8 by grabbing a working boot image for the device, and modifying the ramdisk to use scripts for the HD2. I had modified those scripts to match the M8 requirements, then repackaged the image and voila. If i still had my working image, i would've uploaded it for you and tried modifying the needed files.
If you get the needed kernel working, i will help you with the next steps
and just another pic i found.
gilbert32 said:
It's not that hard to get it working
Should be about downloading the source code of any kernel you want to use, make menuconfig, adding loop device support and compiling the kernel. it's about 5-6 commands.
Yes, it is very possible. In the old days before android (where developers used to port linux to windows mobile devices, using HaRet), it was about compiling a working kernel, adding a ramdisk that prepares the loop device and mounts it, then changing the root to the loop device. In another way, to achieve it on a new phone:
Build the os for your phone, or install it. You must have a working loop device in the end, containing the root filesystem
Create the init file to use with the ramdisk later
compile a kernel that supports all features required by the OS
package the ramdisk and kernel into a bootable image, that you can fastboot boot or flash
Click to expand...
Click to collapse
hm..ok, but I must say, I never compiled a kernel...
I got kind of "advanced" knowledge about android compared to normal "Smartphone users", but I'm definitely no developer!
So unfortunately compiling things is beyond my skills. I think I could do it with a step-by-step-tutorial, but I guess my request is too specific to find a fitting tutorial.
When it comes to Linux, I know some basics about the system and some basic commands. But usually when I'm doing stuff with Linux I use tutorials as well.
I have much more experience with Windows, html, css and some java...
So again, for everything that has to be done with Linux, I need an easy tutorial...
I appreciate your trying to help me, but unfortunately i must say it's way too advanced for me. without a detailed how-to, I will not be able to do this...
gilbert32 said:
and just another pic i found.
Click to expand...
Click to collapse
I'm feeling a bit ambitious and wanted to try something, just want to know if it's been done before.
So I want to use my other phone - Samsung Galaxy Nexus - as a home server (FTP, p2p for start and maybe some light home automation later if everything works well).
So there is a patch for the GNex kernel that allows for phone charging and OTG at the same time. Also, I would need to patch in the loop back into the kernel so I wanted to know if Gento would be able to access my HDD hooked on OTG and how the drivers work in general on Gento and if it is worth the hassle getting it from Android to Gento. Also, I plan to VNC into the phone so display drivers aren't needed to work 100%.
Opinions?
Just install Sailfish OS. It's Linux with just a modified GUI for phones.
Here you can get the latest images, instructions, help (if you need) and info about all the various things https://talk.maemo.org/showthread.php?t=99377
Then take a look at this thread https://talk.maemo.org/showthread.php?t=98882
this is a link to working arch linux chroot https://github.com/Preflex/easy-chroot/releases/tag/0.0.2
here is a pic from my setup
Now someone made a patch for wayland to open in landscape mode. here it is https://openrepos.net/content/elros34/qxcompositor
And here is also ubuntu chroot, which works with that patch https://github.com/elros34/sailfish_ubu_chroot
I moved away from android long ago. Because i want my privacy back from google. Now i do not use anything from google except youtube (without google account)
ILA said:
I'm feeling a bit ambitious and wanted to try something, just want to know if it's been done before.
So I want to use my other phone - Samsung Galaxy Nexus - as a home server (FTP, p2p for start and maybe some light home automation later if everything works well).
So there is a patch for the GNex kernel that allows for phone charging and OTG at the same time. Also, I would need to patch in the loop back into the kernel so I wanted to know if Gento would be able to access my HDD hooked on OTG and how the drivers work in general on Gento and if it is worth the hassle getting it from Android to Gento. Also, I plan to VNC into the phone so display drivers aren't needed to work 100%.
Opinions?
Click to expand...
Click to collapse
If you can get the HDD to work inside android, it will work inside Gentoo. As long as you can mount the HDD inside android it should be possible. And you really don't need android to mount it, just look for the dmesg and see if it's detected, or look for it in /dev/sdxx. If it works, then don't forget to install the specific HDD filesystem support in Gentoo.
The easiest way is Linux deploy in the Google play store, u have the option to install Ubuntu, Debian, Kali, etc. Also with the option of selecting your GUI such as KDE, lxde, etc. U can also chose to build it as an image or use an sdcard partition if you're advanced which is the best option. Most Android devices can easily support running Linux IMO, there hasn't been a device I haven't got it not running on, with the exception of the ones u can't root lol. Give it a try, you'll see what in talking about, as for the vnc use juice SSH on the play store, that's my favorite, also helps to install the hackers keyboard from the play store too. Depending on the internet it should take u less than 30 minutes to get Linux up and running
Sailfish OS (pretty darn good), Plasma-Mobile (not very efficient), and PostmarketOS (least efficient) are good alternatives
there is shortly to be some work done by wicket in my home community of Maemo ...
to get Maemo Leste OS running on the nexus 5 ...
I suggest patience.
it will happen...there are just the n9 and n900 to come first...(which are coming along nicely thus far ..)
I myself am looking forward to having Leste on both my n900's and Nexus 5's...
Leste for the nexus 5 should progress quite rapidly once work begins, considering the nexus 5 is the perfect candidate in compare with other devices.
So you may wish to keep an eyeball on the Maemo Leste OS project
shomu said:
really no one an idea?
A ROM/Kernel Combination for the Nexus 5 with "Loop Device" support would be enough! (see 3. "Complete Linux Installer")
Click to expand...
Click to collapse
KDE Plasma
Sailfish OS if you can figure out how to install manjaro
Ubuntu Touch with dock
Come on just use Google.

Categories

Resources