[Q] Deeper Firmware information (partitions, SIN-Files, Fastboot) - Xperia Z Q&A, Help & Troubleshooting

Hi @all,
I have some questions regarding the Firmware.
I have searched for answers to my questions but I haven´t found any...
I´m still learning so excuse also some "stupid" questions...
1. Fastboot
With fastboot (if BL is open) it is possible to send files to the phone.
"fastboot flash boot kernel.sin"
"fastboot flash system system.sin"
Normally this is working fine.
But on the Xperia Z I get an error, that the system.sin file is to large. Anyone noticed this also? (The same file converted as a flashable zip File is working in CWM)
2. SIN-Files
What is with the other .sin files which are in the usual FTF-File? How to flash them?
There are fotakernel.sin, amss_fs_1.sin, amss_fs_2.sin, amss_fs_3.sin, rpm.sin, partition-image.sin, loader.sin and (in my case for the Xperia Z French FW) elabel-c6603-row_201302121303_10.1.A.1.350.sin which seem to be interesting!?
The other files like userdata.sin, cache.sin apps_log.sin and simlock.ta seems for me are not so relevant.
Aren´t they necessary? I have also noticed this on CWM where only the system.sin is flashed and not the other .sin files. Why?
I have checked the partitions in the shell with "df" and there are only
/dev
/mnt/asec
/mnt/obb
/system
/data
/cache
/lta-label
/mnt-qcks
/data/idd
/storage/sdcard0
/storage/sdcard1
Click to expand...
Click to collapse
Is this the reason why we do not know where to flash the other .sin Files because there are no partitions where to put them in?
So in this case it should be possible to flash userdata and cache (but this is unnecessary) because this data are created while using the phone!?

Related

[ROM] CyanogenMod 10.1 - JellyBean 4.2.1 -NIGHTLY

