Thursday, 2020-04-16

T42<Rodrigosolari> this my  journalctl -alb --no-pager00:34
T42<birdzhang> reboot and grab from begining01:42
T42<Rodrigosolari> @birdzhang [reboot and grab from begining], Logcat ?01:45
T42<birdzhang> dmesg, logcat and journalctl01:46
dkterhmm, after re-initializing and syncing with 15.1 build/tools/ is gone01:50
T42<Rodrigosolari> do you read guide?01:56
T42<Rodrigosolari> show me hadk.env01:56
dkterwhere's that02:03
T42<Rodrigosolari> cat ~/hadk.env02:04
dkteri don't have that...02:08
dkteroh it's .hadk.env02:08
T42<Rodrigosolari> Yes .hadk02:08
T42<Rodrigosolari> what is you repo02:10
r0kk3rzdouble check it all synced properly02:11
dkterhow do i do that r0kk3rz?02:11
dkteri ran repo sync --force-sync --fetch-submodules02:12
r0kk3rzrun it again02:12
dkteroh hey, it worked i think02:17
r0kk3rzits a big sync and sometimes errors can get hidden in the massive output02:21
dkteryeah makes sense02:21
dkterhuh, not sure what to make of this error message
dkterwow it seems like literally nobody has ever gotten this error before03:28
r0kk3rzits not one i remember seeing03:29
r0kk3rzbut its pretty early for most folk in this channel03:29
T42<birdzhang> is java -version working?03:29
dkterError: dl failure on line 89303:30
dkterError: failed /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/amd64/server/, because cannot open share03:30
dkterd object file: No such file or directory03:30
T42<Rodrigosolari> do you try "sudo apt update" and "sudo apt upgrade" to update system chroot03:32
dkterapt never really worked for me on habuild sdk03:33
dkteri'm not super familiar with chroot environments so i'm not sure if this is normal03:33
dkterbut whenever i run an apt command there's no output at all03:34
T42<birdzhang> so fix java first03:35
T42<Rodrigosolari> @dkter [but whenever i run an apt command there's no o …], Remove ubuntu Chapoy03:38
T42<Rodrigosolari> Chrroot03:38
T42<Rodrigosolari> And install ubuntu Christian03:39
dkterwhat's that03:39
T42<Rodrigosolari> Ubuntu chroot03:39
dkteri'm a little lost03:39
dktershould i try to build from outside the chroot?03:40
T42<birdzhang> if you use ubuntu, of course you can03:44
dkteri'm using ubuntu on WSL 203:45
dkterokay i think it's working03:55
dkterweird how zypper works in platformsdk but apt doesn't work in the ubuntu chroot04:00
r0kk3rzthe ubuchroot is a bit old now04:04
T42<Rodrigosolari> @dkter [weird how zypper works in platformsdk but apt …], Zypper is for merskd for ubuchroot is sudó apt install or sudó apt-get04:06
dkteryeah ik but apt wasn't working04:07
T42<Rodrigosolari> @dkter [yeah ik but apt wasn't working], maybe because you use wls, use pure linux04:11
dkterit's wsl 2 so it pretty much is pure linux04:13
dkteri'm running without the chroot and it's working so far04:13
T42<Rodrigosolari> @dkter [it's wsl 2 so it pretty much is pure linux], Not wsl 2 is an virtual machine...04:15
T42<Rodrigosolari> It is a very, very basic chroot, you will have problems installing apps in the chroot04:18
dkterthis is weird, because prebuilts/misc/linux-x86/bison/bison does exist04:38
dkteroh nvm i think i fixed it. i didn't have i386 support installed04:45
T42<Rodrigosolari> "ls -l ~/hadk/prebuilts/misc/linux-x86/bison"04:45
T42<Rodrigosolari> ok04:45
T42<Rodrigosolari> dkter: you are going to have enough problems, since you will lack clan, java, etc etc libraries, do not use WLS2, in any case install in a virtual machine linux server and use ssh for connections, I recommend that or you install linux on your PC04:47
dkterthat would take longer than just installing the stuff i'm missing04:49
dkter(which apparently includes gcc, unzip and libxml2-utils)04:50
T42<Rodrigosolari> false, because it will take you more time and problems looking for solutions to put WLS2 to an operational point, and that you can just normally, you will get constant errors in construction issues, and updating, in my opinion, you would delay the half the time working on linux than on WSL04:51
T42<Rodrigosolari> Well, as you see, they are your things, mine is just opinion, since I have always worked in Linux!04:53
T42<Rodrigosolari> :)04:53
dkterit's building right now ¯\_(ツ)_/¯04:53
dkterbuild completed successfully!!05:26
T42<Rodrigosolari> after apply ld this my logcat
T42<Rodrigosolari>  --> dmesg06:12
T42<Rodrigosolari> --> journal06:12
T42<elros34> @Rodrigosolari start to read logs you are posting. First line in your logcat suggest that you didn't apply ld.config changes correctly. dmesg and journal are still pretty useless. Try: echo "something" > /dev/kmsg and then check whether message is visible in dmesg08:01
*** piggz_ is now known as piggz08:02
T42<Verevka86> (Photo, 720x1280)
T42<Verevka86> It compiled at last08:36
deathmistmal: I also noticed that the manual /system and /vendor mount unit stuff that is needed for >=15.1 bases is missing from FAQ too, where should I put that exactly?09:12
deathmist@Rodrigosolari what does the command `mount` output for you from telnet 2323 after a bit of waiting? you may also be missing the stuff I was referring to just above09:16
T42<edp_17> @Verevka86 : Have you got this error and if you got how did you solve? :
T42<elros34> deathmist: if you mean custom vendor.mount then according to systemd documentation this is not needed09:20
deathmistoh? I'll have to test that right now then, /system should definitely be needed though right?09:21
T42<Verevka86> @edp_17 [@Verevka86 : Have you got this error and if yo …], No09:22
T42<elros34> deathmist: no, system_root and system should also be created by droid-hal without issues provided you dont skip creation of them in droid-hal spec09:25
deathmist@elros34 they aren't in fstab for me at all (, that's the issue as they don't get created in the first place -> I had to create the units myself. maybe this only affects some devices too09:27
T42<elros34> if they aren't in fstab then sure you need to create custom mount unit or add it to fstab. For sure not all devices have such issue. I was refering to incorrect advice to add "makefstab_skip_entires /"09:30
deathmist this is how my device deals with those "missing" fstab entries on Android-side: they're just defined on the DTS09:31
T42<Nebrassy> deathmist: hybris-boot doesn't include dtb09:44
deathmist@Nebrassy it (or the kernel inside the image usually anyway) has to on older non-A/B devices, otherwise nothing would boot.09:48
maldeathmist: why were the manual mount services needed?10:06
deathmistmal: /system and /vendor aren't in my device fstab since Oreo 8.1 (15.1 base onwards) -> dhd build doesn't create mount units for them10:07
deathmistsome other devices may need to create these too10:08
maldeathmist: are those mounts listed somewhere in the android side repos, just thinking if we could improve the mount detection10:10
deathmistmal: pretty sure they get mounted by the android early init from DTS @ /firmware/android/fstab/ but I can try to look deeper10:11
maldeathmist: maybe grep the sources for the device node or something like that10:11
Nebrassy[m]Deathmist: maybe, but on my android 9 a/b it skips it completely10:50
Nebrassy[m]Deathmist:  you can check with abootimg, split-appended-dtb and dtc10:51
Nebrassy[m]that's if your dtb is appended to kernel of course, it might be separate in the boot image or on a separate partition10:52
deathmistI know on my boot images the kernel has appended DTB lol, I've done mainlining for this phone and know how the things go together10:52
Nebrassy[m]I mean on hybris-boot.img10:52
Nebrassy[m]also I mean you can see the fstab in the dtb this way10:53
deathmistwhat about it? it's just an android kernel (which my DTB is appended to) with a custom initramfs10:53
deathmistsure, but my device has like 20 DTBs in one image lol10:53
Nebrassy[m]aren't you trying to see the early init fstab?10:54
Nebrassy[m]yeah grep those for your codename10:54
deathmistI don't need to find it as I know even the source dtsi file they come from, the dhd build script improvements that would create mounts based on those would have to though, and DTS stuff in general is just a huge mess in downstream so I don't know if there would be any reliable way to get the correct file10:56
deathmist`find "$ANDROID_ROOT"/out/target/product/$DEVICE/obj/KERNEL_OBJ/arch/ -name "*.dtb"` is a start I guess10:57
Nebrassy[m]Ah, yeah now I got what you mean10:57
Nebrassy[m]this is the case for me11:15
Nebrassy[m][nebrassy@nebrassy-pc New Folder]$ ../split-appended*/split-app* zImage11:15
Nebrassy[m]ERROR: Appended Device Tree Blob not found!11:15
T42<edp_17> I am getting this error:
T42<edp_17> Should I create that folder (etc/init) in there manually?12:01
deathmist@edp_17 assuming it's an Android <7 base:
maldeathmist: wondering what base that is, hybris_extras.rc should not be present in older bases and therefore the copying should not happen12:58
deathmistmal: looks to cause it, should probably be wrapped around a $(ANDROID_VERSION_MAJOR) -ge 7 check13:41
maldeathmist: so this
deathmistyep, that should fix it :p13:46
T42<edp_17> @deathmist: Yes, it is cm12.1 base (Android 5.1).14:28
deathmist@edp_17 can you implement locally on your tree and `rm "$ANDROID_ROOT/out/target/product/$DEVICE/system/etc/init/hybris_extras.rc"` before doing `mka hybris-boot` and trying build_packages again?14:31
T42<edp_17> @deathmist: It worked, thanks. I needed to add some straggler files too but the process continued. Now it failed again but I think this is the point where I need to compile glibc and busybox how @elros34 advised.15:00
deathmistmal: ^ there is confirmation that should be merged :p15:01
T42<elros34> @edp_17 not sure what failed for you but glibc cause issue ONLY on device15:02
T42<edp_17> I got this when tried to build packages:
T42<edp_17> I have removed the glibc.ini from sparse/usr/share/ssu/features.d15:10
T42<elros34> this has nothing to glibc. glibc patch is needed because of too old kernel on your device.15:12
T42<elros34> use: "sb2 -t $VENDOR-$DEVICE-$PORT_ARCH -m sdk-install -R" to get into target then zypper se -s droid-hal15:14
T42<elros34> so now figure out why it can't find droid-hal in your local repo: ssu lr15:17
T42<elros34> so do you have droid-hal rpms in /home/s2v3/mer/android/droid/droid-local-repo/i9100/droid-hal-i9100/?15:19
T42<edp_17> Yes.15:20
T42<edp_17> I guess need to install it manually.15:21
T42<elros34> try zypper ref and search for droid-hal or other packages which you have in local repo again. I don't understand whats wrong your sdk15:22
deathmist@edp_17 is your dhd submodule up-to-date on master branch? not sure if it would cause this but it needs to be if you're building for SFOS 3.3.x15:23
T42<edp_17> @deathmist: yes, I created a new environment for this and refreshed all sub-modules to master.15:24
T42<edp_17> @elros34 : I did zypper ref but didn't help :
T42<elros34> how about other packages or it can't find only droid-hal15:26
deathmistmal: also I've now made a PR about ld.config patching for 16.0 ->
T42<elros34> @edp_17 ? Do you also have 3.3.0 sdk?15:31
T42<edp_17> if I do a 'zypper se -s droid' it returns with lots of packages.15:51
T42<edp_17> 3.3.0? I did 'ssu re'. Might it be 'ssu re'?15:53
T42<elros34> I was asking whether you have 3.3.0.x sdk (not target). About packages check whether any of rpm you have in local repo can be found15:54
T42<edp_17> I have updated tooling, target and sdk. I have only two folders in local repo : community-adaptation and droid-hal-i9100, and there are rpms in them.16:06
T42<elros34> so confirm that "ssu re" returns 3.3.0.x in sdk.In target do zypper se -s community-adaptation.16:12
T42<edp_17> ssu re returns: Device release is currently:
T42<edp_17> 'zypper se -s community-adaptation' returns:
T42<elros34> so there is progress, soemthing wrong is in droid-hal rpm so it's not found. Check your spec file, maybe run "createrepo_c /path/to/local/repo" with some verbose options16:16
T42<edp_17> Should I run this in Platform?16:18
T42<edp_17> In Platform I ran 'createrepo_c --verbose droid-local-repo/' :
T42<elros34> shoudn't it be droid-local-repo/$DEVICE?16:27
T42<edp_17> Yes, you are right. On the original S2 environment ( those folders are in droid-local-repo/i9100.16:38
T42<edp_17> Only the repodata folder is in the same level as i9100.16:39
T42<edp_17> No I was wrong, the droid-local-repo has the same structure in both environments.16:49
T42<edp_17> S2 ( $ANDROID_ROOT/droid-local-repo/i9100/subfolders (including the repodata)16:50
T42<elros34> I only mean that you shoudl run createrepo_c droid-local-repo/$DEVICE16:50
T42<edp_17> S2 ( $ANDROID_ROOT/droid-local-repo/i9100/subfolders (including the repodata)  + this one has an additional repodata folder on the same level as i9100 foder.16:51
T42<edp_17> Oh, I see. I do it now.16:51
T42<edp_17> here it is:
T42<Rodrigosolari> deathmist: it seems that normal is mounting vendoy and system, this my log
deathmist@Rodrigosolari check for instructions about the ld.config.28.txt patch, you've seemingly done it incorrectly17:51
deathmistwhen you've done it correctly `file "$ANDROID_ROOT/hybris/droid-configs/sparse/lib/systemd/system/"` should give you back `symbolic link to ../system-etc-ld.config.28.txt.mount`, anything else is wrong17:57
deathmistmal: uh, droid-config failed to obsolete usb-moded-configs even though it also provides it? this is during droid-hal-version build where it installs the droid config packages: how can that even happen when I have these lines in the spec:
T42<Rodrigosolari> deathmist, after add you ld, my logcat not foun19:31
T42<Rodrigosolari> found*19:31
T42<Rodrigosolari> deathmist: this my log of mount19:31
T42<Kalubeee> Are you just running `logcat`? It's not in your path it's in `/usr/libexec/droid-hybris/system/bin/logcat` I think, path is similar to that19:32
T42<Rodrigosolari> @caleb my logcat is symblink to /usr/libexec/droid-hybris/system/bin/logcat19:36
T42<kalube> ok, so what's the problem?19:37
T42<kalube> Run `mount` again and make sure there's a line containing `ld.config.28.txt`19:38
deathmist@Rodrigosolari if you did any modifications on your device and reflashed a new zip those modifications will not be there anymore. add the changes in your droid-config sparse files if you care to have them show up in new zips19:40
T42<Rodrigosolari> mount log
T42<Rodrigosolari> line /dev/mmcblk0p87 on /system/etc/ld.config.28.txt type ext4 (ro,noatime,data=ordered)19:41
deathmist@Rodrigosolari does `systemctl status droid-hal-init` show status as running?19:42
T42<Rodrigosolari> sh-3.2# systemctl status droid-hal-init19:43
T42<Rodrigosolari> ● droid-hal-init.service - droid-hal-init19:43
T42<Rodrigosolari>    Loaded: loaded (/lib/systemd/system/droid-hal-init.service; disabled; vendor preset: enabled)19:43
T42<Rodrigosolari>    Active: inactive (dead)19:43
T42<kalube> grab the whole output of `dmesg` and `journalctl -b`19:44
T42<Rodrigosolari> remove the ld.config.28.txt on all its paths, and if droid-hal-init works, but adding those files doesn't start droid-hal-init,19:45
T42<Rodrigosolari>  --> dmesg19:47
T42<Rodrigosolari> --> journal19:47
T42<kalube> That's only one screenful.... Both those outputs should be >10,000 lines long. you need to run `dmesg > dmesg.log` and `journalctl -b > journal.log` and then copy the files. If you have SSH you can use the `scp` command or you can reboot into recovery and copy them19:49
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> @kalube20:13
T42<kalube> Link your kernel source20:16
T42<kalube> looking at your dmesg.log suggests you might be having an issue with the power supply driver20:20
T42<kalube> No idea what's causing the error, but I had an issue before where the phone was failing to start because of so much log spam (journald was using 100% CPU). Comment out this line and then get logs again
T42<kalube> You'll need to comment out lines 114-11620:24
T42<elros34> how is that possible that your dmesg is so big if your previous logs had < 100 lines: Did you cutted it instead provide full...?20:26
T42<kalube> He cut and pasted from his terminal instead of actually getting the whole log20:26
T42<elros34> oh c'mon we struggle because of lack of useful dmesg and journal. With such a log he gives you it's obvious why dmesg fails to show anything useful20:28
T42<Rodrigosolari> @elros34 it eliminated the identical lines, that's why it put ..., because it was the powersupply error and indicated the ... that it continued20:56
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> @kalube  this log21:06
T42<kalube> `systemctl status droid-hal-init --no-pager` please21:08
T42<kalube> trace_printk() being used. Allocating extra memory. This means that this is a DEBUG kernel and it is unsafe for production use.21:09
T42<kalube> oh no21:09
T42<Rodrigosolari> sh-3.2# systemctl status droid-hal-init --no-pager21:10
T42<Rodrigosolari> ● droid-hal-init.service - droid-hal-init21:10
T42<Rodrigosolari>    Loaded: loaded (/lib/systemd/system/droid-hal-init.service; disabled; vendor preset: enabled)21:10
T42<Rodrigosolari>    Active: inactive (dead)21:10
T42<kalube> systemctl start droid-hal-init21:11
T42<Rodrigosolari> after add ld.config.28.txt in the config, droid-hal-init not start21:11
T42<kalube> it was running before?21:11
T42<kalube> with errors?21:12
T42<Rodrigosolari> yes21:12
T42<Rodrigosolari> it was running21:12
T42<Rodrigosolari> before21:12
T42<Rodrigosolari> afted add ld.config.28.txt not found21:12
T42<kalube> So what is your current problem?21:13
T42<Rodrigosolari> not start droid-hal-init21:13
T42<kalube> "afted add ld.config.28.txt not found" what does this mean?21:13
T42<Rodrigosolari> when I started logcat I got errors, install the previous zip and I'll send them to you21:14
T42<kalube> what?21:14
deathmist@Rodrigosolari if the ld config stuff was the only thing you changed you can just `systemctl disable system-etc-ld.config.28.txt.mount` and `reboot` instead of flashing your old zips again?21:14
deathmistshow journal, dmesg and logcat after you disable it with FULL CONTENT AFTER WAITING FOR AROUND 30 SECONDS, you maybe should have done the same with that enabled as you seemingly grabbed the logs instantly after booting21:16
T42<Rodrigosolari> thisthis @kalube
T42<Rodrigosolari> deathmist: in 30 second the phone is reboot.21:19
T42<kalube> yes I know what that is. I want to know why you think errors in logcat are relevant? What are you stuck on with your device and how can we help? You need to pick a problem ie droid-hal-init doesn't start, give us proper logs and speak in a way that we can understand if you want us to be able to help you21:19
T42<Rodrigosolari> deathmisht: sh-3.2# systemctl disable system-etc-ld.config.28.txt.mount21:19
T42<Rodrigosolari> Error getting authority: Error initializing authority: Could not connect: No such file or directory (g-io-error-quark, 1)21:19
T42<Rodrigosolari> @kalube this my logcat from befrote21:23
T42<Rodrigosolari> yes I know what that is. I want to know why you think errors in logcat are relevant? What are you stuck on with your device and how can we help? You need to pick a problem ie droid-hal-init doesn't start, give us proper logs and speak in a way that we can understand if you want us to be able to help you21:23
T42<Rodrigosolari> @kalube  this my logcat from before21:24
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> (Document)
T42<Rodrigosolari> @kalube , deathmist: this my logs21:35
T42<kalube> droid-hal-init is running21:37
T42<Rodrigosolari> yes, I am in the previous version, before adding ld.config, only it gives me an error.21:39
T42<Rodrigosolari> --------- beginning of crash21:39
T42<Rodrigosolari> 12-13 13:02:44.070  3229  3229 F linker  : CANNOT LINK EXECUTABLE "/system/bin/servicemanager": library "/usr/libexec/droid-hybris/system/lib64/" needed or dlopened by "/system/bin/servicemanager" is not accessible for the namespace "(default)"21:39
T42<kalube> which is fixed by adding the ld.config21:39
T42<kalube> You read Deathmist's message that you can simply disable the bind mount unit instead of reflashing your old zip file right?21:40
T42<Rodrigosolari> yes, i read but it gives me this error21:42
T42<Rodrigosolari> sh-3.2# systemctl disable system-etc-ld.config.28.txt.mount21:42
T42<Rodrigosolari> Error getting authority: Error initializing authority: Could not connect: No such file or directory (g-io-error-quark, 1)21:42
T42<Rodrigosolari> my system is reboot after 1 min21:43
T42<kalube> you can do it manually by creating a symlink... `ln -s /dev/null /etc/systemd/system/ld.config.28.txt`21:43
T42<kalube> make your journal logs non volatile and run `journalctl -b -1` to get the logs of the previous boot and that should explain why it crashed21:45
T42<kalube> it's all explained the FAQ21:45

Generated by 2.17.1 by Marius Gedminas - find it at!