Section XIP Porting to the appliances Himalaya
Compatible:
O2 XDA II, T-Mobile MDA II, Qtek 2020, iMate Phone Edition, TSM500, and other variants PH10
As a rule, move the XIP (kernel - kernel), is one principle
to describe below. porting principle applies to the total users and the Himalaya
Preparation:
I will not describe here how to obtain this section, assume that each of you has already been mined xip.bin.
1) Create a directory called eg Old_XIP
-> Copy to him,
- Xip.bin (From with nk.nba our device)
- XIPPort.exe
- Pkgcommon.dll
- Mreloc.exe
Run XIPPort.exe and press:
-> dump xip.bin
-> realloc P
-> write maps
By creating a folder with the name and it OUT MODULES 2 folders and files:
-Delete:
The catalog of files:
• 778fa68c-6f86-312d-7cfb-6862e7b2f41c.dsm
• 778fa68c-6f86-312d-7cfb-6862e7b2f41c.dsm.imageinfo.txt
• 723fb954-d931-4348-b672-82a188e587b5.dsm
• 723fb954-d931-4348-b672-82a188e587b5.dsm.imageinfo.txt
• 723fb954-d931-4348-b672-82a188e587b5.rgu
• 723fb954-d931-4348-b672-82a188e587b5.rgu.imageinfo.txt
• d92a4f0a-378a-4482-8fd3-bd127a05e4de.dsm
• d92a4f0a-378a-4482-8fd3-bd127a05e4de.dsm.imageinfo.txt
• boot_ms.rgu
• boot_ms.rgu.imageinfo.txt
• mxip_lang.vol
• mxip_lang.vol.imageinfo.txt
• sysroots.p7b
• sysroots.p7b.imageinfo.txt
The catalog of modules:
• busenum.dll + busenum.dll.txt
• cachefilt.dll + cachefilt.dll.txt
• certmod.dll + certmod.dll.txt
• coredll.dll + coredll.dll.txt
• crypt32.dll + crypt32.dll.txt
• device.exe + device.exe.txt
• devmgr.dll + devmgr.dll.txt
• diskcache.dll + diskcache.dll.txt
• fatfsd.dll + fatfsd.dll.txt
• fatutil.dll + fatutil.dll.txt
• filesys.exe + filesys.exe.txt
• fsdmgr.dll + fsdmgr.dll.txt
• fsreplxfilt.dll + fsreplxfilt.dll.txt
• mencfilt.dll + mencfilt.dll.txt
• mspart.dll + mspart.dll.txt
• pm.dll + pm.dll.txt
• regenum.dll + regenum.dll.txt
All modules and files and corresponding. Txt, which we removed, we must now replace these with new XIP section ... ... ... ....
2) Create a directory called eg New_ XIP
-> Copy to him,
- Xip.bin (from with another device nk.nba)
- XIPPort.exe
- Pkgcommon.dll
Run XIPPort.exe and press:
-> dump xip.bin
-> make Pkgs
Copy all files and modules, together with the corresponding. Txt, XIP to the old section, which should look like this:
The catalog of files:
Files in New XIP Section:
• 778fa68c-6f86-312d-7cfb-6862e7b2f41c.dsm
• 778fa68c-6f86-312d-7cfb-6862e7b2f41c.dsm.imageinfo.txt
• 723fb954-d931-4348-b672-82a188e587b5.dsm
• 723fb954-d931-4348-b672-82a188e587b5.dsm.imageinfo.txt
• 723fb954-d931-4348-b672-82a188e587b5.rgu
• 723fb954-d931-4348-b672-82a188e587b5.rgu.imageinfo.txt
• d92a4f0a-378a-4482-8fd3-bd127a05e4de.dsm
• d92a4f0a-378a-4482-8fd3-bd127a05e4de.dsm.imageinfo.txt
• boot_ms.rgu
• boot_ms.rgu.imageinfo.txt
• mxip_lang.vol
• mxip_lang.vol.imageinfo.txt
• sysroots.p7b
• sysroots.p7b.imageinfo.txt
Files from the old XIP Section:
• 8677e734-fc16-3610-0db1-001405fb4b9a.dsm
• 8677e734-fc16-3610-0db1-001405fb4b9a.dsm.imageinfo.txt
• boot.hv
• boot.hv.imageinfo.txt
• boot.rgu
• boot.rgu.imageinfo.txt
• e27f9da5-f2bd-6586-1098-afeef97ab52a.dsm
• e27f9da5-f2bd-6586-1098-afeef97ab52a.dsm.imageinfo.txt
The catalog of modules:
Modules from New XIP Section:
• busenum.dll + busenum.dll.txt
• cachefilt.dll + cachefilt.dll.txt
• certmod.dll + certmod.dll.txt
• coredll.dll + coredll.dll.txt
• crypt32.dll + crypt32.dll.txt
• device.exe + device.exe.txt
• devmgr.dll + devmgr.dll.txt
• diskcache.dll + diskcache.dll.txt
• fatfsd.dll + fatfsd.dll.txt
• fatutil.dll + fatutil.dll.txt
• filesys.exe + filesys.exe.txt
• fsdmgr.dll + fsdmgr.dll.txt
• fsreplxfilt.dll + fsreplxfilt.dll.txt
• mencfilt.dll + mencfilt.dll.txt
• mspart.dll + mspart.dll.txt
• pm.dll + pm.dll.txt
• regenum.dll + regenum.dll.txt
The modules from the old XIP Section:
• msflash.dll + msflash.dll.txt
• cecompr.dll + cecompr.dll.txt
• ceddk.dll + ceddk.dll.txt
• nk.exe + nk.exe.txt
• relfsd.dll + relfsd.dll.txt
• imgfs.dll + imgfs.dll.txt
• initvmmap.exe + initvmmap.exe.txt
In such a structure should look like your Out folder, we must remember that the files and modules from the Old and New XIP-a given in the catalog from the old kernel, as more than FILES folders and modules, we have 4 files. Txt Kernel-old with a . We must remember that they are playing the first violin ... ... ..
To facilitate these files are:
1. PARTHDR.txt
2. ROMHDR.txt
3. MAP.physical.txt
4. MAP.txt *
* According to the MAP.txt, we will lay the entire section based on the addresses of its virtual memory.
As a rule looks like:
01fa01fe - 01fa01fe L00000000 Start: first DLL address
01fa01fe - 01feb000 L0004ae02 NUL
01feb000 - 01fec000 L00001000 initialized data of region_1 ceddk.dll
01fec000 - 01fed000 L00001000 initialized data of region_1 msflash.dll
01fed000 - 01fee000 L00001000 initialized data of region_1 relfsd.dll
01fee000 - 01fef000 L00001000 initialized data of region_2 cecompr.dll
01fef000 - 01ff0000 L00001000 initialized data of region_1 regenum.dll
01ff0000 - 01ff1000 L00001000 initialized data of region_1 pm.dll
01ff1000 - 01ff2000 L00001000 initialized data of region_1 mspart.dll
01ff2000 - 01ff3000 L00001000 initialized data of region_1 imgfs.dll
01ff3000 - 01ff4000 L00001000 initialized data of region_1 fsreplxfilt.dll
01ff4000 - 01ff5000 L00001000 initialized data of region_1 fsdmgr.dll
01ff5000 - 01ff6000 L00001000 initialized data of region_1 fatutil.dll
01ff6000 - 01ff7000 L00001000 initialized data of region_1 fatfsd.dll
01ff7000 - 01ff8000 L00001000 initialized data of region_1 encfilt.dll
01ff8000 - 01ff9000 L00001000 initialized data of region_1 diskcache.dll
01ff9000 - 01ffa000 L00001000 initialized data of region_1 devmgr.dll
01ffa000 - 01ffc000 L00002000 initialized data of region_1 Crypt32.dll
01ffc000 - 01ffd000 L00001000 initialized data of region_1 coredll.dll
01ffd000 - 01ffe000 L00001000 initialized data of region_1 certmod.dll
01ffe000 - 01fff000 L00001000 initialized data of region_1 cachefilt.dll
01fff000 - 02000000 L00001000 initialized data of region_1 busenum.dll
02000000 - 02000000 L00000000 End: last DLL address
02000000 - 03dc0000 L01dc0000 NUL
03dc0000 - 03dc6000 L00006000 Virtual base address of ceddk.dll
03dc6000 - 03dd0000 L0000a000 NUL
03dd0000 - 03dda000 L0000a000 Virtual base address of msflash.dll
03dda000 - 03de0000 L00006000 NUL
03de0000 - 03de7000 L00007000 Virtual base address of relfsd.dll
03de7000 - 03df0000 L00009000 NUL
03df0000 - 03df7000 L00007000 Virtual base address of cecompr.dll
03df7000 - 03e5e000 L00067000 NUL
03e5e000 - 03e62000 L00004000 Virtual base address of regenum.dll
03e62000 - 03e71000 L0000f000 Virtual base address of pm.dll
03e71000 - 03e79000 L00008000 Virtual base address of mspart.dll
03e79000 - 03e83000 L0000a000 Virtual base address of imgfs.dll
03e83000 - 03e8d000 L0000a000 Virtual base address of fsreplxfilt.dll
03e8d000 - 03ea2000 L00015000 Virtual base address of fsdmgr.dll
03ea2000 - 03eab000 L00009000 Virtual base address of fatutil.dll
03eab000 - 03ebe000 L00013000 Virtual base address of fatfsd.dll
03ebe000 - 03eca000 L0000c000 Virtual base address of encfilt.dll
03eca000 - 03ed0000 L00006000 Virtual base address of diskcache.dll
03ed0000 - 03edc000 L0000c000 Virtual base address of devmgr.dll
03edc000 - 03f4e000 L00072000 Virtual base address of Crypt32.dll
03f4e000 - 03fe4000 L00096000 Virtual base address of coredll.dll
03fe4000 - 03ff0000 L0000c000 Virtual base address of certmod.dll
03ff0000 - 03ffa000 L0000a000 Virtual base address of cachefilt.dll
03ffa000 - 04000000 L00006000 Virtual base address of busenum.dll
04000000 - 801c0000 L7c1c0000 NUL
Important: remember that in the final map, on the whole relocation, there was no exclamation ... ....
The substitution Address M'reloc help us, however, the need for each module in the file imageinfo.txt of change such as address change above in the application, otherwise your OS does not stand up ... ... ... ...
amazing work, nice tutorial, Sticky!
Here is some more info :
to extract the Himalaya XIP :
RomMaster.exe nk.nba -w 5 -b 0x1C0040 -x -o xip.bin
To Extract nk.nba from nk.nbf :
xda2nbftool.exe -x nk.nbf nk.nba 0x20040304
Rom Master.exe and xda2nbf are attached below
Thank's
Thank's to link to program's .....
Complete Tools
Here is an AIO package of tools required, includes :
- XIPPort.exe
- Pkgcommon.dll
- Mreloc.exe
- RomMaster.exe
Good
Very good THX
cook
thank you. For xip port
Xip porting
very please me dear freand
Error when extract xip.bin
ather90 said:
amazing work, nice tutorial, Sticky!
Here is some more info :
to extract the Himalaya XIP :
RomMaster.exe nk.nba -w 5 -b 0x1C0040 -x -o xip.bin
Click to expand...
Click to collapse
i'v got error when extracting xip.bin.. when i see list command for RomMaster.exe, I did'nt see "-b" command on the list command
Is anything wrong??
Thanks for advice
......
I don't no,this aplikation and command is Ok.......... You one more thi's command
12omy said:
i'v got error when extracting xip.bin.. when i see list command for RomMaster.exe, I did'nt see "-b" command on the list command
Is anything wrong??
Click to expand...
Click to collapse
Yes, you have a wrong version of RomMaster.
XIP porting
Meybe...... I have v.2.3
the -b switch were added later, so he has an old version of this tool
command
this command -> RomMaster.exe nk.nba -w 5 -b 0x001C0040 -x -o xip.bin
If he has this old version, he could try without specifying an address:
RomMaster.exe nk.nba -w 5 -x -o xip.bin
maybe it will work, can't remember it now. If not, he should download the newer RomMaster version.
Yes, is work for old version this command
XIP extract
Yes.. My apologize for did'nt see version of RomMaster.exe . Now I have correct version RomMaster.exe v2.3
I just want to know, is the offset code same with other device ROM? If different how we can get the offset code address for each device ROM
Thanks for advice...
The address is different for every device - that's why you should specify it... if it were the same, there wouldn't be such option
yea, the offset are diff, i'll list some offsets for some device, (let me look up my dusty HDD )
Hello Ather long time no see... congrats on becoming a moderator
Hey utak3, been missing your input too , and thanks
Related
I have a problem with some CABs:
wceLoad prevents me to install any CAB with registry setting - any DWORD value in the range 0x80000000 - 0xFFFFFFFF
Is it a bug?
--------
If you wish to replicate my problem, try to install two attached CABs.
Both of them contains dummy file \Temp\temp.txt
test_OK.cab sets HKLM\Test\Test_00000000 to 0x7FFFFFFF [this is OK]
test_fail.cab sets HKLM\Test\Test_00000000 to 0x80000000 [this is not OK]
MODIFICATIONS
In this part of the course, as a general rule, we modify our system.
It connects to the addition and removal of various types: application, file or even substitutions skins and overlays system. But we must remember not to reload the ROM to us, because when it comes to our device is limited to 32 MB.
Let's start now, modify the presentation of the sample. This applies in particular for new cooks. In this process, we can breathe lightly and not to think that somehow our uwalimy device. It is rare that the phone is not included in the substitution or deletion of a program.
Remember - all the changes shown in this article are just an example. The need to know (for this example) which add and remove what ... .. To do the work ....
First what we need in our oven, and a folder to obtain "dump"
Open kitchen, based on the command line, which is created in the first part of this course:
We viewed the 4 position, select:
[1] - This ROM dump
I wait until the process is complete ... ... ..
Upon completion, we can see each other, exactly the folder.
Then, for the subsequent work click on:
[2] - REGISTRY. dv To. rgu
In the root, we have established the following two files:
-default.hv
-user.hv
Both files opened with - Notepad + + . See a string, something like this:
Code:
REGEDIT4
[HKEY_CLASSES_ROOT \. Zip]
@ = "zipfile"
[HKEY_CLASSES_ROOT \. Rar]
@ = "PocketRAR"
[HKEY_CLASSES_ROOT \ SimToolkit.UI]
@ = "UI Toolkit"
[HKEY_CLASSES_ROOT \ SimToolkit.UI \ CLSID]
@ = "(7B58F1D9-1C13-440f-894B-B90680570A2D)"
[HKEY_CLASSES_ROOT \ ExSMime.MimeReader.1]
@ = "MIME Reader"
Important:
-> In the beginning we have to enter the registry:REGEDIT4
-> Also, see if between each key is at least one blank line, ie there is no entry
-> All files. Rgu save in UNICODE, so we have opened such as default.rgu in Notepad + + click File> Encoding> Unicode
-> New keys entered by us, can not double the old
In this way we have prepared a record, we can now freely edit.
Now, we'll file Initflashfiles.dat
With this file we will not have in total, no problems. The only thing we will be interested to add or remove tracks, of course, they are dependent on the arrangement of folders and applications, or the peaks appearing in them.
For a deeper understanding of an application to add a ROM, but it must be in OEM format, how to do this? This is described at some length on the Internet. The second of the output, are designed for the software, which of the files. Cab form OEM
Insert into the application:
Consider, for example, the Pocket RAR in OEM format. Open the folder, we are interested in it:
- inietflaszfiles.txt,
- *. rgu - Registry File
- PocketRAR.exe - program
- PocketRAR.lnk - shortcut
In the first instance, to copy the folder dump: - PocketRAR.exe - software
I PocketRAR.lnk - shortcut
Open your file initflaszfiles.txt to the OEM:
Code:
Directory ( "\ Windows \ Start Menu \ Programs"):-Directory ( "Accessories")
Directory ( "\ Windows \ Start Menu \ Programs \ Accessories"):-File ( "Pocket RAR.lnk", "\ Windows \ RAR.lnk Pocket")
copy its contents to the main Initflashfiles.dat from the dump. This is to look like this.
This is the end of the passage of this file:
Code:
......
;================================================= =========================
; SAP MASD customization settings
;================================================= =========================
Directory ( "\ Windows \ AppButtons"):-File ( "Calendar.lnk", "\ Windows \ calendar.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Contacts.lnk", "\ Windows \ addrbook.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Tasks.lnk", "\ Windows \ tasks.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Record.lnk", "\ Windows \ voice.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Camera.lnk", "\ Windows \ camera.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Messaging.lnk", "\ Windows \ tmail.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Camera.lnk", "\ Windows \ Camera.lnk")
Directory ( "\ Windows \ AppButtons"):-File ( "Comm Manager.lnk", "\ Windows \ CommManager.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "BPInsert.lnk", "\ Windows \ BPInsert.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "coldinit.lnk", "\ Windows \ coldinit.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "bugtrap.lnk", "\ Windows \ bugtrap.lnk");
Directory ( "\ Windows \ StartUp"):-File ( "poutlook.lnk", "\ Windows \ poutlook.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "HandsFree.lnk", "\ Windows \ HandsFree.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "Welcome.lnk", "\ Windows \ welcome.lnk")
Directory ( "\ Windows \ StartUp"):-File ( "ScreenRotate.lnk", "\ Windows \ ScreenRotate.lnk")
;================================================= =========================
; End - SAP MASD customization settings
;================================================= =========================
;================================================= ================================================
; Pocket RAR Home
;================================================= ================================================
Directory ( "\ Windows \ Start Menu \ Programs"):-Directory ( "System")
Directory ( "\ Windows \ Start Menu \ Programs \ System"):-File ( "Pocket RAR.lnk", "\ Windows \ RAR.lnk Pocket")
;================================================= ================================================
; Pocket RAR End
;================================================= ================================================
Then, open *.rgu and copy its contents to default.rgu or user.rgu.
Writing kluchy, is dependent on its path. Each new path has to be in this part of the registry where the key begins in the same way.
An example of a registry entry for PocketRAR:
Code:
[HKEY_CLASSES_ROOT \. zip]
@ = "PocketRAR"
[HKEY_CLASSES_ROOT \. Rar]
@ = "PocketRAR"
So we have to place it where keys start with:
Code:
[HKEY_CLASSES_ROOT]
If the operation completed successfully, that the application will work poprawnie.Do modify the registry, are the various outputs, my way is not a last resort. This type of keys, and their removal also save our memory, which is extremely low.
We can also replace the driver or a new version of the program such as File Explore - in this case, replace the virtual memory address and the address of relocation, because otherwise this application does not start. Saved as a module, which is different from the file? Look up to our dump, you can see the difference at first glance, the content is located in the directory.
The fact is that the conversion module, with the newer ROM version, we also need to replace these two values as described above. Podmieniając file, we do not have the obligation to relocate, even under the old addresses.
Welcome to Part three of this Course
To translate the system - the relationship and functionality of files and modules ....
Hello,
I tried to build a kernel myself and it just fails to boot. I have UART access (through headphone adapter) and I just get nothing in the serial console.
I have CM 11.0 and I cloned CM's android_kernel_lge_hammerhead repo and checked out stable/cm-11.0 with hammerhead_defconfig.
I used google's arm-eabi-4.8 precompiled toolchain.
To boot:
Code:
ttouch android_kernel_lge_hammerhead> sudo fastboot boot arch/arm/boot/zImage-dtb
creating boot image...
creating boot image - 8583168 bytes
downloading 'boot.img'...
OKAY [ 0.375s]
booting...
OKAY [ 0.123s]
finished. total time: 0.498s
Here is what I get in UART:
Code:
welcome to hammerhead bootloader
[10] Power on reason 81
[10] DDR: elpida
[90] Loaded IMGDATA at 0x11000000
[90] Display Init: Start
[170] MDP GDSC already enabled
[170] bpp 24
[210] Config MIPI_CMD_PANEL.
[210] display panel: ORISE
[210] display panel: Default setting
[340] Turn on MIPI_CMD_PANEL.
[390] Display Init: Done
[390] cable type from shared memory: 8
[390] vibe
[590] USB init ept @ 0xf957000
[610] secured device: 1
[610] fastboot_init()
[660] splash: fastboot_op
FASTBOOT MODE
PRODUCT_NAME - hammerhead
VARIANT - hammerhead D821(E) 16GB
HW VERSION - rev_11
BOOTLOADER VERSION - HHZ11k
BASEBAND VERSION - M8974A-2.0.50.1.16
CARRIER INFO - None
SERIAL NUMBER - <blablablabla>
SIGNING - production
SECURE BOOT - enabled
LOCK STATE - unlocked
[770] splash: start
[1260] splash: bootloader
[1260] Fastboot mode started
[1260] udc_start()
�����l[60660] -- reset --
[60660] -- portchange --
[60820] -- reset --
[60820] -- portchange --
[60990] fastboot: processing commands
��[112660] fastboot: download:0082f800
downloading...
[113140] fastboot: boot
[113150] Found Appeneded Flattened Device tree
[113150] DTB: platform id 126, board id 150, soc rev 20002, board rev 11
[113160] get_display_kcal = 0, 0, 0, x
[113200] vibe
[113300] splash: boot
[113340] splash: unlocked
[113380] cmdline: uart_console=enable lcd_maker_id=primary lge.hreset=off lge.reset=unknown gpt=enable lge.kcal=0|0|0|x lge.rev=rev_11 androidboot.laf androidboot.emmc=true fastboot=true androidboot.serialno=<blablablabla> androidboot.bootloader=HHZ11k androidb[113400] Updating device tree: start
[113420] Updating device tree: done
[113420] booting linux @ 0x10008000, ramdisk @ 0x11000000 (0), tags/device tree @ 0x10000100
[113430] Turn off MIPI_CMD_PANEL.
[113430] Continuous splash enabled, keeping panel alive.
[113430] undefined abort, halting
[113430] r0 0x00000000 r1 0x00000000 r2 0x10000100 r3 0x003996e3
[113430] r4 0x10008000 r5 0x0f92607a r6 0x0f925d5b r7 0x0f925f89
[113430] r8 0x0f955652 r9 0x0f9556c7 r10 0x00000001 r11 0x10000100
[113430] r12 0x20000193 usp 0x00000000 ulr 0x00000000 pc 0x1000800c
[113430] spsr 0x40000193
I've never installed a kernel like that (via fastboot) and I had to look up the headphone UART adapter thing.
I don't have much to offer. I always use mkbootimg to link my kernel and ramdisk, then flash it via fastboot. Looking at your serial dump, the only thing I see is that the base, ramdisk, and tags offsets look completely different from the ones I use with mkbootimg.
BASE=0x00000000
PAGESIZE=2048
RAMDISK_OFFSET=0x02900000
TAGS_OFFSET=0x02700000
I'm playing around with my breadboard and an FTDI USB<-->Serial board I have to try and make a working serial console and I'll see what my N5 dumps.
Gene Poole said:
I've never installed a kernel like that (via fastboot) and I had to look up the headphone UART adapter thing.
I don't have much to offer. I always use mkbootimg to link my kernel and ramdisk, then flash it via fastboot. Looking at your serial dump, the only thing I see is that the base, ramdisk, and tags offsets look completely different from the ones I use with mkbootimg.
BASE=0x00000000
PAGESIZE=2048
RAMDISK_OFFSET=0x02900000
TAGS_OFFSET=0x02700000
Click to expand...
Click to collapse
Thanks, I'll try that.
Gene Poole said:
I'm playing around with my breadboard and an FTDI USB<-->Serial board I have to try and make a working serial console and I'll see what my N5 dumps.
Click to expand...
Click to collapse
I guess you're trying to build the N4 cable, but it does not work.
For the N5 to work you need to supply 3V3 and not 1V8 to the VCC
The RX though (serial input to the N5) should be 1V8 (done with a simple voltage divider, try 1K and 1.2K to GND) or there is a chance that you'll fry your serial.
Yeah, my search showed that the N5 version needed no resistors, but I used some anyway just to shunt some voltage. It worked. I got a dump and it does appear that your offsets are not right. Here's my dump up to the kernel taking over:
Code:
welcome to hammerhead bootloader
[10] Power on reason 80
[10] DDR: hynix
[90] Loaded IMGDATA at 0x11000000
[90] Display Init: Start
[170] MDP GDSC already enabled
[170] bpp 24
[210] Config MIPI_CMD_PANEL.
[210] display panel: ORISE
[260] Found Appeneded Flattened Device tree
[260] DTB: platform id 126, board id 150, soc rev 20002, board rev 11
[300] Set panel ON cmds [35]
[420] Turn on MIPI_CMD_PANEL.
[470] Display Init: Done
[470] cable type from shared memory: 8
[470] reboot_mode restart reason = power_on
[520] vibe
[620] splash: boot
[660] splash: unlocked
[700] use_signed_kernel=0, is_unlocked=1, is_tampered=0.
[700] Loading boot image (9226240): start
[1030] Loading boot image (9226240): done
[1030] Found Appeneded Flattened Device tree
[1040] DTB: platform id 126, board id 150, soc rev 20002, board rev 11
[1040] get_display_kcal = 0, 0, 0, x
[1050]
Booting Linux
[1050] cmdline: console=ttyHSL0,115200,n8 androidboot.hardware=hammerhead user_debug=31 maxcpus=2 msm_watchdog_v2.enable=1 selinuxt
[1090] Updating device tree: done
[1090] booting linux @ 0x8000, ramdisk @ 0x2900000 (714802), tags/device tree @ 0x2700000
[1100] Turn off MIPI_CMD_PANEL.
[1100] Continuous splash enabled, keeping panel alive.
[ 0.000000] Booting Linux on physical CPU 0
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Linux version 3.4.0-hoxnet-gd745771 ([email protected]) (gcc version 4.6.x-google 20120106 (prerelease) (GCC) ) #7 SMP PREE5
[ 0.000000] CPU: ARMv7 Processor [512f06f0] revision 0 (ARMv7), cr=10c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache
...
I see a fastboot option, -b, for specifying the kernel base address. Try with -b 0x8000.
Edit: maybe it's -b 0. looks like the address gets 0x8000 added by default.
Gene Poole said:
Yeah, my search showed that the N5 version needed no resistors, but I used some anyway just to shunt some voltage. It worked. I got a dump and it does appear that your offsets are not right. Here's my dump up to the kernel taking over:
Code:
welcome to hammerhead bootloader
[10] Power on reason 80
[10] DDR: hynix
[90] Loaded IMGDATA at 0x11000000
[90] Display Init: Start
[170] MDP GDSC already enabled
[170] bpp 24
[210] Config MIPI_CMD_PANEL.
[210] display panel: ORISE
[260] Found Appeneded Flattened Device tree
[260] DTB: platform id 126, board id 150, soc rev 20002, board rev 11
[300] Set panel ON cmds [35]
[420] Turn on MIPI_CMD_PANEL.
[470] Display Init: Done
[470] cable type from shared memory: 8
[470] reboot_mode restart reason = power_on
[520] vibe
[620] splash: boot
[660] splash: unlocked
[700] use_signed_kernel=0, is_unlocked=1, is_tampered=0.
[700] Loading boot image (9226240): start
[1030] Loading boot image (9226240): done
[1030] Found Appeneded Flattened Device tree
[1040] DTB: platform id 126, board id 150, soc rev 20002, board rev 11
[1040] get_display_kcal = 0, 0, 0, x
[1050]
Booting Linux
[1050] cmdline: console=ttyHSL0,115200,n8 androidboot.hardware=hammerhead user_debug=31 maxcpus=2 msm_watchdog_v2.enable=1 selinuxt
[1090] Updating device tree: done
[1090] booting linux @ 0x8000, ramdisk @ 0x2900000 (714802), tags/device tree @ 0x2700000
[1100] Turn off MIPI_CMD_PANEL.
[1100] Continuous splash enabled, keeping panel alive.
[ 0.000000] Booting Linux on physical CPU 0
[ 0.000000] Initializing cgroup subsys cpu
[ 0.000000] Linux version 3.4.0-hoxnet-gd745771 ([email protected]) (gcc version 4.6.x-google 20120106 (prerelease) (GCC) ) #7 SMP PREE5
[ 0.000000] CPU: ARMv7 Processor [512f06f0] revision 0 (ARMv7), cr=10c5387d
[ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, PIPT instruction cache
...
I see a fastboot option, -b, for specifying the kernel base address. Try with -b 0x8000.
Edit: maybe it's -b 0. looks like the address gets 0x8000 added by default.
Click to expand...
Click to collapse
Didn't work.
I also tried to build a boot.img, I flashed it (just to be sure) and I get all the same results.
My tags/device tree is different and I don't know how to change it. There is no available option in fastboot or mkbootimg
ttouch said:
Didn't work.
I also tried to build a boot.img, I flashed it (just to be sure) and I get all the same results.
My tags/device tree is different and I don't know how to change it. There is no available option in fastboot or mkbootimg
Click to expand...
Click to collapse
mkbootimg has an undocumented --tags_offset option. I don't know why it doesn't show up in the --help. I found it in the source for mkbootimg (in the AOSP tree) when I first ran the unpackbootimg and noticed that it dumped text files containing info about the offsets.
I have a shell script I use to make boot images. Here it is:
Code:
#!/bin/sh
RAMDISK=ramdisk
KERNEL=zImage
BASE=0x00000000
PAGESIZE=2048
RAMDISK_OFFSET=0x02900000
TAGS_OFFSET=0x02700000
CMDLINE="console=ttyHSL0,115200,n8 androidboot.hardware=hammerhead user_debug=31 maxcpus=2 msm_watchdog_v2.enable=1 selinux=1"
echo Making ramdisk image ...
(cd ${RAMDISK} ; mkbootfs . | gzip -9c > ../${RAMDISK}.cpio.gz )
echo Making boot image ...
mkbootimg --kernel ${KERNEL} --ramdisk ${RAMDISK}.cpio.gz --cmdline "${CMDLINE}" -o boot.img --base ${BASE} --pagesize ${PAGESIZE} --ramdisk_offset ${RAMDISK_OFFSET} --tags_offset ${TAGS_OFFSET}
"ramdisk" is a directory containing the unpacked AOSP stock ramdisk (plus my modifications). These offset values were obtained from unpackbootimg executable but I can't remember where I found the source. I'll send you a copy if you want it.
Gene Poole said:
mkbootimg has an undocumented --tags_offset option. I don't know why it doesn't show up in the --help. I found it in the source for mkbootimg (in the AOSP tree) when I first ran the unpackbootimg and noticed that it dumped text files containing info about the offsets.
I have a shell script I use to make boot images. Here it is:
Code:
#!/bin/sh
RAMDISK=ramdisk
KERNEL=zImage
BASE=0x00000000
PAGESIZE=2048
RAMDISK_OFFSET=0x02900000
TAGS_OFFSET=0x02700000
CMDLINE="console=ttyHSL0,115200,n8 androidboot.hardware=hammerhead user_debug=31 maxcpus=2 msm_watchdog_v2.enable=1 selinux=1"
echo Making ramdisk image ...
(cd ${RAMDISK} ; mkbootfs . | gzip -9c > ../${RAMDISK}.cpio.gz )
echo Making boot image ...
mkbootimg --kernel ${KERNEL} --ramdisk ${RAMDISK}.cpio.gz --cmdline "${CMDLINE}" -o boot.img --base ${BASE} --pagesize ${PAGESIZE} --ramdisk_offset ${RAMDISK_OFFSET} --tags_offset ${TAGS_OFFSET}
"ramdisk" is a directory containing the unpacked AOSP stock ramdisk (plus my modifications). These offset values were obtained from unpackbootimg executable but I can't remember where I found the source. I'll send you a copy if you want it.
Click to expand...
Click to collapse
My mkbootimg does not have the tags_offset.
When I try to build the boot image with tags_offset, mkbootimg shows me the help message, which means it got no tags_offset option.
EDIT: Nevermind, I cloned and compiled the latest mkbootimg from here. Trying to boot it now...
EDIT2: IT WORKS!!
Since the AOSP build has to create a boot image, it is included in the utilities. I always use the one native to the build tree. It is in:
[aosp_root]/out/host/linux-x86/bin/mkbootimg
and the source is in:
[aosp_root]/system/core/mkbootimg/
Greetings;
I've been wrestling with EFS & DM-Verity problem on my SM-T713 for a week now to no avail!
I've tried almost every solution/info from Google search to no avail.
My Tab can get to "Download & Recovery(Custom or Oem) mode with no problem
but any Firmware flash from odin wind up with "Samsung" bootloop!
And if I flash stock firmware, it ends up at Recovery mode with the following error:
"failed to mount /efs (invalid argument) dm-varity verification failed"
Any help is much appreciated.
Thank you.
Just factory reset in recovery. does that help?
Lightn1ng said:
Just factory reset in recovery. does that help?
Click to expand...
Click to collapse
Hi and thank you for replying.
BTW, I enjoy your rom bro, thanks for all the time you put in man.
I tried everything to no avail. I think I know how to resolve it but my know how
is probably limited to work it through! If that make any sense!
I first need to know the exact name of the "EFS Partition" on SM-T713. Then I
need to use the terminal/command line to format it and re-mount it, that should
do it if nothing else is a problem.
If you do own the T713, maybe you can help or anyone else reading this and
Thank you for your help.
samteeee said:
Hi and thank you for replying.
BTW, I enjoy your rom bro, thanks for all the time you put in man.
I tried everything to no avail. I think I know how to resolve it but my know how
is probably limited to work it through! If that make any sense!
I first need to know the exact name of the "EFS Partition" on SM-T713. Then I
need to use the terminal/command line to format it and re-mount it, that should
do it if nothing else is a problem.
If you do own the T713, maybe you can help or anyone else reading this and
Thank you for your help.
Click to expand...
Click to collapse
Wiping your EFS is a bad idea, it contains stuff that should truly NEVER be deleted.
I'm going to bed now. I'll try to continue helping in the morning.
This is important: is TWRP working?
Lightn1ng said:
Wiping your EFS is a bad idea, it contains stuff that should truly NEVER be deleted.
I'm going to bed now. I'll try to continue helping in the morning.
This is important: is TWRP working?
Click to expand...
Click to collapse
Ok I'll hold till you get back to me and Yes TWRP working and I have root
but of course I cannot boot to Android. I'll talk to you Tomorrow if you have time
and appreciate your help brother.
samteeee said:
Ok I'll hold till you get back to me and Yes TWRP working and I have root
but of course I cannot boot to Android. I'll talk to you Tomorrow if you have time
and appreciate your help brother.
Click to expand...
Click to collapse
Sounds like an easy fix. Will post the links tomorrow. Cya!
samteeee said:
Ok I'll hold till you get back to me and Yes TWRP working and I have root
but of course I cannot boot to Android. I'll talk to you Tomorrow if you have time
and appreciate your help brother.
Click to expand...
Click to collapse
OK. I'm going to start with a simple fix. Flash the stock firmware, then flash TWRP. Within TWRP, go to Wipe, then tap Format Data. Now, type yes and hit enter. After that, go to Reboot>Recovery. Now, flash this zip by @ashyx:
https://www.androidfilehost.com/?fid=24591000424951049
Reboot and tell me if it works or not
Lightn1ng said:
OK. I'm going to start with a simple fix. Flash the stock firmware, then flash TWRP. Within TWRP, go to Wipe, then tap Format Data. Now, type yes and hit enter. After that, go to Reboot>Recovery. Now, flash this zip by @ashyx:
https://www.androidfilehost.com/?fid=24591000424951049
Reboot and tell me if it works or not
Click to expand...
Click to collapse
Unfortunately I did this yesterday but just to be 100% sure I did it again just
now and got the same result. Right after flashing the stock firmware with odin, it winds up in android
recovery with the following error:
"E: failed to mount /efs (Invalid argument"
" E: DM-Verity failed"!
samteeee said:
Unfortunately I did this yesterday but just to be 100% sure I did it again just
now and got the same result. Right after flashing the stock firmware with odin, it winds up in android
recovery with the following error:
"E: failed to mount /efs (Invalid argument"
" E: DM-Verity failed"!
Click to expand...
Click to collapse
Yes at that point reboot back into download mode and flash twrp, then continue
Lightn1ng said:
Yes at that point reboot back into download mode and flash twrp, then continue
Click to expand...
Click to collapse
Done! Stuck at "Samsung Blinking" !
samteeee said:
Done! Stuck at "Samsung Blinking" !
Click to expand...
Click to collapse
Can you do this from a terminal in TWRP:
cat /proc/last_kmsg > /sdcard/kmsg.log
And send me kmsg.log from your internal storage please
Lightn1ng said:
Can you do this from a terminal in TWRP:
cat /proc/last_kmsg > /sdcard/kmsg.log
And send me kmsg.log from your internal storage please
Click to expand...
Click to collapse
How did you want me to send it to you?!!!
samteeee said:
How did you want me to send it to you?!!!
Click to expand...
Click to collapse
Copy it via USB.
Here you go...........
B - 530547 - VSENSE CX: Vol1=900000,Code1=98, Vol2=1000000,Code2=123
B - 536830 - VSENSE APC0: Vol1=900000,Code1=97, Vol2=1000000,Code2=121
B - 543327 - VSENSE APC1: Vol1=900000,Code1=96, Vol2=1000000,Code2=120
D - 58712 - vsense_init, Delta
B - 565134 - clock_init, Start
D - 640 - clock_init, Delta
B - 565897 - @@ pm power on reason[0x200000080]
B - 569526 - @@ Reset status @sdi[0x7f6e24db]
B - 573979 - @@ Reset status @sbl1[0x0]
B - 579195 - boot_fota_restore_partition, Start
B - 583068 - FOTA restore magic no matching
D - 4148 - boot_fota_restore_partition, Delta
B - 593743 - Image metadata authentication, Start
D - 17598 - Image metadata authentication, Delta
B - 613324 - Load all segments into memory, Start
D - 23454 - Load all segments into memory, Delta
B - 639890 - Hash verification of all segments, Start
D - 11102 - Hash verification of all segments, Delta
D - 63409 - QSEE Image Loaded, Delta - (660012 Bytes)
B - 658281 - Image Load, Start
D - 793 - SEC Image Loaded, Delta - (2048 Bytes)
B - 666699 - sbl1_efs_handle_cookies, Start
D - 884 - sbl1_efs_handle_cookies, Delta
B - 674416 - VSENSE codes wrote into SMEM
B - 678503 - boot_fota_close_hdev, Start
D - 0 - boot_fota_close_hdev, Delta
B - 688842 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 708423 - Load all segments into memory, Start
D - 2775 - Load all segments into memory, Delta
B - 716079 - Hash verification of all segments, Start
D - 1098 - Hash verification of all segments, Delta
D - 39925 - QHEE Image Loaded, Delta - (99056 Bytes)
B - 731390 - RPM loading is successful.
B - 737551 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 757254 - Load all segments into memory, Start
D - 6466 - Load all segments into memory, Delta
B - 766800 - Hash verification of all segments, Start
D - 6740 - Hash verification of all segments, Delta
D - 41937 - RPM Image Loaded, Delta - (192712 Bytes)
B - 783270 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 802882 - Load all segments into memory, Start
D - 49684 - Load all segments into memory, Delta
B - 855616 - Hash verification of all segments, Start
D - 24796 - Hash verification of all segments, Delta
D - 103120 - APPSBL Image Loaded, Delta - (1508364 Bytes)
B - 887977 - QSEE Execution, Start
D - 61 - QSEE Execution, Delta
B - 894687 - SBL1, End
D - 593743 - SBL1, Delta
S - Flash Throughput, 25000 KB/s (2465934 Bytes, 94911 us)
S - DDR Frequency, 931 MHz
S - Core 0 Frequency, 800 MHz
device type 1 = 0x0
device type 2 = 0x0
microusb_clear_register() - reset start
microusb_clear_register() - reset end
device type 1 = 0x0
device type 2 = 0x0
device type 1 = 0x0
device type 2 = 0x0
device type 1 = 0x0
device type 2 = 0x0
Initialization_routine: Already F/G initialized(version:0x1)
device type 1 = 0x0
device type 2 = 0x0
BOOTLOADER VERSION : T713XXU1APG1
check_pit_integrity: invalid pit magic code.(0x0)
B - 509472 - VSENSE CX: Vol1=900000,Code1=99, Vol2=1000000,Code2=123
B - 515755 - VSENSE APC0: Vol1=900000,Code1=98, Vol2=1000000,Code2=121
B - 522312 - VSENSE APC1: Vol1=900000,Code1=97, Vol2=1000000,Code2=120
D - 58682 - vsense_init, Delta
B - 544028 - clock_init, Start
D - 640 - clock_init, Delta
B - 544821 - @@ pm power on reason[0x2000000081]
B - 548542 - @@ Reset status @sdi[0xfb6e24db]
B - 552904 - @@ Reset status @sbl1[0x0]
B - 558211 - boot_fota_restore_partition, Start
B - 562115 - FOTA restore magic no matching
D - 4148 - boot_fota_restore_partition, Delta
B - 572790 - Image metadata authentication, Start
D - 17598 - Image metadata authentication, Delta
B - 592310 - Load all segments into memory, Start
D - 23881 - Load all segments into memory, Delta
B - 619272 - Hash verification of all segments, Start
D - 11102 - Hash verification of all segments, Delta
D - 63775 - QSEE Image Loaded, Delta - (660012 Bytes)
B - 637663 - Image Load, Start
D - 793 - SEC Image Loaded, Delta - (2048 Bytes)
B - 645990 - sbl1_efs_handle_cookies, Start
D - 884 - sbl1_efs_handle_cookies, Delta
B - 653828 - VSENSE codes wrote into SMEM
B - 657824 - boot_fota_close_hdev, Start
D - 0 - boot_fota_close_hdev, Delta
B - 668255 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 687866 - Load all segments into memory, Start
D - 2806 - Load all segments into memory, Delta
B - 695552 - Hash verification of all segments, Start
D - 1098 - Hash verification of all segments, Delta
D - 40016 - QHEE Image Loaded, Delta - (99056 Bytes)
B - 710802 - RPM loading is successful.
B - 717055 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 736666 - Load all segments into memory, Start
D - 6588 - Load all segments into memory, Delta
B - 746335 - Hash verification of all segments, Start
D - 6832 - Hash verification of all segments, Delta
D - 42090 - RPM Image Loaded, Delta - (192712 Bytes)
B - 762927 - Image metadata authentication, Start
D - 17507 - Image metadata authentication, Delta
B - 782538 - Load all segments into memory, Start
D - 50599 - Load all segments into memory, Delta
B - 836218 - Hash verification of all segments, Start
D - 24766 - Hash verification of all segments, Delta
D - 104066 - APPSBL Image Loaded, Delta - (1508364 Bytes)
B - 868548 - QSEE Execution, Start
D - 61 - QSEE Execution, Delta
B - 875289 - SBL1, End
D - 595573 - SBL1, Delta
S - Flash Throughput, 25000 KB/s (2465934 Bytes, 96617 us)
S - DDR Frequency, 931 MHz
S - Core 0 Frequency, 800 MHz
device type 1 = 0x4
device type 2 = 0x0
device type 1 = 0x0
device type 2 = 0x0
device type 1 = 0x0
device type 2 = 0x0
device type 1 = 0x0
device type 2 = 0x0
Initialization_routine: Already F/G initialized(version:0x1)
device type 1 = 0x0
device type 2 = 0x0
BOOTLOADER VERSION : T713XXU1APG1
check_pit_integrity: invalid pit magic code.(0x0)
AST_POWERON
device type 1 = 0x0
device type 2 = 0x0
RUSTPROOF : Power on Status 0x0000002000000081
device type 1 = 0x0
device type 2 = 0x0
Gimme a second to decypher that.
---------- Post added at 08:38 AM ---------- Previous post was at 08:35 AM ----------
Hmm... This is very weird - I don't see anything abnormal in that kmsg, just booting.
Are you sure you attempted to boot, then rebooted recovery to get the log?
@ashyx?
Lightn1ng said:
Gimme a second to decypher that.
---------- Post added at 08:38 AM ---------- Previous post was at 08:35 AM ----------
Hmm... This is very weird - I don't see anything abnormal in that kmsg, just booting.
Are you sure you attempted to boot, then rebooted recovery to get the log?
@ashyx?
Click to expand...
Click to collapse
I'll do it again......And send you the log!
Sorry tried twice to paste it here but the
XDA system won't allow me to do it, "Too long", it's 512 kb!
Can I email it to you??
samteeee said:
Sorry tried twice to paste it here but the
XDA system won't allow me to do it, "Too long", it's 512 kb!
Can I email it to you??
Click to expand...
Click to collapse
Yes. Email to [email protected] please thanjs
Lightn1ng said:
Yes. Email to [email protected] please thanjs
Click to expand...
Click to collapse
Sent....
samteeee said:
Sent....
Click to expand...
Click to collapse
Received. Looking over it now.
This module is capable of building VERY large hosts files from multiple sources.
In my testing (and is actually my current live environment) I build a host file blocking 2.8 million hosts, from sources listing >4M hosts. Obviously some duplication between sources.
Requirements
Root
BusyBox
CURL - see post 2 for instruction on how to enable
Feature List
Builds from multiple host list sources. I am running >90
Allows whitelist
Supports HTTP, HTTPS as well as local FILE
Runs using multiple parallel threads. i.e. Multi-threaded. Defaults to 16 parallel threads, so while one is awaiting downloading, another would be parsed
In my testing, an older device built large hosts files not too much slower than that on a newer device
Supports mirrors
Fallbacks to previous good run
Multiple file source formats. ie host file with IP and/or simple domain lists even two formats within the same file
Can be run without Magisk
It is script based, so is open source
Configurable via a text file
Tries to clean up / correct some poorly formatted hosts files
Automaically enables / allows the host sources./. ie no need to explicitly include an allow list for the host sources
Automaticallly handles the removal of local hosts in the header from source block lists
Numerous reports on the results can be attained using my other development app with a UI called TeMeFI
You can manually run the build from TeMeFI or from a shell / adb
It defaults to building to the systemless host location of MAgisk, but can build to a RW direct location of /sytsem/etc/hosts
It runs at the LOWEST priority, thus minimal to no degradation of phone performance.
Redirects - text file
triues to minimise downloading files that have not changed
Does not rebuild the host file if the source host lists have not changed
Will force a re-download and host file rebuild if the host sources list has changed
Comments can be aadded to host source list without forcing a rebuild
Its not an app to install and does not run in the background, but a script that only runs on boot
Not Supported
Wildcards in whitelist
No UI, its all script and text files, however reports can be generated using TeMeFI
Install Instructions
Install CURL (see post 2)
Install the Magisk module from within Magisk, using the zip attached to this post
Enable the Magisk systemless host
Reboot twice. Once to finish the install, and the second top actually run the build of host file
MD5: C3464A3A594ECFE95EF87E6E0D324A62
Download: DiamondJohnHostManager_v2.1.zip
Busybox has WGet, and the script will dall back to WGet, but Wget has less featires and also a very well known bug, Dont expect this bug to be fixed too soon as it is even present in the desktop build of Linux!
So the solution is to install CUrl. Following the steps below will get you up and running by installing a MAgisk Module. Its called "Cross Compiled Binaries"
So to clarify the steps.
1. Download & Install "Cross Compiled Binaries" from the Magisk Repo
2. Reboot
3. Open a shell and get an su
4. Run "ccbins"
Spoiler: SCREEN OUTPUT
Code:
sunfish:/ $ su
sunfish:/ # ccbins
===============================
Cross Compiled Binaries v7.2(9)
by Zackptg5
===============================
BusyBox v1.31.1-osm0sis
/dev/a7Y7BvR/.magisk/modules/ccbins/busybox
===============================
Testing internet connection [/] - OK
Fetching available binaries
[|] - Done
Checking for mod updates
[\] - Ccbins is up to date
Checking for binary updates
[/] - Installing NCursesw v6.2
[-] - NCursesw has been installed!
[|] - Binaries are up to date
Checking for conflicting modules
[\] - No conflicting mods were found
===============================
Binary Installer ==============
===============================
Current install location: /system/bin
Auto-update binaries at launch: Enabled (recommended)
DOH Server: None
===============================
Choose option =================
===============================
0: Refresh CCbins (remove everything - start fresh)
1: General Information
2: Options/Settings
3: List all installed binaries
4: List all downloadable binaries
5: Remove binary
6: Install binary
7: Install dynamic linked binary
Type 'q' at any time to quit
-->
5. Select "Install a Binary" ie "--> 6"
Spoiler: SCREEN OUTPUT
Code:
--> 6
===============================
Install which binary? =========
===============================
Current install location: =====
/system/bin ===================
===============================
0: None, go back to main menu
1: Install all binaries listed below
2: Aria2 (v1.35.0)
3: Bash (v5.1.8)
4: Bc (v1.07.1)
5: Brotli (v1.0.9)
6: Coreutils (v8.32)
7: Cpio (v2.12)
8: Curl (v7.78.0)
9: Diffutils (v3.7)
10: Ed (v1.17)
11: Findutils (v4.8.0)
12: Gawk (v5.1.0)
13: Grep (v3.6)
14: Gzip (v1.10)
15: Htop (v3.0.5)
16: Iw (v5.9)
17: Keycheck (v1.0)
18: Nano (v5.8.0)
19: Nethogs (v0.8.6)
20: Openssl (v1.1.1.11)
21: Patch (v2.7.6)
22: Patchelf (v0.12)
23: Sed (v4.8)
24: Strace (v5.13)
25: Tar (v1.34)
26: Tcpdump (v4.99.1)
27: Vim (v8.2.3095)
28: Wavemon (v0.9.3)
29: Xmlstarlet (v1.0)
30: Xxd (v1.10)
31: Zip (v3.0)
32: Zsh (v5.8.0)
33: Zstd (v1.5.0)
-->
6. Install the selected one. "curl" in my case. ie "--> 8"
Spoiler: SCREEN OUTPUT
Code:
--> 8
Downloading Curl
[|] - Curl has been installed!
Reboot for changes to take effect
7. Reboot
8. open a shell, get su and curl is now available
Spoiler: CURL NOW AVAILABLE
Code:
sunfish:/ $ su
sunfish:/ # curl--help
/system/bin/sh: curl--help: inaccessible or not found
127|sunfish:/ # curl --help
Usage: curl [options...] <url>
-d, --data <data> HTTP POST data
-f, --fail Fail silently (no output at all) on HTTP errors
-h, --help <category> Get help for commands
-i, --include Include protocol response headers in the output
-o, --output <file> Write to file instead of stdout
-O, --remote-name Write output to a file named as the remote file
-s, --silent Silent mode
-T, --upload-file <file> Transfer local FILE to destination
-u, --user <user:password> Server user and password
-A, --user-agent <name> Send User-Agent <name> to server
-v, --verbose Make the operation more talkative
-V, --version Show version number and quit
This is not the full help, this menu is stripped into categories.
Use "--help category" to get an overview of all categories.
For all options use the manual or "--help all".
Some file Locations:
Your listt of Host Sources: /storage/emulated/0/Android/data/DiamondJophnDroidHostManager/host_sources.trxt
Each line is a different "row" which is a host source.
Lines Preceded with a "-" will be treated as an allow list, otherwise it will be treated as a deny list
Within each line, a mirror for the host sources is define by sepereating with a piping character ie "|"
A source can be https:// or http:// or file:// Note for a file source, the protocol has 2 slashes and then a third slash will be there for the path. Hence a file will have a tipple slash
Anything after the hash (#) will be ignored and treated as a comment
Empty lines will be ignored
MAKE SURE YOU USE A LINE-FEED and NOT a CARRIAGE RETURN & LINE-FEED to end each line. ie Android/Unix/Linux style, not windows style.
An example of each of the above:
Code:
https://dbl.oisd.nl
https://winhelp2002.mvps.org/hosts.txt|http://winhelp2002.mvps.org/hosts.txt|https://raw.githubusercontent.com/hectorm/hmirror/master/data/winhelp2002.mvps.org/list.txt|https://ssl-proxy.my-addr.org/myaddrproxy.php/http/winhelp2002.mvps.org/hosts.txt
file:///data/media/0/User/hosts/Deny/deny_coinblocker.txt
# Dead Host source
#https://raw.githubusercontent.com/Zelo72/hosts/main/big.txt
-file:///data/media/0/User/hosts/Allow/google_play_whitelist.txt
-file:///data/media/0/User/hosts/Allow/google_video_whitelist.txt
The config is stored at: /data/adb/modules/DiamondJophnDroidHostManager/bin/includes/shared_constants.sh
The logs will go to: /storage/emulated/0/Android/data/DiamondJophnDroidHostManager/logs/*
The history / previous run will go to: /storage/emulated/0/Android/data/DiamondJophnDroidHostManager/previous/*
reserved...
reserved...
Just to give you some context on performance. I have a Pixel 4A and the following is from the end of the log:
Code:
...snip...
download_hosts.sh - Start build final output host file at 2021-10-18 10:40:14.018
21 seconds - download_hosts.sh 91 files combined,
blocking 2,888,313 hosts from 5,172,803 total blocking hosts and 622 allowed hosts
with a file size of 87,246,214 bytes,
built using 79 historic hosts lists, of 91 total sources. at 2021-10-18 10:40:34.596
Resultant Hosts file copied to /data/adb/modules/hosts/system/etc/hosts at 2021-10-18 10:40:34.857
SAVE_PARAM >>> ROW= MIRROR=0 NAME=UNIQUE_BLOCKED_HOSTS VALUE=2888313 at 2021-10-18 10:40:34.905
SAVE_PARAM >>> ROW= MIRROR=0 NAME=BLOCKED_HOSTS VALUE=5172803 at 2021-10-18 10:40:34.952
SAVE_PARAM >>> ROW= MIRROR=0 NAME=ALLOWED_HOSTS VALUE=622 at 2021-10-18 10:40:34.999
SAVE_PARAM >>> ROW= MIRROR=0 NAME=SOURCE_COUNT VALUE=91 at 2021-10-18 10:40:35.050
SAVE_PARAM >>> ROW= MIRROR=0 NAME=HISTORIC_SOURCES VALUE=79 at 2021-10-18 10:40:35.090
SAVE_PARAM >>> ROW= MIRROR=0 NAME=FILE_SIZE VALUE=87246214 at 2021-10-18 10:40:35.126
SAVE_PARAM >>> ROW= MIRROR=0 NAME=ELAPSED_TIME VALUE=232 at 2021-10-18 10:40:35.166
ALL processed in 232 seconds at 2021-10-18 10:40:35.181
I also did some tests on an old 2013 Samsung S4, and it was around 300-400 seconds to build a similar 2.8M host file from 4.8M hosts.
Updated module. v2.1 Removed some debug code that made its way into the release.
Also note, the default host source list does not download 2.8M hosts. Its gets about 200K hosts, which are about 90+% unique.
Buena tarde:
Para agregar más fuentes de las que vienen, ¿qué sería modificar el archivo host_sources.txt?
Lo que no entiendo es que el complemento se descargue de magisk o .zip.
Saludos cordiales FELIZ NAVIDAD Y PRÓSPERO AÑO NUEVO.