UPDATE 18-01-2013: new gapps
Based on dreamcwli's gapps.
gapps-minimal-jb-20130115-signed.zip
------------------------------------------
UPDATE: As you may have noticed, since yesterday we have nightly builds for the p3 at get.cm/?device=p3.
------------------------------------------
Get your update from there. You will still need to install the minimal gapps posted below. Also, still read pershoot's latest post on his blog.
To flash the first one:
fastboot erase system
fastboot flash recovery recovery.img
fastboot boot recovery.img
flash rom
flash minimal gapps
After that, you can use CM's built in update function.
Thanks pershoot for getting this up so quickly!
------------------------------------------
pershoot has built CM 10.1 for the p3:
I won't copy any information about the ROM here, everything you need to know you can find on his blog:
http://droidbasement.com/db-blog/
Gapps:
gapps-minimal-jb-20130115-signed.zip
There are some serious space issues on the system partition of the p3, that's why I created a minimal gapps version especially for our tablet.
They are taken from the 20130115 gapps from dreamcwli and are very bare. You'll need to install Google Search, Gmail, Calendar and all the rest from the Play Store
Send thanks to pershoot for supporting our tablet!
That is a Bad information man since the second test build u can use the normal gapps
http://goo.im/gapps/gapps-jb-20121212-signed.zip
The Rom is over 20 MB smaller everything fits now
Gesendet von meinem HTC One X mit Tapatalk 2
feraay said:
That is a Bad information man since the second test build u can use the normal gapps
http://goo.im/gapps/gapps-jb-20121212-signed.zip
The Rom is over 20 MB smaller everything fits now
Gesendet von meinem HTC One X mit Tapatalk 2
Click to expand...
Click to collapse
That is not true. To proof my point: right after you flash it in recovery, first the ROM and then the full gapps, check out /tmp/recovery.log . you'll see that the script has errors that there is not enough space to unpack and copy all the files. Further, mount /system and do a df -h /system. You will see that you have only around 4k left. I know it appears as if it had enough space but it doesn't. I've spent quite a lot of time together with pershoot to get this right.
After flashing the ROM, you have about 38 MB left. The full gapps are around 100MB unpacked. That obviously doesn't fit.
Ok but i have no probs arround here everything works fine
U know what i mean
I belive u but it is making no problems
Gesendet von meinem HTC One X mit Tapatalk 2
ramonams said:
That is not true. To proof my point: right after you flash it in recovery, first the ROM and then the full gapps, check out /tmp/recovery.log . you'll see that the script has errors that there is not enough space to unpack and copy all the files. Further, mount /system and do a df -h /system. You will see that you have only around 4k left. I know it appears as if it had enough space but it doesn't. I've spent quite a lot of time together with pershoot to get this right.
After flashing the ROM, you have about 38 MB left. The full gapps are around 100MB unpacked. That obviously doesn't fit.
Click to expand...
Click to collapse
Could you help me to get my errors resolved (see below)? I have installed from stockrom. Cleared dalvik cache and wiped everything else. Also flashed galaxy wipe.zip. I installed the rom zip and the directly after installed mini gapps. Should I remove the rom zip and everything else from the sdcard before continuing flashing gapps?
-- Installing: /sdcard/Download/gapps-minimal-jb-20121212-signed.zip
Finding update package...
I:Update location: /sdcard/Download/gapps-minimal-jb-20121212-signed.zip
I:using /data/media for /sdcard/Download/gapps-minimal-jb-20121212-signed.zip.
Opening update package...
Installing update...
***********************************************about to run program [/sbin/busybox] with 3 args
minzip: Extracted file "/system/addon.d/70-gapps.sh"
minzip: Extracted file "/system/app/ChromeBookmarksSyncAdapter.apk"
minzip: Extracted file "/system/app/GmsCore.apk"
minzip: Extracted file "/system/app/GoogleBackupTransport.apk"
minzip: Extracted file "/system/app/GoogleContactsSyncAdapter.apk"
minzip: Extracted file "/system/app/GoogleFeedback.apk"
minzip: Extracted file "/system/app/GoogleLoginService.apk"
minzip: Extracted file "/system/app/GooglePartnerSetup.apk"
Minimal Google Apps for Android 4.2.1 minzip: Extracted file "/system/app/GoogleServicesFramework.apk"
minzip: Extracted file "/system/app/MediaUploader.apk"
minzip: Extracted file "/system/app/NetworkLocation.apk"
minzip: Extracted file "/system/app/OneTimeInitializer.apk"
***********************************************
Mounting system...minzip: Extracted file "/system/app/Phonesky.apk"
minzip: Extracted file "/system/app/SetupWizard.apk"
minzip: Extracted file "/system/app/Talk.apk"
roid.maps.xml"
minzip: Extracted file "/system/etc/permissions/com.google.android.media.effects.xml"
minzip: Extracted file "/system/etc/permissions/com.google.widevine.software.drm.xml"
minzip: Extracted file "/system/etc/permissions/features.xml"
minzip: Extracted file "/system/framework/com.google.android.maps.jar"
minzip: Extracted file "/system/framework/com.google.android.media.effects.jar"
Copying files...minzip: Extracted file "/system/framework/com.google.widevine.software.drm.jar"
minzip: Extracted file "/system/lib/libfilterpack_facedetect.so"
minzip: Error writing 24576 bytes from zip file from 0xbeaf1bc4: No space left on device
minzip: Process function elected to fail (in inflate)
minzip: Can't extract entry to file.
minzip: Error extracting "/system/lib/libgcomm_jni.so"
about to run program [/sbin/busybox] with 3 args
Fixing Permissions...
Unmounting system...
script result was [Installation complete!]
Installation complete!
Install from sdcard complete.
pinibo said:
Could you help me to get my errors resolved (see below)? I have installed from stockrom. Cleared dalvik cache and wiped everything else. Also flashed galaxy wipe.zip. I installed the rom zip and the directly after installed mini gapps. Should I remove the rom zip and everything else from the sdcard before continuing flashing gapps?
-- Installing: /sdcard/Download/gapps-minimal-jb-20121212-signed.zip
Finding update package...
I:Update location: /sdcard/Download/gapps-minimal-jb-20121212-signed.zip
I:using /data/media for /sdcard/Download/gapps-minimal-jb-20121212-signed.zip.
Opening update package...
Installing update...
***********************************************about to run program [/sbin/busybox] with 3 args
minzip: Extracted file "/system/addon.d/70-gapps.sh"
minzip: Extracted file "/system/app/ChromeBookmarksSyncAdapter.apk"
minzip: Extracted file "/system/app/GmsCore.apk"
minzip: Extracted file "/system/app/GoogleBackupTransport.apk"
minzip: Extracted file "/system/app/GoogleContactsSyncAdapter.apk"
minzip: Extracted file "/system/app/GoogleFeedback.apk"
minzip: Extracted file "/system/app/GoogleLoginService.apk"
minzip: Extracted file "/system/app/GooglePartnerSetup.apk"
Minimal Google Apps for Android 4.2.1 minzip: Extracted file "/system/app/GoogleServicesFramework.apk"
minzip: Extracted file "/system/app/MediaUploader.apk"
minzip: Extracted file "/system/app/NetworkLocation.apk"
minzip: Extracted file "/system/app/OneTimeInitializer.apk"
***********************************************
Mounting system...minzip: Extracted file "/system/app/Phonesky.apk"
minzip: Extracted file "/system/app/SetupWizard.apk"
minzip: Extracted file "/system/app/Talk.apk"
roid.maps.xml"
minzip: Extracted file "/system/etc/permissions/com.google.android.media.effects.xml"
minzip: Extracted file "/system/etc/permissions/com.google.widevine.software.drm.xml"
minzip: Extracted file "/system/etc/permissions/features.xml"
minzip: Extracted file "/system/framework/com.google.android.maps.jar"
minzip: Extracted file "/system/framework/com.google.android.media.effects.jar"
Copying files...minzip: Extracted file "/system/framework/com.google.widevine.software.drm.jar"
minzip: Extracted file "/system/lib/libfilterpack_facedetect.so"
minzip: Error writing 24576 bytes from zip file from 0xbeaf1bc4: No space left on device
minzip: Process function elected to fail (in inflate)
minzip: Can't extract entry to file.
minzip: Error extracting "/system/lib/libgcomm_jni.so"
about to run program [/sbin/busybox] with 3 args
Fixing Permissions...
Unmounting system...
script result was [Installation complete!]
Installation complete!
Install from sdcard complete.
Click to expand...
Click to collapse
The amount of files you have on your sdcard doesn't have any influence on the success when flashing. do this:
- Put your tab in fastboot mode
- "fastboot erase system"
- "fastboot boot path/to/recovery.img"
- Flash the ROM
- in the recovery, go to mounts and storage and mount /system
- "adb shell"
- "df -h /system" and record what the output is
- unmount /system
- Flash the gapps
- in the recovery, go to mounts and storage and mount /system
- "adb shell"
- "df -h /system" and record what the output is
and check recovery.log again
basically, this should work like this and you should be left with about 1 MB on /system
Let me know how it goes.
EDIT: just to be sure, redownload the minimal gapps again. I put up another zip as I realised the first one wasn't the one I wanted there.
ramonams said:
The amount of files you have on your sdcard doesn't have any influence on the success when flashing. do this:
- Put your tab in fastboot mode
- "fastboot erase system"
- "fastboot boot path/to/recovery.img"
- Flash the ROM
- in the recovery, go to mounts and storage and mount /system
- "adb shell"
- "df -h /system" and record what the output is
- unmount /system
- Flash the gapps
- in the recovery, go to mounts and storage and mount /system
- "adb shell"
- "df -h /system" and record what the output is
and check recovery.log again
basically, this should work like this and you should be left with about 1 MB on /system
Let me know how it goes.
EDIT: just to be sure, redownload the minimal gapps again. I put up another zip as I realised the first one wasn't the one I wanted there.
Click to expand...
Click to collapse
After the fifth step (mount /system) you say to run adb shell. I assume this is only possible after leaving recovery and rebooting again. Correct?
Do I need to clear caches and execute all wipes?
pinibo said:
After the fifth step (mount /system) you say to run adb shell. I assume this is only possible after leaving recovery and rebooting again. Correct?
Do I need to clear caches and execute all wipes?
Click to expand...
Click to collapse
You don't need to leave recovery and reboot, actually, if you're still in the shell, you don't need to do that again, i just copy pasted. just don't be in the system directory and better unmount system in between flashing, otherwise the gapps flashing script will give an error that the partition is busy.
Why not use the 'format /system' option in CWM before flashing rom & gapps?
The ROM is great.
feraay said:
That is a Bad information man since the second test build u can use the normal gapps
http://goo.im/gapps/gapps-jb-20121212-signed.zip
The Rom is over 20 MB smaller everything fits now
Gesendet von meinem HTC One X mit Tapatalk 2
Click to expand...
Click to collapse
no, you cannot.
this will not work.
'your' rom is 20MB smaller when installed + normal gapps, because you've symlinked content on to /data to make room and/or youve deleted a massive amount of system content. that, or you have a special p3 with more system space then the others i've seen.
the builds from droidbasement or when is published to nightly status, require minimal gapps (above), if you use gapps.
pinibo said:
Could you help me to get my errors resolved (see below)? I have installed from stockrom. Cleared dalvik cache and wiped everything else. Also flashed galaxy wipe.zip. I installed the rom zip and the directly after installed mini gapps. Should I remove the rom zip and everything else from the sdcard before continuing flashing gapps?
Click to expand...
Click to collapse
you did not read droidbasement on installation instructions.
flash p4's modem via odin.
flash cwm 6.0.2.5.
fastboot erase system
fastboot boot CWM
flash unofficial 12/28 rom, flash minimal gapps (if you use gapps, above), clear all data/userdata, reboot.
pershoot said:
you did not read droidbasement on installation instructions.
flash p4's modem via odin.
flash cwm 6.0.2.5.
fastboot erase system
fastboot boot CWM
flash unofficial 12/28 rom, flash minimal gapps (if you use gapps, above), clear all data/userdata, reboot.
Click to expand...
Click to collapse
Followed now all the steps as indicated by ramon and pershoot's instructions on droidbasement.
Checked the log and finally no space issues detected anymore.
Great and many thanks!!!!
---------- Post added at 01:22 PM ---------- Previous post was at 01:19 PM ----------
I used the latest ROM (28-12) and gapps as given by ramon. Now I have 1.1M free on system.
pinibo said:
Followed now all the steps as indicated by ramon and pershoot's instructions on droidbasement.
Checked the log and finally no space issues detected anymore.
Great and many thanks!!!!
---------- Post added at 01:22 PM ---------- Previous post was at 01:19 PM ----------
I used the latest ROM (28-12) and gapps as given by ramon. Now I have 1.1M free on system.
Click to expand...
Click to collapse
That's how it should be.
pershoot said:
no, you cannot.
this will not work.
'your' rom is 20MB smaller when installed + normal gapps, because you've symlinked content on to /data to make room and/or youve deleted a massive amount of system content. that, or you have a special p3 with more system space then the others i've seen.
the builds from droidbasement or when is published to nightly status, require minimal gapps (above), if you use gapps.
Click to expand...
Click to collapse
When do you plan to bring it back to CM repository. C-o-M in the Galaxy Tab 8.9 forum made first builds for the P73xx devices. Maybe everything could be brought together again, so nothing is lost as the P73xx and P75xx are pretty similar.
shiko80 said:
When do you plan to bring it back to CM repository. C-o-M in the Galaxy Tab 8.9 forum made first builds for the P73xx devices. Maybe everything could be brought together again, so nothing is lost as the P73xx and P75xx are pretty similar.
Click to expand...
Click to collapse
i'm not the device maintainer on that tab variant. please speak with kallt kaffe for that device suite.
pershoot said:
i'm not the device maintainer on that tab variant. please speak with kallt kaffe for that device suite.
Click to expand...
Click to collapse
kallt_kaffe seems not to be available any more. Isn't it possible for you take over the device ownership? Can you send a request for this?
gonna flash this too but I was a bit more "agressive" and deleted most of the ringtones and notification sounds from the rom. reduced the size of the rom to a whopping 117 mb
and also deleted appolo since I use Google Music. Will report back as soon as possible
shiko80 said:
kallt_kaffe seems not to be available any more. Isn't it possible for you take over the device ownership? Can you send a request for this?
Click to expand...
Click to collapse
sorry i dont own that tab and dont have the resources to take on more like devices at this current time.
pershoot said:
sorry i dont own that tab and dont have the resources to take on more like devices at this current time.
Click to expand...
Click to collapse
Sorry, I didn't want you take over any further devices but I thought it would help if everything is back in the CyanogenMod repository and more developers would work on it at the same time. In my opinion it makes no sense that C-o-M gets your sources, modifies it and makes a firmware for P73xx. So why not working all in the same repository. The other advantage would be that we have nightly builds.
The sound for my tab is not very hard if i put it to the max. Same wit headphone, even if i ignore the warning and put it harder.
Had the same on my Samsung Note on cm10 but cm10.1 solved it and is about just right now.
Watching a movie our listing a mp3
Sent from my GT-P7100 using xda app-developers app

