TWRP: File is bigger then Target device - Honor 5X Questions & Answers

Some how it double posted im sorry.

Related

extracting kernel from boot.img from Sony Ericsson X10

hey XDA here i'm again,
i need some help with extracting the kernel from boot.img
i already got system.img and boot.img, i also can covert more files, but i don't think thats a high priority rightnow.
check this mediafire map for the files(system.img and boot.img):
http://www.mediafire.com/?myyeyniydzh
Check the attachment for the "kernel-extract.pl"
this is the error i get when i try to extract the kernel from boot.img:
Code:
[[email protected] phone]# perl extract-kernel.pl boot.img
substr outside of string at extract-kernel.pl line 23.
Use of uninitialized value $kernel in print at extract-kernel.pl line 27.
the first line is the command i used to execute the perlscript on the boot.img
can someone help me with this little problem?
Odd. I assume the script is correct - I've not bothered to compare it to a verified one. So for you it slurps in the image, but two values in the header imply the kernel is in an illogical location within. Is the image file valid? I'd check it's md5sum. Also maybe get the script to dump the header values it reads in lines 20-21.
[Edit] Of course the other explanation is that the X10 boot.img doesn't have the standard format, but why Sony would do that I don't know.
[Edit2] A quick comparison of the headers to the img you uploaded against a recent back up of my Hero's current ROM's boot.img, cross-checked against the script to see if values seem plausible, suggests your image is faulty or the X10 uses a different data structure.
cauli said:
[Edit2] A quick comparison of the headers to the img you uploaded against a recent back up of my Hero's current ROM's boot.img, cross-checked against the script to see if values seem plausible, suggests your image is faulty or the X10 uses a different data structure.
Click to expand...
Click to collapse
hmm... well i think the data structure is different then, because i used an decrypted version from the X10 forums..
it was the only version that was there, so it was the only file i could even use..

help with recovery

an anyone tell me what im doing wrong
I download the zip file and unzipped it to the C drive
The image files name is recovery-en-goapk
I have placed it inside C\android-sdk-windows\tools
then i type the following code
C:\Users\Mike>cd C:\android-sdk-windows\tools
then
C:\android-sdk-windows\tools>fastboot flash recovery C:\recovery-en-go-apk
then i get: error cannot load 'C:\recovery-en-goapk
http://forum.xda-developers.com/showthread.php?t=1138541
Make sure the recovery file is in the same directory as your fastboot.exe if using windows. The same goes for the moto-fastboot if using that one.
jra89027 said:
an anyone tell me what im doing wrong
I download the zip file and unzipped it to the C drive
The image files name is recovery-en-goapk
I have placed it inside C\android-sdk-windows\tools
then i type the following code
C:\Users\Mike>cd C:\android-sdk-windows\tools
then
C:\android-sdk-windows\tools>fastboot flash recovery C:\recovery-en-go-apk
then i get: error cannot load 'C:\recovery-en-goapk
Click to expand...
Click to collapse
SGTShark said:
http://forum.xda-developers.com/showthread.php?t=1138541
Make sure the recovery file is in the same directory as your fastboot.exe if using windows. The same goes for the moto-fastboot if using that one.
Click to expand...
Click to collapse
if you placed the recovery-en-go-apk file INSIDE the tools directory why would you be trying to point it to the root of C:\ ????
lets make a small attempt at logic. i damn sure would not be doing this to my device if i wasnt sure of the path of the file......

[SOLVED] Build/development question - CM13 - missing ROM ZIP but imgs are built

I pulled the CM13 source from github and successfully completed a build. Set up all the tools, got the right java version set up, then did the actual build (envsetup, breakfast surnia, then used make) which took a few hours to complete.
However, I cannot seem to find the ZIP file which contains the flashable ROM. My build works well when I fastboot flash things (recovery, boot, cache and system). But I really would like to get a ZIP version of the ROM which can be ADB sideloaded.
I searched around and most of the posts I see related to this kind of stuff are old posts, and all of them indicate that the ZIP file will be created with the build. Is this not the case anymore? If not, can anyone help point me in the direction of how to make proper flashable zip created from a set of properly built .img files?
Asked too soon. Found how to get the zip file - ran "brunch surnia" instead of breakfast and a manual make, and now the ZIP file is generated.
You should try
make otapackage
Command instead of make surnia

How to remove unlocked bootloader warning for almost every Samsung devices.

Bootloader warning ⚠​Have you recently unlock your bootloader and want to remove Warning Bootloader Unlock message that comes every time when your device is starting up? Then not worry this article is for you. This tutorial gives you the detail view of How to remove Warning Bootloader Unlocked message from your android devices.
What you need?​
Your device.
Terminal (termux recommended).
Magisk patched recvory (you just need root for one time).
Steps to follow to fix Bootloader Unlocked Warning issue :​
Download the Param file and move it to download folder (internal storage).
Download terminal (you can use termux).
Start terminal and gain root access using "su".
Type / copy this command into the terminal -
Code:
dd if=/storage/emulated/0/Download/up_param.tar of=/dev/block/platform/13520000.ufs/by-name/up_param
Now simply reboot to recovery or system.
Mission accomplished.
Download​(in this case the param file is only for Samsung Galaxy M30s, if you want it for your device message me on telegram or comment below)​Splash screens for other devices :
Galaxy Tab S6 lite​
Galaxy A12​
Galaxy A22
Galaxy Tab A7 Lite
If you want it for your device comment below..​
​Conclusion :​In this post I have talked about How to remove bootloader warning. Tell us What You Say About The Post by commenting and if you have any questions then comment below.
Reference : Razs Originals!
Reserved..
Hello i cant found this folder in galaxy Tab s7+
avsozi said:
Hello i cant found this folder in galaxy Tab s7+
Click to expand...
Click to collapse
1. Make folder on your desktop and Open 2 command line programme windows in that directory.
2. choose one window and run this commands
adb shell
su
dd if=/dev/block/platform/13540000.dwmmc0/by-name/PARAM of=/sdcard/PARAM.bin bs=4096
if you failed, report me I'll send you another way
3. goto second command line window and run
adb pull /sdcard/PARAM.bin
Or simply just use a root explorer, grant root permissions and navigate to root directory then find dev folder and search for the up_param file.
razs.originals said:
Bootloader warning ⚠​Have you recently unlock your bootloader and want to remove Warning Bootloader Unlock message that comes every time when your device is starting up? Then not worry this article is for you. This tutorial gives you the detail view of How to remove Warning Bootloader Unlocked message from your andriod devices.
What you need?​
Your device.
Terminal (termux recommended).
Magisk patched recvory (you just need root for one time).
Steps to follow to fix Bootloader Unlocked Warning issue :​
Download the Param file and move it to download folder (internal storage).
Download terminal (you can use termux).
Start terminal and gain root access using "su".
Type / copy this command into the terminal -
Code:
dd if=/storage/emulated/0/Download/up_param.tar of=/dev/block/platform/13520000.ufs/by-name/up_param
Now simply reboot to recovery or system.
Mission accomplished.
Download​(in this case the param file is only for Samsung Galaxy M30s, if you want it for your device message me on telegram or comment below)​Splash screens for other devices :
Galaxy Tab S6 lite​
Galaxy A12​
If you want it for your device comment below..​
​Conclusion :​In this post I have talked about How to remove bootloader warning. Tell us What You Say About The Post by commenting and if you have any questions then comment below.
Reference : Razs Originals!
Click to expand...
Click to collapse
Hi, can you make a splash screen for the A22? I'm bad at using Photoshop to make my own. Thanks in advance
avsozi said:
Hello i cant found this folder in galaxy Tab s7+
Click to expand...
Click to collapse
It should be at /dev/block/by-name/up_param (sometimes it's param instead of up_param)
This should be a general directory for things like the boot and recovery. The directory OP provided is specific to each device as far as I know.
Platypus Enthusiast said:
Hi, can you make a splash screen for the A22? I'm bad at using Photoshop to make my own. Thanks in advance
Click to expand...
Click to collapse
Yea sure message me on Telegram
Razs Originals!
Razs Originals! | more at @razs_redirect
t.me
Platypus Enthusiast said:
It should be at /dev/block/by-name/up_param (sometimes it's param instead of up_param)
This should be a general directory for things like the boot and recovery. The directory OP provided is specific to each device as far as I know.
Click to expand...
Click to collapse
Yes that's the right path
razs.originals said:
Yea sure message me on Telegram
Razs Originals!
Razs Originals! | more at @razs_redirect
t.me
Click to expand...
Click to collapse
Should have sent this yesterday, but I couldn't sign up to Telegram because I don't have a phone number (anymore).
Platypus Enthusiast said:
Should have sent this yesterday, but I couldn't sign up to Telegram because I don't have a phone number (anymore).
Click to expand...
Click to collapse
Oh okay then I'll download the firmware
Hi, I'm using A70, which has a Snapdragon chip, I did notice the devices you mentioned has Exynos/MTK. Can it work on SD?
I did pull param (there's no up_param), but I have no idea what to do to patch it (you did not complete your tutorial at #4 comment). So should I upload it or something?
Mohamedkam000 said:
Hi, I'm using A70, which has a Snapdragon chip, I did notice the devices you mentioned has Exynos/MTK. Can it work on SD?
I did pull param (there's no up_param), but I have no idea what to do to patch it (you did not complete your tutorial at #4 comment). So should I upload it or something?
Click to expand...
Click to collapse
Extract it using a tool for opening archives (WinRAR, 7Zip, etc.), you will end up with a bunch of picture files. Edit these using a program like PhotoShop and repack the files into one archive, make sure you did not change the dimensions and that there are no folders inside. Opening the repacked archive should show the pictures directly and not having to open a folder inside the archive. Use dd or Odin to replace the existing param. If you're using Odin, ensure it is named exactly what partition you're replacing inside the archive or it will end up with the "Unassigned file" error.
As an experiment, I filled the boot_warning.jpg black and the svb_orange.jpg was replaced by a copy of logo.jpg but resized to the dimensions of the originally svb_orange (1800x936). I only get a black screen at boot with the words vbmeta and boot in the top left corner, and skips to logo.jpg without anything between (still booted fine, though). No idea what went wrong.
Mohamedkam000 said:
Hi, I'm using A70, which has a Snapdragon chip, I did notice the devices you mentioned has Exynos/MTK. Can it work on SD?
I did pull param (there's no up_param), but I have no idea what to do to patch it (you did not complete your tutorial at #4 comment). So should I upload it or something?
Click to expand...
Click to collapse
Unfortunately I don't think there's a way to remove the bootloader waring in snapdragon devices.
Platypus Enthusiast said:
As an experiment, I filled the boot_warning.jpg black and the svb_orange.jpg was replaced by a copy of logo.jpg but resized to the dimensions of the originally svb_orange (1800x936). I only get a black screen at boot with the words vbmeta and boot in the top left corner, and skips to logo.jpg without anything between (still booted fine, though). No idea what went wrong.
Click to expand...
Click to collapse
Send me your param file I'll edit it
razs.originals said:
Send me your param file I'll edit it
Click to expand...
Click to collapse
Okay got it will send you the edited param in some time
I have a galaxy tab a 2019 model (sm-t510). Would someone able to alter the param file for mine and let me know which one to use? Thanks!
Hey can you help me out with tab a7 lite it Would be helpful thanks

How To Guide Automated GSI build script (Linux/WSL)

I've spent last day automating the guide at https://forum.xda-developers.com/t/guide-t220-t225-flash-a-gsi-on-the-a7-lite-without-twrp.4456821/ into a bash script (linux only)!
Here it is releasing it for anyone that needs it
Code:
I am not responsible whatever happens to your device
by using this script, i have tested it on my own device
and it worked but it may or may not work for you.
I will do my best to help you but that may be limited
as i have other responsibilities in life
Before starting read the third post
Usage​Download the your desired firmware from somewhere like samfw.com and extract it
Download your desired GSI image and extract it
Download otatools-mini, gsi-build script and vbmeta image, place them all together inside one directory (extract the otatools-mini next to the script)
Download patched odin
Run this in Linux or WSL!
Code:
$ ./build-gsi.sh <PATH TO YOUR AP FILE .tar.md5> <PATH TO GSI .img>
And let it do the work, may take a while depending on your PC
You may get something like this in the process, ignore it
Code:
Invalid sparse file format at header magic
Then go into download mode (VOLUME UP and DOWN when plugging in USB) and flash the CUSTOM_AP file you got from the script and BL, CSC from the firmware you used, DO NOT USE HOME_CSC
Reboot into recovery and factory reset (VOLUME UP while booting)!
If you are getting dm-verify error then flash the vbmeta_disabled_R (it needs to be .tar, extract it) in odin as AP and try rebooting again into recovery
Downloads​I used to provide one archive but it was large and i couldnt change the script without reuploading it so i am going to use gist for the script and provide other files separately
ota-tools-mini
build-gsi.sh
Getting Help​If you want me to help you ALWAYS post full output from the script, and make sure to use the latest script from the gist
I've spent a lot of time trying to make it work with all GSIs but i could not get it to work consistently
By default it works for all smaller GSIs, if you get the following error
Code:
ERROR: Output image is bigger than original super image, rerun the script with correct super image size
Then you will have to manually provide the new super size which i cannot help you with try to guess but it has to be divisible by 512
Not enough free space to expand partition: vendor
error while repacking
i have a lot of space . but it shows me like that
lpmake E 01-15 23:22:16 100 100 builder.cpp:698] [liblp]Not enough free space to expand partition: vendor
i am using debian wsl
Please post full script log in a spoiler or pastebin
sandorex said:
Please post full script log in a spoiler or pastebin
Click to expand...
Click to collapse
Could you try normal AP file not the magisk patched, i do not know how it modifies it
Also from my experience you do not need to patch whole AP file for magisk, you just need to patch the boot.img, zip it then flash it
OK . i will try
i tried with original ap file but same error
dxsyrz said:
i tried with original ap file but same error
Click to expand...
Click to collapse
It seems for some reason your gsi is too big, i managed to reproduce it, ill see if i can fix it
@dxsyrz can you test this one, it should work now
EDIT: i've updated the gist so you can just use that instead
good util but test more.
tom.android said:
good util but test more.
Click to expand...
Click to collapse
It worked for me, i would not release it if it did not work
sandorex said:
It worked for me, i would not release it if it did not work
Click to expand...
Click to collapse
OK sorry to write that message.
sandorex said:
It worked for me, i would not release it if it did not work
Click to expand...
Click to collapse
Well, something did not work in my case:
:: Uncompressing super image
super.img.lz4 : decoded 5637366988 bytes
:: Running simg2img
./build-gsi.sh: line 79: /mnt/c/Users/Zero/Desktop/otatools-mini/otatools-mini/simg2img: No such file or directory
^ Despite the files actually existing. You tell me cuz I've no idea (do note I do know how to do this manually, was just trying your script to simplify everything).
nirogu325 said:
Well, something did not work in my case:
:: Uncompressing super image
super.img.lz4 : decoded 5637366988 bytes
:: Running simg2img
./build-gsi.sh: line 79: /mnt/c/Users/Zero/Desktop/otatools-mini/otatools-mini/simg2img: No such file or directory
^ Despite the files actually existing. You tell me cuz I've no idea (do note I do know how to do this manually, was just trying your script to simplify everything).
Click to expand...
Click to collapse
You need to place otatools-mini in folder next to the script not together with the script
hi i have this problem
izimen said:
hi i have this problem
View attachment 5814501
Click to expand...
Click to collapse
You havs a space in your path, its actually a bug but you can jist move the files to somewhere without spaces
EDIT: Fixed it on gist
sandorex said:
You havs a space in your path, its actually a bug but you can jist move the files to somewhere without spaces
EDIT: Fixed it on gist
Click to expand...
Click to collapse
ok i try
bro it worked thank you I managed to make it work with a GSI and when I try with another I have this error

Categories

Resources