I can't create custom vbmeta.img file because my files have different names and are missing - Android Q&A, Help & Troubleshooting

Hi, while trying to create a custom vbmeta.img file with avbtool with the instructions at https://www.hovatek.com/forum/thread-32664.html I noticed that most of the parts that should be in my vbmeta.img section are missing. What should I do?
The vbmeta.img file and its information are in the attachments.

Related

What are data.img system.img boot.img files

Someone please tell me some basic of data.img system.img boot.img files
their use
and how to edit them ?
Or post some links explaining these.
ip2op01 said:
Someone please tell me some basic of data.img system.img boot.img files
their use
and how to edit them ?
Or post some links explaining these.
Click to expand...
Click to collapse
http://stackoverflow.com/questions/3879717/what-is-purpose-of-using-system-img-in-android
http://en.wikipedia.org/wiki/Disk_image
http://en.wikipedia.org/wiki/Boot_image
these may help, or may not. But hopefully so, if not try looking around stackoverflow a bit more.
ip2op01 said:
Someone please tell me some basic of data.img system.img boot.img files
their use
and how to edit them ?
Or post some links explaining these.
Click to expand...
Click to collapse
1.
boot.img : be similar with bootstrap in the PC's BIOS,aim to boot the android OS;
data.img : this file includes some user data and system data;
system.img : this file includes some packages and some lib file.
ramdisk.img : emulator's FS(file system)
2.
when the android OS start, emulator loads those image file to ramdisk FS, create "system" file directory and "data" file directory.so you should think that those are android OS component.
3.
(1)unpack:
a. tool-------"unyaffs" download link : http://code.google.com/p/unyaffs/downloads/list
b. command------./unyaffs system.img
(2)pack:
a. tool-------"mkyaffs2image" location:android/out/host/linux-x86/bin or search internet
b. make this tool
c. command------ ./mkyaffs2image <directory> <out_file>
I know this, try myself
Thanks guys
ip2op01 said:
Thanks guys
Click to expand...
Click to collapse
My English is poor,it's my pleasure,you can understand it.
enyblock said:
1.
boot.img : be similar with bootstrap in the PC's BIOS,aim to boot the android OS;
data.img : this file includes some user data and system data;
system.img : this file includes some packages and some lib file.
ramdisk.img : emulator's FS(file system)
2.
when the android OS start, emulator loads those image file to ramdisk FS, create "system" file directory and "data" file directory.so you should think that those are android OS component.
3.
(1)unpack:
a. tool-------"unyaffs" download link : http://code.google.com/p/unyaffs/downloads/list
b. command------./unyaffs system.img
(2)pack:
a. tool-------"mkyaffs2image" location:android/out/host/linux-x86/bin or search internet
b. make this tool
c. command------ ./mkyaffs2image <directory> <out_file>
I know this, try myself
Click to expand...
Click to collapse
So, if I have a ROM with the .img file extension I should flash it as "System" (In TWRP)???

[TOOL][SHARE] Boot.img tools (unpack,repack,ramdisk)

Note: I'm just sharing the work of the XDA Member CNexus.Here's a little introduction by him :
CNexus said:
I have not seen this posted anywhere, so I thought I would post it here. This is NOT purely my work, and I do not take credit for it as such.
Included in the attached ZIP are the following files:
boot_info - prints information about the boot.img passed to it, including the base address and ramdisk address. This tool prints out everything needed to repack the boot.img correctly.
split_boot - More commonly known as split_bootimg.pl, this rips apart the boot.img to extract the ramdisk and zImage. It has been modified by me to split the boot.img into a separate folder (specified by the file name of the boot.img passed to it) and to extract the ramdisk into a sub-folder as well (extracts the cpio from the gz and then extracts the actual files from the cpio archive)
unpack_ramdisk - unpacks the given ramdisk file.
Code:
Usage: unpack_ramdisk
repack_ramdisk - repacks the ramdisk from the given directory (found online and modified slightly to take a directory)
Code:
Usage: repack_ramdisk [outputFile]
mkbootimg - mkbootimg binary that creates a boot.img file from the given ramdisk and zImage. Updated to a version compiled by me to support the --ramdiskaddr option (ramdisk address) so that even nonstandard boot.img's can be repacked correctly (Use with boot_info for best results).
umkbootimg - included for convenience. Not made by me. Original thread here.
unpack - wrapper script made by me for the umkbootimg binary^ to unpack the boot.img into a separate directory and then unpack the ramdisk into a sub-directory.
Note: These tools were made for Linux. They may also work on Cygwin, but I have not personally tested them.
ANYONE is free to use / modify / kang these files as they see fit. No need to ever ask or do anything more than download.
Enjoy.
Click to expand...
Click to collapse
Download the required files from the original thread.
Original Thread : http://forum.xda-developers.com/showthread.php?t=2319018
1+
Sent from my GT-S5360 using Tapatalk 2

Invalid Boot.img when trying to extract kernal and ramdisk.

A very warm Hi! to the XDA community
My phone, the Sony Xperia E4, does not have a recovery - so I am slowly learning how to develop one. It has an MT6582 chip.
In the process I have obtained the stock boot.img (via boot.sin) from the phone's stock .ftf firmaware file.
I wish to use MTK droid tools to create the recovery, however it first gave me the error that the boot.img file is not split. After some research I came to learn that such boot.img files need to be split into the kernal (Zimage i believe) and ramdisk.
After some further research I came across this seemingly helpful guide and tool on how to split the boot.img file on Windows (unfortunately I do not have Linux at my disposal atm).
Now to my issue: (referring to the aforementioned guide & tool) When running the command
Code:
bootimg.exe --unpack-bootimg boot.img
I get this error:
Code:
AssertionError: invald bootimg
Which leads me to believe the boot.img file I have extracted may be corrupt or extracted from the wrong .sin file.
If you are still with me, how can i confirm that the boot.img file from the stock rom is indeed "working" and contains ramdisk and kernal?
Some extra information:
This is the guide I used to initially extract the boot.img file from my phones stock firmware. They highlight that boot.img is extracted from the kernal.sin file. My firmware has no such file. Later in the comments it mentions that newer Sony phones have the boot.img file in the appropriately named "boot.sin" file. This is the file i used to extract my boot.img. Thus from here I cannot see why the boot.img file cannot be split.
The full command line and response is:
Code:
C:\Users\\Downloads\Cofface>bootimg.exe --unpack-bootimg boot.img
arguments: [bootimg file]
bootimg file: boot.img
output: kernel[.gz] ramdisk[.gz] second[.gz]
Traceback (most recent call last):
File "<string>", line 2213, in <module>
File "<string>", line 1424, in unpack_bootimg
File "<string>", line 151, in parse_bootimg
AssertionError: invald bootimg
Thanks very much in advance!

Unpacking and Repacking problem