[Q] How to create boot.img

Hi @all,
does anyone know how to create the boot.img to flash it over fastboot?
When I extract the kernel.sin from a FTF and try to flash it over fastboot it doesn´t work.
Thanks.
Greetings
UserX10
Why do you want to do that? Just flash kernel.sin via flashtool.
pandaball said:
Why do you want to do that? Just flash kernel.sin via flashtool.
Click to expand...
Click to collapse
For sure this is possible, but on this way I haven't learned anything
But I found after some search that I have to extract the system.sin to system.ext4 and just rename the system.ext4 to system.img
I assume that this is working the same way with kernel.sin
Will try it tomorrow...
That will only work if you're unlocked. You can just take the ftf, open it in flashtool and exclude everything except the kernel. That will flash just the kernel.
How to create boot.img Android
If you really want to learn then you should be reading reading reading.
http://forum.xda-developers.com/showthread.php?t=2139498
Sent from my C6603 using xda premium
gm007 said:
http://forum.xda-developers.com/showthread.php?t=2139498
Sent from my C6603 using xda premium
Click to expand...
Click to collapse
The thread you linked is about compiling a kernel from source, rather than converting a .ftf file to a .img file.
Easiest method to do this is to use flashtool, and dd the boot partition to /sdcard/boot.img
I don't know what the boot partition is though, but the command is either:
dd if=/path/to/boot of=/sdcard/boot.img bs=2048
or
dd if=/path/to/boot of=/sdcard/boot.img bs=4096
The boot.img you get on your sdcard is now flashable through fastboot and a direct copy of your currently installed kernel.
Thanks,
have done as described ftf -> sin -> ext4 and rename to img
flashed over fastboot worked
When I try to flash the same way the system I get the following error:
error: cannot load 'system.img'
anyone an idea?

