yashsingh1/xdaforums huggingface dataset:
[General Questions and Answers] Nofan Tasi:
Hi kieronspitter

Another attempt to build CWM fails to boot in recovery ... Instead it tries once and then boots normally. As if, somehow, a custom recovery was detected, but then, how come Chainfire's CF-Auto-Root recovery img does boot (and, moreover, installs root). It is far above my experience. Note that, unlike what was reported by others, my own built CWM did not boot as stock one, neither was it overwritten by stock one. It just happens to not boot (either because not good or because refused). I compared both stock and mine and only ramdisk (of course) is different, in ramdisk same fstab is used. I built ROMs and CWM recoveries for various devices in the past. But firmware becomes more and more immune, it seems...

Perhaps it has to do with Samsung KNOX?

recipe:

--

mkdir sm-g3815

cd sm-g3815

export PATH=~/bin:$PATH

repo init -u git://github.com/CyanogenMod/android.git -b cm-11.0

repo sync

. build/envsetup.sh

make -j8 otatools

export PATH=$PATH:$PWD/out/host/linux-x86/bin

build/tools/device/mkvendor.sh samsung wilcoxlte /tmp/recovery.img

lunch cm_wilcoxlte-eng

. build/tools/device/makerecoveries.sh cm_wilcoxlte-eng

--

env:

--

PLATFORM_VERSION_CODENAME=REL

PLATFORM_VERSION=4.4.2

CM_VERSION=11-20140120-UNOFFICIAL-wilcoxlte

TARGET_PRODUCT=cm_wilcoxlte

TARGET_BUILD_VARIANT=eng

TARGET_BUILD_TYPE=release

TARGET_BUILD_APPS=

TARGET_ARCH=arm

TARGET_ARCH_VARIANT=armv7-a-neon

TARGET_CPU_VARIANT=cortex-a7

HOST_ARCH=x86

HOST_OS=linux

HOST_OS_EXTRA=Linux-3.12.7-gentoo-x86_64-with-Ubuntu-13.10-saucy

HOST_BUILD_TYPE=release

BUILD_ID=KOT49H

OUT_DIR=/root/sm-g3815/out

--

have a nice day
[General Questions and Answers] aureljared:
What are the contents of /system/etc/install-recovery.sh?

That slippery little git was responsible for abnormal recovery behaviour on the AT&T Galaxy Express 1.

It replaced whatever was on the recovery partition with stock on every reboot.

Dunno if this helps you guys :-/

Beamed from my Galaxy Express using Tapatalk
[General Questions and Answers] Nofan Tasi:
Hi aureljared

Right, on some stock ROMs this script reinstalls stock recovery on boot.

It seems /system/etc/install-recovery.sh on my device got added by CF-Auto-Root because it is not present in stock system ext4 image (as I checked)

content is:

--

#!/system/bin/sh

# If you're implementing this in a custom kernel/firmware,

# I suggest you use a different script name, and add a service

# to launch it from init.rc

# Launches SuperSU in daemon mode only on Android 4.3+.

# Nothing will happen on 4.2.x or older, unless SELinux+Enforcing.

# If you want to force loading the daemon, use "--daemon" instead

/system/xbin/daemonsu --auto-daemon &

# Some apps like to run stuff from this script as well, that will

# obviously break root - in your code, just search this file

# for "install-recovery-2.sh", and if present, write there instead.

/system/etc/install-recovery-2.sh

--

(there is no /system/etc/install-recovery-2.sh)

What puzzles me is that the CWM I built does not boot. It has same zImage and other parts as stock, but, of course, ramdisk is different than stock.

Would the device refuse to boot custome recovery altogether?
[General Questions and Answers] pedestre:
Hi all, I'm going to have this mobile in a few weeks. I've seen theres no custom recovery for this device. As express 2 is almost the same hardware as S4 mini, I've repacked stock kernel and ramdisk with i9150 recovery, hoping it can work, but as I said I haven't tested because I don't have the mobile yet.

If anyone can test it, would be great, but I'm not responsible of any damage caused by this file or for any other reason. You probably void your guarantee. Use at your own risk

Flash with odin:

Regards¡¡

Edit: removed because it didn't work :(
[General Questions and Answers] :
Hi pedestre

Nice idea to use S4 mini ramdisk and keep rest as stock.

But, just like is the case with my own built cwm

(I was suspecting something wrong with my ramdisk),

- system prints

BOOTING RECOVERY

- vibrates a few times

- then boots normal

Note that I clone to partition with dd, like

dd if=recovery.img of=/dev/block/mmcblk0p14 bs=4096

So I put back stock recovery image (which does boot fine).