Hoping someone can help me. Using the stock OS for a motorola moto G(3rd gen) and the windows command prompt, I can flash install system.img_sparsechunk.# files succesfully and the phone works great. However, I want to slim down this OS and remove some of the bloatware.
So, I unpacked system.img_sparsechunk.#'s into a system.img file using 'sparse converter.exe'. Then further decompressed it into folders and files using 'img extractor.exe'. Removed a few unimportant apps from the app folder and then made it back into a system.img file using 'make_ext4fs.exe & cygwin1.dll' which I got from the MTK Thai Developers Tool Unpack Repack package. Finally, I convert system.img into system.img_sparsechunk# files with 'sparse converter.exe' and I flashed to the moto G. This is unsuccessful. The phone is never gets past the bootloader unlocked screen and eventually goes to recovery. Is there something I'm doing wrong along the way in my unpack and repack?
These are the files from the stock OS:
boot.img
bootloader.img
flashfile.xml
fsg.mbn
gpt.bin
logo.bin
NON-HLOS.bin
OSPREY_RETUS_6.0_MPI24.65-25.1_cid9_subsidy-DEFAULT_CFC.info.txt
recovery.img
servicefile.xml
slcf_rev_b_default_v1.0.nvm
system.img
system.img_sparsechunk.0
system.img_sparsechunk.1
system.img_sparsechunk.2
system.img_sparsechunk.3
system.img_sparsechunk.4
system.img_sparsechunk.5
system.img_sparsechunk.6
Here are my steps more detailed:
1. sparseConverter_1.0.1 /decompress system.img_sparsechunk.0 system.img
A. This creates system.img
2. imgExtractor.exe system.img systemUnpack
A. This unpacks to files and folders
3. Modify files within 'systemUnpack' folder
4. make_ext4fs.exe -l 1200M system.img g:\rootAndroidMotoG3\osModXT1540\systemUnpack
A. Determine the size of the 'systemUnpack' folder. Round up to the nearest 100 Mb and substitute this
number for 1200.
B. This makes system.img
5. sparseConverter_1.0.1 /compress system.img . 256MB
A. This makes system.img_sparsechunk files
6. Enter bootloader mode on the MotoG.
7. Type: 'c:\adb\fastboot flash system system.img_sparsechunk1'. Type this for all of the system.img_sparsechunk#'s
Thanks
ACFH said:
I think you need put "-a system" in make_ext4fs command. Read this:
https://forum.xda-developers.com/ge...packing-editing-packing-roms-img-dat-t3350261
Click to expand...
Click to collapse
Thanks, it worked.

Extract system.img,vendor.img and product.img from super.img

After lots of search i found a way to extract those img file from super.img
What is need?
1.Computer with linux os.
extract zip file from this post and place your super.img in same location where you extract..
then run below cmd...
simg2img super.img super.img.raw
To extract system.img run below cmd
./lpunpack --partition=system super.img.raw
To extract vendor.img run below cmd
./lpunpack --partition=vendor super.img.raw
To extract product.img run below cmd
./lpunpack --partition=product super.img.raw
Shas45558 said:
After lots of search i found a way to extract those img file from super.img
Click to expand...
Click to collapse
It is better to let other also know where you have found this. https://github.com/AndroidDumps/Fir...20a9a111b44f79da89b8/tools/Linux/bin/lpunpack from https://github.com/AndroidDumps/Firmware_extractor
HemanthJabalpuri said:
It is better to let other also know where you have found this. https://github.com/AndroidDumps/Fir...20a9a111b44f79da89b8/tools/Linux/bin/lpunpack from https://github.com/AndroidDumps/Firmware_extractor
Click to expand...
Click to collapse
Tnx for suggestions....and right i found it from those source.i want to simplify the hole process....
Shas45558 said:
After lots of search i found a way to extract those img file from super.img
What is need?
1.Computer with linux os.
extract zip file from this post and place your super.img in same location where you extract..
then run below cmd...
simg2img super.img super.img.raw
To extract system.img run below cmd
./lpunpack --partition=system super.img.raw
To extract vendor.img run below cmd
./lpunpack --partition=vendor super.img.raw
To extract product.img run below cmd
./lpunpack --partition=product super.img.raw
Click to expand...
Click to collapse
how to repack after modeficatiom
mohacraft8 said:
how to repack after modeficatiom
Click to expand...
Click to collapse
Sorry i do not know...
But you can flash then via fastbootd mood..
Remember do not use fastbootd if you are custom recovery...it must brick your device...
So flash stock recovery..go fastbootd mood and flash system, vendor and product..
Tnx for understanding.
mohacraft8 said:
how to repack after modeficatiom
Click to expand...
Click to collapse
You have to use lpmake for it.
See https://forum.xda-developers.com/t/gsis-on-a51-5g.4114349/ and https://forum.xda-developers.com/t/script-android-10-universal-mount-system-read-write-r-w.4247311/ for more info.
.......
Bro can we get modem.img by this
So let say if we flashing super.img , does it automatically flashed product.img ? or need to manually flash the product.img ?

Categories

Resources