• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Help Logcat of bootloop

SavageRobot

Android Expert
Jan 23, 2012
877
483
Wales
OK, so I've been trying to flash a new ROM (current one is full of crap and buggy and this new one looks good...for Lollipop anyway). My problem is that when I flash it, aroma goes well looks OK, then the last line says something like "not rooted", then all I can do is restart and goes into a bootloop.

My Question is can I produce a logcat running through the installation and the boot loop to see if the dev (or anyone) can tell me what the problem is, or does it only run when android UI is running? Nobody on the forum is having this problem and they just keep suggesting I am flashing it wrong....but I 100% am not. Also I found this [Tutorial] How to Logcat but unfortunately I'm not as good with command line as I would like to be. If the logcat from this state can be done could someone talk me through it please?
 
The issue with capturing a logcat during a bootloop is that the boot process has to be far enough along to have started-up the adb daemon (/sbin/adbd) so your adb client on your PC can talk to it.

The only wait to really know is to have your device attached to your PC while it's booting and do an "adb logcat" or "adb wait-for-device" to see if it's getting that far.

Since I'm guessing you've got a custom recovery installed (I'm assuming) and you are comfortable/willing to monkey around with some stuff, there's a couple of things you could try to get a logcat or even a kernel log recorded for later review.
 
Upvote 0
Okay, lemme find my old posts...a member @gapi also had problems trying to install a new ROM on his Galaxy Nexus and I suggested hijacking the boot animation process to have it instead record the logcat and/or kernel log to his SD card for later review.

Are you seeing the boot animation sequence? If not, then this might not be a viable thing to try...
 
Upvote 0
No, it doesn't get as far as the boot animation. Normal booting is Sony on black screen, then goes to wavy lines while it boots, then into UI. The bootloop went Sony on black, then black screen, repeat.
The problem also is (I assume because for some reason one of the lines is "root denied" or whatever it says), I lose recovery too so it doesn't vibrate and I can't get to recovery from that. So I have to put it into flash mode, flash a rootable Kit-Kat, root, install SuperSU, flash recovery then I can get back to restoring the nandroid...ball ache and a half ha.
 
  • Like
Reactions: scary alien
Upvote 0
@EarlyMon I did think about that and I checked the md5 (never done it before so that took some hunting ha) and it is correct as long as I read it right. The recovery is fine, I flash that from PC run.bat or whatever it is. I just dont get it after the ROM. I think when I flash the ROM a new recovery flashes with it anyway. This is the ROM I'm trying to flash
[5.0][Z1 series][new][LB/UB][Advanced]RockZ1l_v3.0 Deodex/most advanced[30/06/15] the problem I think is right at the end of the install. Found the fault now, last line in aroma is
Rooting...
set_perm: some changes failed
the only option at this point is to reboot into boot loop.
@scary alien Can I safe-mode boot from aroma installer/boot loop? I have no idea, I did think about trying another download in case it was a bad download but it's almost 2GB and the internet here isn't the best. So I checked the md5 thinking that would tell me if it is a bad download or not wouldn't it?
@funkylogik I have a locked bootloader. In the service menu it says something like "Boot loader unlock: No" and can't be unlocked.
 
Upvote 0
If the md5 checksum matches, the download is good.

I'm downloading the rom because I want to see what the installer is really doing, especially because a) you mentioned that you think that it's installing recovery as well, and b) the rom prerequisites say that you have to be running stock Lollipop before flashing.

If I read you right, you're starting from KitKat and your phone doesn't handle recovery or installs like unlocked phones.

It's not just you - it's telling me that it's going to take 3 hours for the download. Nuts.

What recovery are you running?

Does it have logs available?
 
Upvote 0
Does it have logs available?

I.e., grab (adb pull) and check the /cache/recovery/last_log or /cache/recovery/last_log.1 file to see what might have transpired (meh! I just realized this might be futile since you can't finish booting...if you can flash a custom recovery by itself after the boot hang and then check the log files, that might help, but I don't know if you can do that, SavageRobot).

I tried the download, too, EM, and it's telling me two hours but hasn't made any progress at all in 10 minutes...ugh!
 
Upvote 0
My download just finished...poking around now, but I've never seen the aroma pieces before (heard of it, but never used or researched it before).

@SavageRobot, I noticed that there were two different versions available:

Xperia Z1 devices

Xperia Z1 compact​

