yashsingh1/xdaforums huggingface dataset:
[Android Software Development] matrixzone:
Thanks for the update.

Phil just wanted to check if d2lte support has been stopped?
[Android Software Development] Bhargav97:
[MENTION=4666971]Phil3759[/MENTION],

Can you add the threads (which I gave you in previous post) to your "Subscribed Threads"? Because, there are few little problems arising...So, you can solve them directly there OR tell me directly there about what is wrong and what to do.
[Android Software Development] StlGucci:
Flashed Lg G2 d800 v6.27 and got sent to fastboot mode
[Android Software Development] 4D3:
i have tried flashing normally and without auroreboot....

neither worked, the phone just goes into download mode....

does this actually work for the G900i?
[Android Software Development] Swamphound:
Use Flashify to reload recovery image and go back to previous build.

Sent from my VS980 4G using Xparent Green Tapatalk 2
[Android Software Development] andrew.mackew:
[MENTION=643734]Philz[/MENTION]: Any chance to update t0lte? Thank you for your hard and excellent work.
[Android Software Development] chraso:
PhilZ,

I have to make change to the .config to add the line CONFIG_RECOVERY_REBOOT=y phones bcoz of the devices falling into recovery always after rebooting.

How do I do that in the BoardConfig.mk file?

Though changed it in the achr/arm/configs/defconfig file, but I can't push it to the project.

Its just this recovery that have the problem so I should keep the change to this project only.
[Android Software Development] Phil3759:
It cannot be this one only as it is cwm based

defconfig flags are related to kernel, they have nothing to do with recovery
[Android Software Development] Pons:
[MENTION=4666971]Phil3759[/MENTION] working on getting exfat-nofuse up for the m7/msm8960 specifically, but it could benefit others kernels for those that are interested.

exfat-nofuse github

fs: Add exFAT file system for the m7

fs: Add exFAT file system for the msm8960
[Android Software Development] Phil3759:
I added a few comments on github
[Android Software Development] Phil3759:
you probably missed something!
[Android Software Development] hachamacha:
Best answer I've ever seen on this forum! ;)

Love this line:

Compression: 99.23%

What is that algorithm?
[Android Software Development] Phil3759:
maybe you have external/libtar in your sources

ensure you have latest sources from git and not external/libtar

Also, is your ROM selinux enabled?

If not, you must use this flag:

BOARD_RECOVERY_USE_BBTAR := true

always read sources before compiling a new update!
[Android Software Development] Phil3759:
6.29.7 (27.04.2014)

To developers: no need to update from 6.29.2 to latest. This is just a few cosmetics change and mainly a 150kb space spared for devices with tight recovery partition
[Android Software Development] daxisalive:
Found a slight bug (if t is a bug).

It seems like a big gap appears above the first selectable option when you enter 'install zips' section of the recovery

I'm on gsm nexus.

Sent with love, from Steve Jobs using a Nexus.
[Android Software Development] Phil3759:
can you explain what you mean?
[Android Software Development] daxisalive:
I'm sorry, I tried to take screen shots to explain, but the screen shots are buggy too but let me try to explain what I mean.

So what I'm seeing in the other menus of the recovery is

'reboot

Install zips

Blah

Blah

Blah'

But when I enter the install zips menu there is a gap (as big as one selection) before the first option like this

'(gap)

Choose zip

Multi zip

Blah

Blah

Blah'

I hope I'm clear...

Edit

To make things clear, the gap is a gap. It's not like a button that is selectable.

Sent with love, from Steve Jobs using a Nexus.
[Android Software Development] Phil3759:
I see

Since menu is short, I kept the extra space:

static char* headers[] = { "Install update from zip file",
"", #this is the gap
NULL
};

In menus where there are many options, I remove that extra space you find in stock cwm

Any special reason you want to remove it?
[Android Software Development] noooooo:
With my 4ext recovery for my sensation i needed something like 3 minutes to backup a rom and also like 3 minute to restore it, now i need 11 miutes, is it normal beacouse of the bigger size of the stock rom?
[Android Software Development] daxisalive:
Well it would look more natural and fitting with the other menus if the gap was removed. Also, the gap seemed to be increased when I increase the selection size. So when I use bigger buttons, bam. Huge gap. Haha but it's okay if you would like to keep it that way. It's not a big problem. Thanks for the reply philz :)
[Android Software Development] Phil3759:
Here's cross compiled exfat-fuse 1.0.1_r362 / fuse 2.9.2

Mainly for S4 users having exfat issues with 64Gb cards (slow speed, no mount)

exfat debug

WARNING: backup your external exfat storage before testing

Please, for people having exfat issues:

download http://d-h.st/k51

While in recovery

adb push mount.exfat-fuse /sbin
adb shell
chmod 0775 /sbin/mount.exfat-fuse
/sbin/mount.exfat-fuse -o big_writes,max_read=131072,max_write=131072 /dev/block/mmcblk1p1 /external_sd

This should mount external storage exfat

Test backup and restore speed if ok

If it is stable, I will embed in next update
[Android Software Development] dandan2980:
I am on the sprint HTC one was using your recovery and love it had to go back to Twrp only because back up and restore literally took like 20min per session was a drag I only had low compression enabled and all other setting I left alone is it supposed to take this long for back up/restore?
[Android Software Development] Phil3759:
Whith usb cable connected, it could on some phones
[Android Software Development] dandan2980:
Would that include just charging the phone on the charger that would explain cause it was while I was charging my phone
[Android Software Development] Phil3759:
on some phones, yes

Try and report please
[Android Software Development] Ryuinferno:
Hi [MENTION=4666971]Phil3759[/MENTION] , your recovery builds fine and it works on GT-I9100G, using the default device tree from CM will do. But similar to GT-I9100, the ramdisk is in the form of zImage. To split, edit and join the ramdisk, use this method: https://github.com/xiaolu/galaxys2_kernel_repack/tree/i9100g

Attached here is a recent stock kernel (DDLS3): http://www.androidfilehost.com/?fid=22901594685178753

Hope that you can pass me a recovery fake flash zip so that I can include it easily in my custom kernels. Thanks! :)
[Android Software Development] Phil3759:
What I can do enough quickly is build you a recovery binary and send it to you

Playing with xiaolu script is a bit hard for me now as I have very little time for that. I do not build anything manually, as all is automated via scripts. So, starting things manually is a pain. Anyway, you won't need the zimage since all you want is the recovery ramdisk

Please, can you tell me these info:

UMS lun file: did you edit it from cm-10.1 device tree?

BOARD_UMS_LUNFILE

Brightness sys file for your kernel?

#define BRIGHTNESS_SYS_FILE "/sys/class/leds/lcd-backlight/brightness"

Battery level sys file?

#define BATTERY_LEVEL_PATH "/sys/class/power_supply/battery/capacity"

After that, I can build something right
[Android Software Development] Ryuinferno:
I did not edit anything in the device tree. Everything is correct except for brightness

/sys/class/backlight/panel/brightness

:)
[Android Software Development] prasath kp:
Can you make this for device htc desire sv or make this compatible for the device plzz
[Android Software Development] tiho5:
I am sorry if this was answered before, but I couldn't find it after I searched:

When a NAND is created I always get 2 or even 3 *.tar files. It is like having volumes, but always the first *.tar file is 0 mb size and the rest follow. For instance system is backed up in 3 *.tar files:

1. system.ext4.tar = 0 mb size

2. system.ext4.tar.a = 953 mb size

3. system.ext4.tar.b = 145 mb size

This goes for data, system, android_secure and cache.

I want it to create only a single *.tar for all of these. How to set this up? I couldn't find a setting in the options.:confused:

I am on HTC One X and Philz Recovery 6.0.3.2

By the way it is fantastic. Thank you for this great work!
[Android Software Development] Ryuinferno:
That's the format CWM is using now... it's normal...you can open those files as normal .tar files...
[Android Software Development] tiho5:
I know that *.tar is used with CWM. I am ok with this and I can open them too :)

BUT:

I use Total Commander on my Windows PC and if the *.tar is a single file I can open it within the Total Commander without having to use external app.

I was using CWM recovery 5.8.4.0 till recently and all the *.tar files were single and I never found any problem if big single *.tar files were created, so I figure why have multiple ones when there is no problem with single files.

I hope there is an option or some way to set it to create single files. And if anybody knows is/how I can switch to single *.tar files, please share it
[Android Software Development] Ryuinferno:
That's a new feature of CWM6...CWM is generating .tar.a backups now...it's a lot faster when generating backups... there's no option to disable that...a workaround is to rename the .tar.a to .tar...
[Android Software Development] tiho5:
OK, Thank you!

This rename works for the *.tar.a but not for the *.tar.b file.

I didn't notice any speed improvement or may be it was too small, so I am off to recovery-clockwork-touch-5.8.4.0 :)

Thanks again, mate!
[Android Software Development] hachamacha:
I normally read the sources before doing an update but I confess: I didn't this time and it may have bit me. As it happens, and as you said somewhere not too long ago:

I'm still not sure what, but it is not missing anymore after my 5-minute old rebuild.. Good grief! Thanks. Nice changes too!
[Android Software Development] Phil3759:
If you still have that version around, I am interested to debug what happened, really:

flash that nand bizarre version and do the following:

adb shell
ls -l /sbin/tar
tar

and post here the output for each command

Probably an error on your side/sources, but still wondering what happened exactly so that recovery shows ok on backup operations
[Android Software Development] hachamacha:
I have the error version around and will post what you ask about it by tomorrow. I've got to head out now for real life. My ROM is selinux enabled and I didn't use the "use the busybox tar" flag either time. But we'll see what it shows.

Many thanks.
[Android Software Development] Phil3759:
let me know

really curious to debug it as it could hide a hidden bug not accounting for some exceptions...
[Android Software Development] Phil3759:
:good:

Added to OP
[Android Software Development] hachamacha:
Just so we know the current state of my "working version" which I picked out of the ./out tree, it is:

$ ls -al ./out/target/product/moto_msm8960/recovery/root/sbin/tar
lrwxrwxrwx 1 mstein mstein 8 Apr 26 15:17 ./out/target/product/moto_msm8960/recovery/root/sbin/tar -> recovery

Which is what I would expect. I half expect the bad version to show ./sbin/tar -> busybox.

There is an approximately 200K difference in recovery.img sizes , bad one being < than working one..
[Android Software Development] Phil3759:
Would be great if you look at bad one recovery image

Maybe fall back to busybox tar that cannot support -s option

Means busybox tar returns 0 where it should exit with an error code
[Android Software Development] hachamacha:
OK: Didn't take so long so here is the "bad" image output of what you asked for:

No big surprise about link to busybox. I hope the tar command showed what you wanted.
[Android Software Development] Phil3759:
A last one:

busybox tar -csvf test.tar /cache
echo $?
[Android Software Development] hachamacha:
~ # busybox tar -csvf test.tar /cache
busybox tar -csvf test.tar /cache
busybox: invalid option -- s

BusyBox v1.22.1 static (2014-04-06 21:23 +0200) multi-call binary.

Usage: tar -[cxtzjhmvO] [-X FILE] [-T FILE] [-f TARFILE] [-C DIR] [FILE]...

Create, extract, or list files from a tar file

Operation:
c Create
x Extract
t List
f Name of TARFILE ('-' for stdin/out)
C Change to DIR before operation
v Verbose
z (De)compress using gzip
j (De)compress using bzip2
O Extract to stdout
h Follow symlinks
m Don't restore mtime
exclude File to exclude
X File with names to exclude
T File with names to include

~ # echo $?
echo $?
1

OK, and here's one more that should be a success code:

~ # tar cvzf /cache/test.tar.gz *.sh
tar cvzf /cache/test.tar.gz *.sh
init.class_main.sh
init.qcom.class_core.sh
init.qcom.early_boot.sh
init.qcom.sh
init.qcom.syspart_fixup.sh
init.qcom.usb.sh
~ # echo $?
echo $?
0
~ # ls -al /cache/test.tar.gz
ls -al /cache/test.tar.gz

-rw-rw-rw- 1 root root 6452 Apr 26 22:53 /cache/test.tar.gz
~ #
[Android Software Development] Phil3759:
Return codes look fine

I have no clue why it failed the backup without returning an error!
[Android Software Development] hachamacha:
Yep, very strange, and of course, still doing it on that version.Let me know if you want other tests. I'll hang onto the mystery version but won't be able to do anything with it until tomorrow AM.
[Android Software Development] Phil3759:
Found it

https://github.com/PhilZ-cwm6/philz_touch_cwm6/blob/cm-11.0/nandroid.c#L206

Cwm seems to ignore return code from command line during nandroid!

Not sure if it is even possible using popen. Will have to look at it closer
[Android Software Development] Pons:
Just wondering what's up with extra.fstab. Glanced through the code, and I don't see it being called in device.mk like it says it should be. Plus your m7vzw fstab and CM's looks the same. I'll take a closer look at it later tonight, but I got to run.
[Android Software Development] Phil3759:
Look at hacked build/core repo on my git
[Android Software Development] sedric1:
I couldnt get this to work on sprint galaxy s5 - sm-g900P. everything looked ok in odin (success) but when rebooting into recovery it doesnt show any ofthe expected options
[Android Software Development] Pons:
A little more info would be helpful. Official or self compiled? Version? Recovery log?

Found it at Copy needed files without altering device tree.

So basically this doesn't work or get used unless the compiler uses https://github.com/PhilZ-cwm6/android_build I checked in $(TARGET_DEVICE_DIR)/rootdir/etc/ and there's no extra.fstab, just the recovery.fstab. If that's the case, I'll have to change my build process since I only use your system/vold, bootable/recovery, and device tree. I'm trying to keep the changes to a minimum, which is one reason I'm trying to get native exfat support added to the kernel.
[Android Software Development] Phil3759:
If you maintain 2 or 3 devices, you should just add the product_copy_files flag

Maintaining +150 devices is a no go if i have to edit as many device.mk and Boardconfig files. I try to automate most parts

I use BeyondCompare software on linux to quickly copy/modify remaining parts

Same for devices needing a special init.rc file
[Android Software Development] tetakpatak:
Dear [MENTION=4666971]Phil3759[/MENTION]

Just another little donation as sign of endless respect for your unique development project, wonderful!

I use PhilZ on all my devices.

I wish you great health and lot of joy as well, have a nice weekend :)

96C39702EF2877919
[Android Software Development] Phil3759:
:angel:

Big thanks for your generosity and attention
[Android Software Development] Phil3759:
I could trigger when using tar non compressed mode by editing this line:

https://github.com/PhilZ-cwm6/philz_touch_cwm6/blob/cm-11.0/nandroid.c#L242

sprintf(tmp, "cd $(dirname %s) ; touch %s.tar ; (tar -csv --exclude=data/data/com.google.android.music/files/* %s $(basename %s) | split -a 1 -b 1000000000 /proc/self/fd/0 %s.tar.) 2> /proc/self/fd/1 ; exit $?", backup_path, backup_file_image, strcmp(backup_path, "/data") == 0 && is_data_media() ? "--exclude 'media'" : "", backup_path, backup_file_image);

by replacing tar with busybox tar

busybox tar -csv

As I suspected, we cannot rely on pclose return value for that

Nice bug affecting CWM sources

You triggered it by your incomplete sources merge probably, but, in theory, it could cause a bad backup to show as good under some circumstances
[Android Software Development] Phil3759:
Actually, seems a bit more complicated

If you try this in adb shell

(busybox tar -csv cache | split -a 1 -b 1000000000 /proc/self/fd/0 /test.tar.) 2> /proc/self/fd/1 ; echo $?

we get output 0

Now, if we try:

busybox tar -csv cache -f /test.tar echo $?

the out put is 1, which is what we need

So, the problem is not pclose return code but the piping code its self

Have to think at a fix

Open to all your suggestions
[Android Software Development] hachamacha:
Been awhile for me, but I recall that popen just opens a pipe, kicks off a subprocess but doesn't wait for that subprocess' command to finish, so maybe you're just getting back the 'open pipe'(popen() or pclose() result, nothing from whatever actually happened. I think that error-checking is real loose on the 'kicked-off' "command" parm passed to popen. I feel like I've once figured out a better way, but it's lost for the moment in my cluttered head.. I also think it was "non-standard", like a tar-like API. (but it wasn't libtar. I also need to look at libtar and see how it works anyway).
[Android Software Development] Phil3759:
no

nandroid popen code waits for the pipe to end before returning

by default, shell/bash will always report exit code from last element in the pipe.

You can reproduce the issue in adb shell or your bash/shell linux box:

(tar -cv garbadge_file | split -a 1 -b 1000000000 /proc/self/fd/0 test.tar.); echo $?

you will get 0 from echo command despite tar failed on non found file

forcing the 'set -o pipefail' will set $? to error if any command in the pipe element fails:

set -o pipefail;
(tar -cv garbadge_file | split -a 1 -b 1000000000 /proc/self/fd/0 test.tar.); echo $?

Now, you get exit code 1

I committed a fix:

https://github.com/PhilZ-cwm6/philz_touch_cwm6/commit/871a5a60dc26e7838b61641bccd5e747e28c2f37

Thank you for reporting the issue. Sometimes, user unexpected actions can unhide subtle bugs

I also committed this fix to stock CWM gerrit review
[Android Software Development] hachamacha:
"set -o pipefail" seems a good way to go. Just messing around with that in a VM. Thanks for the fix.
[Android Software Development] Phil3759:
We sadly have no

$PIPESTATUS

implementation in recovery shell:

edit: good reading on this:

http://unix.stackexchange.com/questions/14270/get-exit-status-of-process-thats-piped-to-another
[Android Software Development] Phil3759:
6.29.9 (27.04.2014)

This is in my opinion an important bug fix to nandroid backup reliability

It is affecting all CWM recoveries since first versions :D

Basically, if the tar operation fails, the backup could be still reported to be done correctly.

Example: corrupted partition backed up. Backup process shows good, but we end up with a truncated small backup we cannot restore later
[Android Software Development] hachamacha:
It works on this one in /system/xbin: (about 431K)

bash --version
GNU bash, version 4.1.0(1)-release (arm-android-eabi)
Copyright (C) 2011 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

example:

# set -o pipefail
set -o pipefail
#echo $PIPESTATUS
echo $PIPESTATUS
0
#ls init.rc | grep i
ls init.rc | grep i
init.rc
#echo $PIPESTATUS
echo $PIPESTATUS
0
#

And that one is a part of my booted ROM (eclipse build 6 I think of v4.3 os), not a soft link, just a binary.
[Android Software Development] Phil3759:
we have no bash in recovery busybox and 430kb is out of question

'set -o pipefail' is enough

By the way, you do not need to set pipefail if you have a PIPESTATUS implementation
[Android Software Development] hachamacha:
[MENTION=4666971]Phil3759[/MENTION]:

My mistake: I had made a guess that it was there based on the contents of ./out.. in the CM11 tree that had gotten built (or prebuilt-moved) during the "make -j* recoveryimage" process. It did seem somewhat huge ;)

Thanks for the info.
[Android Software Development] Phil3759:
there is a bash in cm sources:

https://github.com/CyanogenMod/android_external_bash

It is not build statically though, even if it should be possible probably. However, unless bash gets implemented in busybox, I think it is a no go
[Android Software Development] tetakpatak:
LOL, Phil, we can't compile and flash as fast as your updates are getting released :D

tetakpatalked from Nexus 7 flo
[Android Software Development] Phil3759:
that's a crazy bug, two years old, since cm-9.1

spotted by case after digging into [MENTION=2658922]hachamacha[/MENTION] non sense bug

He sure broke it during compiling, but that revealed the underlying bug
[Android Software Development] titanic_fanatic:
Hey [MENTION=4666971]Phil3759[/MENTION], I was having a frustration while using the advanced restore feature. I would select the partitions to restore then it would ask me for the backup to restore from then it would ask to select a file to restore even though partitions have been selected previously. I fixed it with the following commits in my github and thought you might be interested in brining it into your mainstream repo:

https://github.com/titanic-fanatic/philz_touch_cwm6/commit/d417383a2de7ddbb8b29937c71b19e07803b2647

and

https://github.com/titanic-fanatic/philz_touch_cwm6/commit/3563a71fd330d8661a6ed8dc753c29b5d55ff0a3

Also, since I'm already posting here, I have uploaded the newest version to my androidfilehost for the celoxhd (6.29.9) which includes my fix for the custom restore.

http://www.androidfilehost.com/?w=files&flid=12461
[Android Software Development] ali.filth:
Sorry out off topic,

is it possible you will release phiz-updater.apk on next time? :D

Send from my Pager using xda-developers app
[Android Software Development] Petrit Ziu:
Will it work on Samsung Galaxy S2 AT&T i777? Thnx
[Android Software Development] Pons:
I don't see official/unofficial support for PhilZ for your device, but there is official CM support, so it shouldn't be too hard for you to do it yourself. Read the 2nd post for details.
[Android Software Development] Bhargav97:
That is not a bug. It is just a preview of all the files you have in your backup. It will restore only your selected partitions even if you click on either of the available files there.

[MENTION=4666971]Phil3759[/MENTION],

I think this thing (preview feature) has confused many people out there. You should give any option like 'continue ---->' at the end of the list of partitions preview.
[Android Software Development] Phil3759:
LoL

Exactly. Seems I am the only one appreciating that feature

Using custom backups, I want to know sometimes which backup set contains let's say a data partition backup

While restoring, this feature lets me go in backup folder and see if it contains what I need

I will think at something to make it more friendly, but for now, I have to fix libtar

Seems restoring /data is failing on some devices

I will disable the libtar for now and advise all devs that updated non officially to compile with the BBTAR flag
[Android Software Development] edzamber:
Thanks Phil for this future feature and for Data restore issue (i'm on i9505 and have this issue with 6.29.9 znd 6.29.7)

Posté via Pyrana v38 by Alan-B

http://xdaforums.com/showthread.php?p=50627772
[Android Software Development] titanic_fanatic:
It just felt strange to me because I would always use aroma installer to do that sort of browsing around. Once I'm restoring, I already know what needs restoring, and I use Online Nandroid Backup which allows me to give each backup a custom name so I always know what backup contains what. Just a personal preference ;)
[Android Software Development] Phil3759:
6.30.1

Sorry, seems something wrong with new libtar affecting many ROMs

I am digging into it