[Q] How to extract system_signed of the RAZR i firmware?

Hy everybody,
I need a small help. I'd like to extract stock system apks placed in /system/app but I don't succed.
On the normal RAZR XT910 I use RSD or a zip extractor (winrar, winzip, etc.) to divide a stock firmware in system_signed, mbr_signed, motoboot, cdrom_signed, boot_signed and other files, then i can extract system_signed using Ext2explore to have a copy of the stock system folders,
On the RAZRi XT890 firmwares 4.1.2 this procedure doesn't work, when i try to extract system_signed,Ext2explore sometimes doesn't read the archive without any response or other times it stops working.
Thanks for helping.
bobby3 said:
Hy everybody,
I need a small help. I'd like to extract stock system apks placed in /system/app but I don't succed.
On the normal RAZR XT910 I use RSD or a zip extractor (winrar, winzip, etc.) to divide a stock firmware in system_signed, mbr_signed, motoboot, cdrom_signed, boot_signed and other files, then i can extract system_signed using Ext2explore to have a copy of the stock system folders,
On the RAZRi XT890 firmwares 4.1.2 this procedure doesn't work, when i try to extract system_signed,Ext2explore sometimes doesn't read the archive without any response or other times it stops working.
Thanks for helping.
Click to expand...
Click to collapse
Hey,
try unyaffs tool
First, wrong section. This belongs in the q&a.
Back to topic. The system.IMG has an ext4 file system. Mount it in Ubuntu with a mount loop methode. Don't know the exact words for it, sry.
Sent from my XT890 using xda app-developers app
Doesn't work
Thanks (and thanks to moderator) but these methods doesn't work.
Using system_signed of RAZRi unyaffs tool gives me an error response, "mount" on linux does nothing.
Using system_signed of RAZR XT910 instead works fine with ext2explore, with unyaffs tool and mounting in ubuntu but i need to extract RAZRi system_signed.
bobby3 said:
Thanks (and thanks to moderator) but these methods doesn't work.
Using system_signed of RAZRi unyaffs tool gives me an error response, "mount" on linux does nothing.
Using system_signed of RAZR XT910 instead works fine with ext2explore, with unyaffs tool and mounting in ubuntu but i need to extract RAZRi system_signed.
Click to expand...
Click to collapse
Than u still didnt look good enough. But ok, i have done it now for you
Download the script in the attachment. The simg2img.py.zip and extract it.
Uncompress the system.img file into a normal ext4 disk image:
‘python simg2img.py system_signed tmp.img’
This will create an uncompressed ext4 volume ‘tmp.img’ in the same directory
Mount this disk image:
‘sudo mount -t ext4 -o loop tmp.img somedir/’
profit. The mounted file/partition (then) is in read only mode, for the record
Hazou
Thanks a lot!
Hazou said:
Than u still didnt look good enough. But ok, i have done it now for you
Download the script in the attachment. The simg2img.py.zip and extract it.
Uncompress the system.img file into a normal ext4 disk image:
‘python simg2img.py system_signed tmp.img’
This will create an uncompressed ext4 volume ‘tmp.img’ in the same directory
Mount this disk image:
‘sudo mount -t ext4 -o loop tmp.img somedir/’
profit. The mounted file/partition (then) is in read only mode, for the record
Hazou
Click to expand...
Click to collapse
Fantastic! It works!
You are great! :highfive:
Thank you! Thank you! Thank you!