I downloaded the first one--could it be that you have the "other" one and that's what's leading to these issues? (no idea, just spitballing here).
 
Upvote 0
Aroma is pretty cool, I've been using it since 2012.

Anyway, the installer begins -

Code:
format("ext4", "EMMC", "/dev/block/mmcblk0p23", "0", "/system");
format("ext4", "EMMC", "/dev/block/mmcblk0p24", "0", "/cache");
mount("ext4", "EMMC", "/dev/block/mmcblk0p25", "/data");
  delete_recursive("/data/dalvik-cache");
  delete_recursive("/data/resource-cache");

So I presume that the aroma prompt to wipe things refers to other partitions - and this thing is the kitchen sink and will install recovery and even a bootloader.

What confuses the hell out of me is line 705 of the updater-script:

Code:
set_perm_recursive(0, 0, 0777, 0755, "/system/bin/.ext");

This installer is not for the faint-hearted but I don't see where that is being created in the first place.

And unless it's something about firmware, I'm not sure where the pre-existing Lollipop requirement comes in, as system and boot are being replaced.

I'm back to suspecting that it's firmware, needing Lollipop first (this I'm less sure of for an installer fail) - or - the recovery installed and running this is just buggy.
 
Upvote 0
Sorry, went out last night :D Thanks for all the help
I'm downloading the rom because I want to see what the installer is really doing, especially because a) you mentioned that you think that it's installing recovery as well, and b) the rom prerequisites say that you have to be running stock Lollipop before flashing.

If I read you right, you're starting from KitKat and your phone doesn't handle recovery or installs like unlocked phones.

It's not just you - it's telling me that it's going to take 3 hours for the download. Nuts.

What recovery are you running?

Does it have logs available?
Did you find the recovery in the installer?
I think the needing to have stock lollipop was for an old version, since the last few updates can flash from any ROM as it does the necessary cleaning up I think and it was at first like a patch I think.
No I'm currently running an older version of the attached ROM but when it gets stuck in bootloop I have to flash Kit-Kat as there isn't a root exploit for Lollipop on Z1.
I'm running [NUT]'s lockeddualrecovery for Z1 from here http://nut.xperia-files.com/


I.e., grab (adb pull) and check the /cache/recovery/last_log or /cache/recovery/last_log.1 file to see what might have transpired (meh! I just realized this might be futile since you can't finish booting...if you can flash a custom recovery by itself after the boot hang and then check the log files, that might help, but I don't know if you can do that, SavageRobot).

I don't know how to do that, is it something to do in cmd on pc or another app? I do have Catlog on pnone, but like I say, I unfortunately don't know what I'm doing or looking at.

I downloaded the first one--could it be that you have the "other" one and that's what's leading to these issues? (no idea, just spitballing here).
No I downloaded the Z1 version I'm sure, but never hurts to check.

What confuses the hell out of me is line 705 of the updater-script:

Code:
set_perm_recursive(0, 0, 0777, 0755, "/system/bin/.ext");

This installer is not for the faint-hearted but I don't see where that is being created in the first place.

And unless it's something about firmware, I'm not sure where the pre-existing Lollipop requirement comes in, as system and boot are being replaced.