I use GooManager for booting into recovery.

Note that Chainfire's CF-Auto-Root is also using a custom recovery, so, we must be doing something wrong.

Can you try to build a CWM recovery image from source? ROM is available on SamMobile

Have a nice day
[General Questions and Answers] pedestre:
Yes, I'll try to build it from sources but I need to have the mobile first.

I made changes in the ramdisk, leaving only the recovery part from i9195 but as I expected it doesn't work, some guy in a Spanish forum has tested and recovery didn't start :(, I'm going to edit the post.

recovery.img stock (in case anybody has tested and want to go back to stock recovery)
[General Questions and Answers] aureljared:
On the contrary, AutoRoot employs a stock recovery image modified to automatically drop the superuser binary into /system/xbin. The process then restores the unmodified stock recovery.

Beamed from my Galaxy Express using Tapatalk
[General Questions and Answers] pedestre:
Exactly, auto-root doesn't change the stock recovery, it just injects supersu and binary
[General Questions and Answers] :
'custom' recovery

Hi aureljared pedestre

I can provide stock ZIP if you like, just PM me. But it is on SamMobile too (where I got it from).

Sorry to say, but, technically, CF-Auto-Root -does- boot a modified (aka custom) recovery (in order to install root and then restores stock recovery).

My point was: it -is- possible to boot a modified (aka custom) recovery, everybody who CF-Auto-Root-ed SM-G3815 did so. The modified (aka custom) recovery images I tried so far were equal to stock exept for ramdisk (which, of course, can differ a lot from stock). Perhaps they booted the kernel but, later, they fail. Device vibrates a few times and, luckily, ends up booting normal. Next I restore stock recovery manually.

Perhaps, rather than building a full blown CWM or TWRP, one should try to start from stock recovery (or from CF-Auto-Root one) and modify step by step to get where one wants to be. To be honest, for me that is not far, I prefer command line usage and I do not need a GUI to make backups or install custom ROMs or clean up partitions. For me it would be OK if I could have stockrecovery + su binary + adb + busybox + access to external SD. With these one can do whatever from linux command line shell. More interesting would be if one could also have IP access in which case one could run sshd from recovery and access the device in recovery with ssh.

I may want to try to build such kind of solution myself.

Thanks

have a nice day
[General Questions and Answers] pedestre:
Thanks, I already have the stock ROM

Auto-Root doesn't include stock recovery, just lunch some scripts to inject su and supersu, then it restores stock recovery for the next booting.

My goal is to install a custom recovery, it is the only comfortable way of installing custom ROMS (stock and Cyano). You can do many things in the command line but not everything and everywhere and for most users it is not an option.

Regards¡¡
[General Questions and Answers] :
I attempted to modify CF-Auto-Root recovery.img to just provide adb access and nothing more ... but I failed, phone vibrates and boots normally.

So I guess this kind of adjusting is for the more experienced. Hopefully someone comes with a working custom recovery image.

have a nice day
[General Questions and Answers] :
Red triangle sick recovery green android man issue solved: I restored stock /cache/recovery directory and green android man does its thing once.
[General Questions and Answers] pedestre:
Hey guys, looking into samsung source code, I've seeing that defconfig is different in express2 than s4 mini, config_cane_defconfig is used in express2, maybe that's the reason why S4 mini recovery doesn't work in express2.

I'll try to build CWM using cane instead serrano ...
[General Questions and Answers] :
Hi pedestre

Thanks a lot for trying new builds! You talk about kernel config, right?

How does your build environment look like?

Mine was loosely based upon f9ee506dc02a4f6dddd1dc6ed315ce80 attempt on http://builder.clockworkmod.com/ which seems to choose cm-11.0, hence PLATFORM_VERSION=4.4.2, however, I don't think that shoud matter much.

Thanks.
[General Questions and Answers] pedestre:
Hi,

yes, I was talking about kernel config

I'm using 10.2 because I already had the cyanogen tree from the S2. I've used serranoltexx from S4 mini, changing the kernel config. In fact I have built the recovery.img (after correcting some building errors in the code), but unfortunatelly I can test it, I don't have the mobile yet. It is really dificult to do anything without having the phone :crying:
[General Questions and Answers] :
Hi pedestre

Right, I had to correct some compilation warning/errors too when I built sm-g8135 kernel a while ago,

but that's perhaps because I use a cross compiler gcc version 4.8.2

I don't mind trying your CWM recovery image.

Either you publish it here public (warning people it is at own risk). Or you PM me and I will make an account on my ftp server for you to upload to.

Thanks for your effort.
[General Questions and Answers] pedestre:
Thanks¡¡¡

There you have it but I don't think this first attempt is going to work but who knows.

Removed (it doesn't work)

If it doesn't work, try to get recovery.log from /cache/recovery

:fingers-crossed::fingers-crossed:
[General Questions and Answers] mek32:
I tried this and doesn't works. I had to reflash the stock recovery.

Hope you find the correct way to install it.

thanks and good luck.
[General Questions and Answers] pedestre:
Hi, thanks, It's goinng to be hard ¡¡

What did it do? black screen, stuck in samsunng logo, reboot?
[General Questions and Answers] mek32:
only reboot and can`t get in recovery mode.
[General Questions and Answers] pedestre:
Another try. I have used source code (kernel) from Samsung. If it fails (probably), it means we have to change something in boardconfig and I have no idea what we should change

Thanks¡¡

recovery.img_2
[General Questions and Answers] mek32:
pedestre!!!! IT WORK'S!!!!!! YEAH!!!!! FUNCIONA TIO FUNCIONA!!!!!!!!
[General Questions and Answers] pedestre:
Greattttttt ¡¡¡¡

Please, check backup and restore (I think you won't be able to test anything else)
[General Questions and Answers] mek32:
ok. you are the boss!!!!!!
[General Questions and Answers] :
Hi pedestre

Congratulations and thanks a lot, this recovery works!

Have a nice day
[General Questions and Answers] Mandrake93:
hi

Hello everyone :D

I have a question, on my express 2 i have "G3815XXUAMJ1" firmware, i also rooted the phone, but, this recovery can work good on my express 2?

i'm afraid to install it :crying:
[General Questions and Answers] :
Hi Mandrake93

I am using this CWM on G3815XXUAMJ1_G3815VFGAMJ1_PRO (Belgium).

If you only change recovery partition, not much can go wrong provided

you have a backup of the stock one. Then you can always restore.

You can get the stock recovery partition image by downloading

SM-G3815 stock firmware (e.g. from SamMobile), or, since you have

root, you can copy the backup recovery partition content yourself.

People use various methods to write a recovery.img to recovery

partition or to backup recovery partition to a file. Having root, I

use unix dd command.

have a nice day
[General Questions and Answers] shinra00:
Thanks for all the hard work!

So i just got a sm-g3815 an i started reading a LOT of foruns about roots, roms, kernels, flashing, CWM... i had no idea there were so many things about the phones O.o

I´ve got a question about this recovery image. What is this for? after rooting the device what is the purpose of this image? can someone explain me please?

sorry but i got a couple more questions.. after the root how can i flash CM11 to the device? any forum that you can point me to?

about the kernel..after reading some foruns this is what i understand the less..what is the benefit of changing it? for which one should i swap? (your opinion of course.)

and last thing, sorry really, anyone knows how to unlock this devicE?

Thank you very much!
[General Questions and Answers] :
Hi shinra00,

A recovery image allows to boot from separate partition for various tasks. Think about it as booting a PC from floppy, CD or USBstick.

The stock recovery image is (on purpose) limited in what tasks one can do.

The custom recovery images (like CWM) are not limited. They have root (so you can do whatever via adb) and they have a GUI for such things like backup/restore from/to various partitions. And also to install custom ROMS.

There is no CM built for sm-g3815 (yet).

Using custom kernel is often a matter of taste. Some custom kernels support features you may want to have. As far as I understand, custom kernel needed to be built for (only for) CWM.

What sort of lock do you experience?

Thanks
[General Questions and Answers] shinra00:
Thank you very much for the reply! I have read SOME foruns about the android software and since i´m new to android modding i still can get pretty confused.

Hmm ok I finally got what a recovery image is for. Thank you for the comparison to Windows (that i know pretty well).

As far as for the kernel for this device (galaxy express 2 sm-g3815) I should look for the some made for the CWM built by Chainfire then right? http://xdaforums.com/showthread.php?t=1980683&page=21 bottom of the page

The lock wel..i´m sim locked to Vodafone Portugal, i´ve read that rooting wont make a difference (right?) does anyone knows a way to unlock it? I´ve read here that a user from XDA (terminal23 ??) unlocked it via Imei to one of those paid websites a lost the wifi connection O.o dont really know what he did to recover it.

Once again thanks for the time and explaining!
[General Questions and Answers] :
Hi shinra00

The URL you mention was for Chainfire's Auto Root method which he kindly implemented for sm-g3815. To do so he needed a -stock- recovery image. Rooting means adding superuser permissions and control to ROM. It does not need to change kernel or ROM partitions in any other way. In general there usually is no need to change the linux kernel. The sm-g3815 CWM (Clockwork MOD recovery) was kindly provided by pedestre. As far as I know he had to build a dedicated kernel for the recovery partition in order to make CWM GUI application work.

I cannot speak about lock. It does not seem to apply for my phone (Belgium)

Thanks
[General Questions and Answers] Ztrindberg:
Hello

I am sorry but i cant find the CWM that you say was provided by terminal32. Do you know where it is?

Regards

sent from my stone Note N7000
[General Questions and Answers] shinra00:
Hi everyone how are you?

Is there any news about CWM for our phone? I am asking this because i want to create a full ROM backup with apps and information but the more i read it always leave me to flashing CWM. I installed Rom manager but cant seam to do much because there is no CWM for this device, or is there?

First thing first. Can someone please explain me what does it mean to "flash" something? I do need the CWM (bahh the more i read the more doubts i get...)

Second. I installed the Titanium Backup app (phone is rooted) and backed up everything i have. Does this mean i have a full ROM backup? Or that all apps, and information is secured? Because i opened the folder that contains the titanium backup and all i see is a lot of of rars in there. I can only back it up with Titanium right?

Sorry for all the questions, thank you very much in advance for you time. Cheers!
[General Questions and Answers] :
oops, I meant pedestre

sorry everybody

---------- Post added at 01:28 AM ---------- Previous post was at 01:21 AM ----------

Hi shinra00

We have pedestre's CWM.

I am not a teacher so below may not be eductional:

Flashing boils down to erasing and replacing one or more partitions content. For example if you flash system partitions content you get another ROM.

Or if you put pedestre's image onto recovery partition, you have a CWM

Just like with computers, there are several backup/restore methods.

- Titanium can do backup/restore of all apps including their data.

- CWM can do backup/restore of partitions (puts them in tar balls or image files).

- dd can do backup/restore of partitions (to/from image files)

Usually (but not always), the program/method to restore is the same (but opposite) one as the backup was made with.

And, as always, make a backup before overwriting.

Thanks
[General Questions and Answers] shinra00:
Thank you very much for your time explaining me. it was really useful :)

In order to place Pedestre´s image i need to, please correct me if am wrong

1. Download and install the Samsung USB drivers on my PC;

2. Download and install ODIN in desktop;

3. Disconnect the phone and power it off;

4. Boot the phone into Download Mode (Volume Down + Home + Power buttons at the same time);

5. Plug in the phone to the PC. See the Added! message in the Odin window;

6. Click the PDA or AP button in ODIN and load the

Pedestre´s image.tar

;

7. Leave everything else in ODIN as it is. Check screenshot below for confirmation

8. Have Auto Reboot, F. Reset Time and PDA or AP checks on in ODIN;

9. Press Start

(just did this so if anyone comes across this forum tab with the same doubts as i have it will be like a tutorial)

After this will i have CFW my phone? one last thing the image i downloaded in this tab as Pedestre´s image has the termination .tar.md5 is it correct like this? I´m asking because all the other forums i read the images everyone talks about are just .tar

Thank you for the help!
[General Questions and Answers] pedestre:
It's the same format (tar) but adding md5 Odin checks first if the file is not corrupted
[General Questions and Answers] shinra00:
Thanks Pedestre! Pretty cool that i´ve been talking about you, hopefully good enough, and you replied to my doubt :)

Let me use this opportunity to thank you for the hard work! Good job, Thanks!

Finally, now i understand what flashing and all its process works =)
[General Questions and Answers] :
Hi shinra00

I think tar.md5 is just fine.

About windows flashing method. I do not have a windows machine so I cannot say. Maybe someone reading this thread has flashed Pedestre´s recovery image with ODIN? If so, I let him/her comment.

Myself I simply copy recovery images from/to recovery partition with UNIX dd command. And, I do not flash any image without a backup first.

Thanks
[General Questions and Answers] shinra00:
Thank you very much for the reply, really!
[General Questions and Answers] shinra00:
CWM on!! :)

Hi guys, how are you?

I want to leave my experience here.

So i just "flashed" Pedestre´s image to my phone via odin like i described in the previous post and all went smooth.

I installed installed Rom Manager and it says there is no custom recovery in the server for this phone. So i thought "what the hell? Weren´t i supposed to have CWM?" Then i turned off the phone, turned to recovery mode and there it was!! CWM on and fully capable to do a nandroid back up as i intended.

Thank you all for your time and patience trying to explain me this stuff!

BTW isn´t it time to add a thread to this phone on the forum? Samsung Galaxy Express 2 SM-G3815
[General Questions and Answers] TheWhisp:
So, guys, do you have a working recovery? I have set up an initial device config for SM-G3815 (wilcoxltexx - European LTE variant) for CM-10.1 (highly based on Arco's S4 Mini implementation).

I have built CWM 6.0.3.7 from CM-10.1 source, if anyone is interested: http://goo.im/devs/thewhisp/wilcox-recovery

If it works, we have a clear path to CM10.x/11.x

If anyone do try to test it, send me an e-mail or PM.
[General Questions and Answers] :
Hi The Whisp.

Have you also built custom kernel?

I had build CWM from CM source and it did not work.

Then pedestre did better, and IIRC, included custom built kernel (pedestre can confirm/deny).

Sorry all if I miss the ball.

Basically I wonder if adding custom built kernel was key to pedestre's success.

Thanks
[General Questions and Answers] TheWhisp:
Yes, I built the kernel from Samsung OS release. Basically if the CWM boots it means the CM should also boot.
[General Questions and Answers] pedestre:
Yes, adding Samsung kernel is the key. You can use the Wilcoxlte from s4 mini to build the cwm but changing the kernel source. At least I did it that way.

I can't try to build the cm because I don't have the e2 yet. My company hasn't given us the mobile yet but it didn't take much longer (finger crossed). It is necessary to have the mobile because you have to extract the blobs from the e2.

Regards!!
[General Questions and Answers] TheWhisp:
I have extracted the proprietary blobs and plan to make initial cm-10.1 build tomorrow. Would be cool if someone could give any feedback on that recovery :)
[General Questions and Answers] :
[MENTION=4148720]TheWhisp[/MENTION]

Do you have the SM-G3815 Galaxy Express 2 yourself? If so, I trust you tested your recovery to work ;)

Have a nice day.

PS: myself I am not immediately interested in CM for e2, but I am sure to remember some other people are!
[General Questions and Answers] anamorphica:
I hate stock samsung so I'm ready to try. I have SM-G3815 and I live in Finland so it''s European model. I'm going to try it and report to you when done :)

E: I tried to flash it and so far nothing. Odin slanders about invalid hash value:

<OSM> Enter CS for MD5..

<OSM> Check MD5.. Do not unplug the cable..

<OSM> Please wait..

<OSM> MD5 hash value is invalid

<OSM> cwm-6.0.3.7-wilcox.tar.md5 is invalid.

<OSM> End...

If there's some info you guys need or anything I can help with I'm yours. I know something about flashing etc. I've beed modifying my phones since sgs1 came out. Just don't know nearly enough about porting or anything. I'm ready to do all testing necessary cause I'm fed up with stock Samsung :DD

Further edit:

lol. as it seems, I didn't know about flashing too much. I got it flashed. It doesn't boot to recovery :/

---------- Post added at 05:44 PM ---------- Previous post was at 05:01 PM ----------

Pedestres recovery does boot though. As you already knew :)
[General Questions and Answers] TheWhisp:
based on the [MENTION=4041508]anamorphica[/MENTION] feedback, cm-10.1 is almost fully functional. It still needs some testing, though.

You can download the build here: https://www.dropbox.com/s/mqa2i3uytfstnpt/cm-10.1-20140324-UNOFFICIAL-wilcoxltexx.zip

I have also uploaded a working CWM 6.0.3.7 @ my goo.im profile.

Enjoy.
[General Questions and Answers] :
Congratulations and thanks for bringing CyanogenMOD to SM-G3815 :good:
[General Questions and Answers] bihslk:
I just bought a Express 2 today.

I can say its an awesome phone. No lags and smooth like hell. Fast browser.

I rooted it and removed all bloatware.

Did anyone try CM posted above and CWM recovery?
[General Questions and Answers] TheWhisp:
I also bought the device. The CWM is working fine, the CM build has some issues, obviously, since it is the first and only build I have made for it.

I have already pushed the kernel and proprietary blobs at Github, if anyone needs I can also push my device config.

Also, do you think there is going to be a KK update?
[General Questions and Answers] bihslk:
Can i use CM as daily driver or? Wich issues? Can you explain more? Thanks
[General Questions and Answers] anamorphica:
I had to drop out for a while from debugging CM cause it wasn't suitable for daily use yet and this is my only phone currently. Also I'm very inexperienced at debugging with catlog etc.

Most of the problems here are related to nfc "drivers" but here's few of them problems:

*Can't make calls (dial/call app freezes) but you can receive them.

*NFC keeps crashing (battery drain)

*wlan doesn't work

*root permissions doesn't work

*USB debugging doesn't work (might be just my inexperience causing this one)

There was few other problems but I can't recall them..

I'll continue debugging after I get most imminent work/bandstuff/school etc. out of the way. :)