[Q] How to mount system.sin properly?

Hey guys, since we now have working root on 4.3 LB I decided to try and work on a custom rom based on stock 4.3.
Im using a ubuntu virtualbox installation.
After a lot of reading I have managed to end up with a system.ext4 from my system.sin file....
When I mount this in linux it is empty?
Any ideas how to get it to mount properly?
Have tried sin2img script and that fails with bad magic error.
Have tried renaming the ext4 to img and that results in the empty (looking) image when its mounted.
Its obviously possible as iHackerz [NUT] Monx etc have proved but I cannot find any information on how to mount the img properly to start customizing it.
EDIT:
Just found [NUT]'s guide in the Z forum... Will try like that =)

[Help needed] Corrupted Partition header (GPT), need one from another Xperia V

Hi guys,
I accidentally wrote a fat signature directly to mmc-flash and now my MBR is corrupted and I don't see partitions anymore in TWRP. Therefore I would be highly pleased if someone could send me his backup of the standard layout. You can obtain it via adb:
Code:
adb dd if=/dev/block/mmc0 of=/storage/sdcard0/partitionheader.img bs=1k count=128
This will copy the partition header to the mounted internal sdcard (requires root)
Many thanks in advance!
Defier525 said:
Hi guys,
I accidentally wrote a fat signature directly to mmc-flash and now my MBR is corrupted and I don't see partitions anymore in TWRP. Therefore I would be highly pleased if someone could send me his backup of the standard layout. You can obtain it via adb:
Code:
adb dd if=/dev/block/mmc0 of=/storage/sdcard0/partitionheader.img bs=1k count=128
This will copy the partition header to the mounted internal sdcard (requires root)
Many thanks in advance!
Click to expand...
Click to collapse
Here It Is.
View attachment GPT.zip
Very cool, thanks a lot! Looks very much the same to mine, except its MBR seems to be intact (unlike mine). Will report here about progress with restoring it.
For the record: I just flashed the MBR (512 bytes) of ElArchibald's GPT and my Xperia V is back to life. Once again, many thanks!
Defier525 said:
For the record: I just flashed the MBR (512 bytes) of ElArchibald's GPT and my Xperia V is back to life. Once again, many thanks!
Click to expand...
Click to collapse
I think you should ask moderator to move this thread to General Forums
You mean Xperia T/V general? Well, I think when not playing around with development you normally don't brick your GPT header, do you?
Oh, but it could fit nice in "help and troubleshooting" I guess.

Categories

Resources