I'm back to suspecting that it's firmware, needing Lollipop first (this I'm less sure of for an installer fail) - or - the recovery installed and running this is just buggy.
So what is that code saying?

I doubt you would find the cause in the installer as I say, it is only me that is having this problem, which is weird.
I actually think I might be on an older version of the recovery, one that I downloaded after rooting months ago. the one I can see on my computer is V2.8.12 I see that V2.8.20 is out now...but like I say, I think the ROM installs a recovery with it, is there a way to check what version you are running? Could that be the problem? I've never had a problem with this recovery before, and the problem seems to occur after flashing everything, so my current recovery has done what it needs to, so I guess that wouldn't be it.
 
  • Like
Reactions: scary alien
Upvote 0
Ah, @SavageRobot...that log file actually does help!

edit: LOL, in reviewing this thread, I see you actually mentioned this in post #9 above :p.

You're getting installation errors where the script is trying to install the su binary:

...
Extract: /system/etc/firmware/wlan/prima/WCNSS_qcom_cfg.ini
Extract: /system/etc/firmware/wlan/prima/WCNSS_qcom_wlan_nv.bin
>>> Flashing kernel...c6903
package_extract_file: no RockZ1L/kernel/C6903/kernel.elf in package
Creating symbolic links...

>>> Setting permissions...
Rooting...
set_perm: chown of /system/xbin/su to 0 0 failed: No such file or directory
set_perm: chmod of /system/xbin/su to 6755 failed: No such file or directory
script aborted: set_perm: some changes failed
set_perm: some changes failed


Installer Error (Status 7)

End at : Sun Jul 5 05:18:27 2015

In looking at the updater-script file and the above log that you provided, it's not doing an extract of the /system/xbin folder from your installation RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip file, so the above "Rooting..." section is failing because the /system/xbin folder and the su binary that it's trying to set permissions on, doesn't exist.

Is the a switch or interaction that you provide to Aroma during the installation process about making sure that you want to root?
 
Last edited:
Upvote 0
Actually, there is a package_extract_dir("system", "/system"); done at line #25 of the updater-script file that should extract all of the subfolders, include the xbin folder, so I'm still not sure what's going on...

edit: okay this is weird....ALL of the /system subfolders EXCEPT for the xbin subfolder were logged (in the log file you provided) as extracted from the above package_extract_dir command. So the question remains: why didn't it extract the xbin folder that contains, importantly, the sub binary???
 
Upvote 0
Okay, sorry for the triple post here, but I wanted to keep my thoughts separate...

Notice in the log file that you provided (RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip.log[1].txt log) that you can see that the extract of /system/vendor/lib stops at line #4605 with the file lib-imsdpl.so.

In the RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip file that I downloaded, there are a LOT MORE files in that folder.

Can you confirm that RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip is the file that you are trying to install?

Also, when you view that .zip file on your PC, can you confirm that the system folder inside that .zip file contains an xbin folder?

And, is the system/vendor/lib folder populated with many more files than what the above log file records at around line #4605?
 
  • Like
Reactions: EarlyMon
Upvote 0
I downloaded what I thought was the "compact" version of the ROM from your starting link above @SavageRobot and got the exact same file as before (weird).

Then, I just now went back to reconfirm the MD5s with my download and I'm seeing this:

For Xperia Z1 devices Click here The Links are Deleted Try v2.1 until New update come (wait for 3 days
tongue.gif
)

For Xperia Z1 compact Click here The Links are Deleted Try v2.1 until New update come (wait for 3 days
tongue.gif
)​

on the download link page (http://forum.xda-developers.com/showpost.php?p=60287727&postcount=4).

Interesting...
 
  • Like
Reactions: GameTheory
Upvote 0
Thanks for looking so deeply into this .
In looking at the updater-script file and the above log that you provided, it's not doing an extract of the /system/xbin folder from your installation RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip file, so the above "Rooting..." section is failing because the /system/xbin folder and the su binary that it's trying to set permissions on, doesn't exist.

Is the a switch or interaction that you provide to Aroma during the installation process about making sure that you want to root?

No, nothing in installation to select root or not I don't think.

Notice in the log file that you provided (RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip.log[1].txt log) that you can see that the extract of /system/vendor/lib stops at line #4605 with the file lib-imsdpl.so.

In the RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip file that I downloaded, there are a LOT MORE files in that folder.

Can you confirm that RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip is the file that you are trying to install?

Also, when you view that .zip file on your PC, can you confirm that the system folder inside that .zip file contains an xbin folder?

And, is the system/vendor/lib folder populated with many more files than what the above log file records at around line #4605?
Yes it's definitely RockZ1L_lolly_v3.0_by-venkat-kamesh_01072015.zip I am trying to install. Yes there is an xbin file, containing antradio_app, busybox, chattr.pie, dexdump, su & supolicy.
In the lib folder there are 431 items, including 11 more folders, each of which have about another 3-5 files in.
I noticed he put something in the thread, although I can't see anybody else having any real problems, looks like some people are having some issues and I'm just missing them, Venkat posted yesterday...

Rom Update
I found the script was not completely perfect
from version 2.2 so i am going to delete those links

i dont want you people to get worried of

i read most of all your logs ( which ends with unknown error )

so in 2 days my vacation will be completed and i will provide once complete rom

there are almost the unnecessary files too i will delete them
tongue.gif


sorry for this and the rom will be changed to v3.0 as now in present update

I'm not sure what he is talking about there. But I guess I will just wait for the next update and see if that one works for me. I did post the log on there too but I don't know if it is my logs he's referring to or someone elses.
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones