Related
This is regarding a recently bought tablet Note 8. The current usage of /system partition is at above 75%. I have been trying to wipe/delete all system data in an attempt to have a 'fresh' OS once I install new stock ROM. In CWM recovery, I have even tried to format system partition (in addition to normal data reset, cache wipe and delvek cache wipe).
I installed the new stock ROM 4.4.2 in Download mode. Afterwards I checked and my system partition was still above 75% full. I do understand that system partition is normally read only. I am trying to work out if there is there any way where I can flash the stock ROM whilst completely removing the current system files.
Please offer any guidance or advice regarding this matter. Thanks!
Possible? Yes. Necessary? No.
The installation script for a ROM will almost always format the system partition before setting it up with the new ROM files, unless the developer is doing some special testing and you would know if that is the case.
ramjet73
Yes I think most custom ROMs would wipe system partition too. Though I want to install the stock ROM of Android 4.4.2. I have flashed the ROM about four times now, everytime trying different settings such as wipe/format system drive.
But I always end up with /system drive same size as before.
Thanks for the reply ramjet73.
S2 user said:
Yes I think most custom ROMs would wipe system partition too. Though I want to install the stock ROM of Android 4.4.2. I have flashed the ROM about four times now, everytime trying different settings such as wipe/format system drive.
But I always end up with /system drive same size as before.
Thanks for the reply ramjet73.
Click to expand...
Click to collapse
Depending on how you flash the stock ROM, Odin will flash a .img file to the system partition and completely replace its contents or an updater-script in a stock ROM zip file will format it and then copy all the included /system files to the empty partition.
In either case you cannot control what goes into the initial configuration of the system partition, only delete things that you don't need after it is flashed, unless you flash from a stock ROM zip file and delete items from that before you flash it.
There are scripting tools that can help with ROM "slimming" but I don't know if any are available for the Note 8.0 or not.
ramjet73
Hi
Let's say we have tablet with allwinner a20 but there are two versions of MB(let's call it first MB and second MB). They use different firmware, when you flash wrong one device is booting but lcd is black(only backlight). I have access to stock firmware but only for first version of MB. So I tried to pull firmware from working device. What I did(in short):
1. Factory data reset.
2. Dump bootloader, boot, env, system, recovery partitions using dd if=nandX of=nanaX.img
3. Unpack stock firmware with imgRePacker.
4. Replace bootloader.fex, boot.fex, env.fex, system.fex, recovery.fex with files from step 2.
5. Mount bootloader partition and make copy of script.bin.
6. Update boot1 and boot2 files using update_boot0 and update_boot1 from SDK.
7. Second MB have one extra partition (called private) so I edited sys_partition.fex and generated sunxi_mbr.fex & dlinfo.fex files with update_mbr.
8. Pack modified firmware to img file.
Device booted successfully after flashing my firmware with phoenixsuit, everything worked, but when i restarted, tablet was stuck in bootloop. I tried to look at logcat output, it looks like it cannot create dalvik-cache directory on /data partition. Strange thing, because all required folders are created on /data partition at first boot, including dalvik-cache, they just dissappear after reboot. Wipe data from recovery doesn't help, I need to do reflash using phoenixsuit, but again, first boot OK and then device is bootlooping.
I also tried flashing my firmware on another tablet but I clicked No in "Does mandatory format?" window, tablet was stuck in bootloop with same errors about dalvik-cache directory.
When I try to make dalvik-cache directory manually using ADB it gives me some I/O error, but I can create folders with different names on /data partition without problems.
I don't have access to device right now, I will post logcat asap.
Another strange thing, on second MB with stock firmware there is 4,07GB of internal sd, but when I flash my firmware it grows to 4,56GB. It's almost 500MB Output of cat /proc/partitions is same(only size of last partition(internal sd) is different).
I will try to dump /data partition and add it to img file but it won't problably work. I'm also looking for a way do dump original MBR and boot0/boot1 from nand, in /dev/block I don't have device that represents full nand, only partitions(nanda, nandb, etc).
I have access to many tablets that I can play with, I bricked 2 so far
I don't know if it's right place to post such problems but I hope someone will be able to help
Phone T-989D
TWRP 2.8.7
Currently running cm-13.0-20151219-UNOFFICIAL-hercules
So in the process of getting the above CM13 to work, I was doing the virtual partition. Following the instructions, I wasn't able to partition as directed in the instructions -
In TWRP, go to Wipe -> Advanced Wipe -> check Internal Storage -> press on "Repair or Change File System" -> press on "Change File System" -> press on "EXT4", and then swipe to start formatting the internal SD card. This can take up to a minute.
Click to expand...
Click to collapse
Pressing on Repair or Change File System gave an invalid location. Apparently this is a known issue? *shrugs*
So I did this -
Used the following PIT file...
http://forum.xda-developers.com/gal.../mod-partition-internal-memory-t-989-t3051556
Odin returned /w success.
Installed CM13 image from above.
Works.
In the instructions for pit, it showed how to check sizes via the Storage and USB option screen, in his version of android... but CM13, doesn't have it the same menu, it shows Internal Storage only and listed at 5gb.
My question is then, is my virtual partions proper? I don't know how to check each virutal partition... using TWRP I can only confirm the partition ares ext4.
In TWRP it has /data /internal storage /system and the other common ones. How do i check if everything is OK? I don't know what is required to confirm a virtual storage is set properly.
Also, in TWRP can some explain what Format Data does? its not like Windows format is it? I mean you partition a drive, then you have to format it, to use it. Its only like wipe correct? I don't really need to do if it I'm wiping /data /dalvick /cache anyways?
Thank you.
You don't need the PIT file anymore. You need to undo and flash the original PIT back to the device. I believed it is called "unmodified". After you finish undo your device you can follow instruction in the Unofficial CM13 thread to flash the special TWRP recovery update. This one rename partitions so the new rom can be installed. Once you reinstall the rom, the Internal storage will show around 11 GB and not 5 GB
In TWRP, go to Wipe -> Advanced Wipe Then
Select "Data" and click "Repair or Change File System", you should see size around 11,xxx MB
Select "System" and click "Repair or Change File System", you should see about 2,xxx MB
Select "Cache" and click "Repair or Change File System", you should see about 5xx MB
kbook said:
You don't need the PIT file anymore. You need to undo and flash the original PIT back to the device. I believed it is called "unmodified". After you finish undo your device you can follow instruction in the Unofficial CM13 thread to flash the special TWRP recovery update. This one rename partitions so the new rom can be installed. Once you reinstall the rom, the Internal storage will show around 11 GB and not 5 GB
In TWRP, go to Wipe -> Advanced Wipe Then
Select "Data" and click "Repair or Change File System", you should see size around 11,xxx MB
Select "System" and click "Repair or Change File System", you should see about 2,xxx MB
Select "Cache" and click "Repair or Change File System", you should see about 5xx MB
Click to expand...
Click to collapse
@kbook,
Would you kindly post the links to Special TWRP recovery update and/or the thread you were referring to? Thanks
usrkizzi said:
@kbook,
Would you kindly post the links to Special TWRP recovery update and/or the thread you were referring to? Thanks
Click to expand...
Click to collapse
The TWRP is in this thread on the #2 post. The newest version is 3.0.2.
http://forum.xda-developers.com/gal...unofficial-cyanogenmod-13-0-hercules-t3246059
To undo the partition using PIT, go to this thread
http://forum.xda-developers.com/gal.../mod-partition-internal-memory-t-989-t3051556
At the very of the first post, long one, you will see
T989_PIT_(Unmodified).zip <-- this is to undo the partition back to its original.
-By following this you can can increase /system space from default 800MB to 1.2GB/2GB
-You can flash gapps on CM ROMs without insufficient space issue.
-You can flash regular MIUI ROMs too,without any issue.
Statutory warning
*Repartition can kill your phone forever if anything goes wrong,so proceed with caution (and make sure you have at least 30% battery)
*This process would format your internal sdcard,backup its contents
*I'm not responsible If your phone dies during this procedure under any circumstances beyond control
Prerequisites:
1)Redmi 1s partition script_system space 1.2GB.zip/2GB.zip
2)Parted
3)Twrp v3.0.2-1.zip
4)Download and copy all these files to external sdcard
Procedure:
1)Flash Twrp recovery(incase if aren't already using it).
2)Boot in to Twrp--->Advanced--->File manager--->Browse to the location of file "parted"--->Select "parted"--->Copy File--->/sbin.
3)Now using Twrp File manager browse /sbin--->parted--->select parted--->chmod 755.
4)You can also use "aroma file manager" instead of Twrp file manager for copying "parted" to "/sbin" and changing it's permissions to 755.
5)In Twrp flash "Redmi 1s partition script_system space 1.2GB.zip/2GB.zip" and wait for the script to finish execution(recovery will reboot automatically once this process finishes).
6)In Twrp--->Wipe--->Advanced wipe--->Mark in "Dalvik/ART Cache"__"Cache"__"System"__"Data"__"Internal Storage"--->Swipe to wipe.
7)Reboot recovery.
8)Install your ROM(don't flash gapps now).
9)Back again to Twrp start screen select "Wipe"-->Advanced wipe-->select/mark "System"-->press "Repair or change file system(notice that size hasn't increased to 1.2GB/2GB)-->Resize file system.
10)Back(though size of partition appears unchanged, its actually increased to 1.2GB)-->Back>select/mark"System"-->Repair or change file system-->Notice size of partition increased.
10)Back to Twrp start screen and flash gapps,that's it.
Reset to default partition:
1)I am also giving link for flashabe script file "Reset to default partition.zip" for restoring default partition sizes.
2)Boot in to Twrp--->Advanced--->File manager--->Browse to the location of file "parted"--->Select "parted"--->Copy File--->/sbin.
3)Now using Twrp File manager browse /sbin--->parted--->select parted--->chmod 755.
4)You can also use "aroma file manager" instead of Twrp file manage for copying "parted" to "/sbin" and changing it's permissions to 755.
5)In Twrp flash "Reset to default partition.zip" and wait for the script to finish execution(recovery will reboot automatically once this process finishes).
6)In Twrp--->Wipe--->Advanced wipe--->Mark in "Dalvik/ART Cache"__"Cache"__"System"__"Data"__"Internal Storage"--->Swipe to wipe.
7)Reboot recovery.
8)that's it you are back to default partition.
PS:
1.Need for "Resizing System partition"(step 9) comes only with CM14.1(haven't tried other CM versions or other custom roms) no need to do that if you are flasing MIUI ROMs(i,e you can skip step 9 if you are flashing MIUI ROMs)
2.If you still need more System space or want to further modify partition table(only if you know what you are doing),you can edit "update-binary" file inside the zip as per your needs.
Credits:
1)forumber2_ Samsung Galaxy S III.
2)slst_for his valuable input.
3)owaisnaim & fefifofum Twrp for redmi 1s.
Downloads:
1)parted:https://drive.google.com/folderview?id=0B6_hhjS3nx4IU05yLVc2Mk9uOEk
2)Repartition script Redmi 1s_1.2GB system space:https://drive.google.com/folderview?id=0B6_hhjS3nx4IRkJFZzAtMjZEa2s
3)Repartition script Redmi 1s_2GB system space:https://drive.google.com/folderview?id=0B6_hhjS3nx4IRXlDZUU1cEJ3Smc
4)Reset to default partition:https://drive.google.com/folderview?id=0B6_hhjS3nx4IeGtXb0liazdLWVk
5)TWRP 3.0.2-1.zip:https://drive.google.com/folderview?id=0B6_hhjS3nx4IdzFHXzdfNXVCYm8
good work mate
Great tutorial! Have a some questions:
1. After successfully doing this, If I decided to full clean wipe system, data, cache, dalvik cache, internal storage, and format data, the size will be reset? Do I need to do all the steps again?
2. If I decided to go back in default partition size I just flash that to reset all the steps? Or there will be a steps to reset all I've done?
Thank you.
Sent from my HM 1SW using Tapatalk
vhick said:
Great tutorial! Have a some questions:
1. After successfully doing this, If I decided to full clean wipe system, data, cache, dalvik cache, internal storage, and format data, the size will be reset? Do I need to do all the steps again?
2. If I decided to go back in default partition size I just flash that to reset all the steps? Or there will be a steps to reset all I've done?
Thank you.
Sent from my HM 1SW using Tapatalk
Click to expand...
Click to collapse
no you just have to go to
wipe >mark on system>click repartition
go back you can see system size 1.2gb
after doing this can i flash latest twrp ?
vhick said:
Great tutorial! Have a some questions:
1. After successfully doing this, If I decided to full clean wipe system, data, cache, dalvik cache, internal storage, and format data, the size will be reset? Do I need to do all the steps again?
2. If I decided to go back in default partition size I just flash that to reset all the steps? Or there will be a steps to reset all I've done?
Thank you.
Sent from my HM 1SW using Tapatalk
Click to expand...
Click to collapse
1.You can do all the wiping as usual, size of partition wil stay as it is and won't get reset,but if you're flashing current version of cm14.1 again you need to resize "System" partition before flashing gapps.
2.You additionally need to change "System" partition too to F2FS and than to EXT4(like you do with "Data" partition),in case you're going back to default partition.
I forgot to mention point 2 in OP,I will now add this there
vinayak.ghimire said:
after doing this can i flash latest twrp ?
Click to expand...
Click to collapse
Ya you can.
and whats the size of userdata and cache partition ?
vinayak.ghimire said:
and whats the size of userdata and cache partition ?
Click to expand...
Click to collapse
Based upon the scenario, the only concern is the system partition coz newer or update partition is too large. Cache partition is ok because it only use as a temp file partition. The userdata partition is large as internal storage because it shared as the same partition. That is the good thing at xiaomi phones, data partition is large as long as you have space in internal storage.
Sent from my HM 1SW using Tapatalk
vinayak.ghimire said:
and whats the size of userdata and cache partition ?
Click to expand...
Click to collapse
Install diskinfo app and check
Thanks for the script. It will help us a lot in now and in future also.
I know, i am asking too much. I bet we all are from developers but I will be very glad if you can provide me link of flashable file of TWRP and philz recovery 6.55.
Thanks Loads.
Anyone have checked this tutorial working ??
I checked this tutorial working fine. Thanks for this awesome tip. Here the flash able zip of twrp
Here is screenshot
apoorvpandey41 said:
I checked this tutorial working fine. Thanks for this awesome tip. Here the flash able zip of twrp
Click to expand...
Click to collapse
Thanks mate appreciated.
Thanks man works perfectly fine. Awesome tutorial.
Guys please help me:
Today morning I reparationed my Redmi 1s as the Op said. it went successful. after using for 5hours I've found an update from CM. So I updated using CM UPDATER APP. after reboot I've lost my Google play store and Google app (after updating to todays CM update using CM UPDATER APP). When I went to see the system partition size, it's size went back to the default 782mb (around 782mb, I don't remember exact size).
I checked whether it is disabled or what in apps. But I can't find there also. I tried Show system apps and reset app preferences, but nothing showed them.
I tried to get them back (play store and Google app) by resizing the partition to 1.2 gb (wipe>advanced wipe> Mark system>change or resize partition>back> checked system partition size whether 1.2gb or not>wipe cache and dalvik cache> reboot to system). But nothing worked.
So please help me in getting them back. Please exclude solution such as factory reset or flash gaggs again.
Is anybody else also facing the same issue or it's just me?:crying::crying::crying:
freeshared said:
1.You can do all the wiping as usual, size of partition wil stay as it is and won't get reset,but if you're flashing current version of cm14.1 again you need to resize "System" partition before flashing gapps.
2.You additionally need to change "System" partition too to F2FS and than to EXT4(like you do with "Data" partition),in case you're going back to default partition.
I forgot to mention point 2 in OP,I will now add this there
Click to expand...
Click to collapse
please give detailed instructions to get back to default partition as i am not anymore able to flash any rom on my device. Sometimes it strucks at patching system image unconditionally and sometimes shows error 7 in twrp. And not even being able flash using adb sideload. Please give detailed instructions to revert back to default partition
sharathe100111 said:
please give detailed instructions to get back to default partition as i am not anymore able to flash any rom on my device. Sometimes it strucks at patching system image unconditionally and sometimes shows error 7 in twrp. And not even being able flash using adb sideload. Please give detailed instructions to revert back to default partition
Click to expand...
Click to collapse
1)Detailed instructions for returning back to default partitions are given in op under the sub header "PPS", nothing more to add to it,just follow as it is.
2)I myself havent faced any issues till now iam currently on cm14.1 6-12-2016 version
3)Saw your posts on cm41.1 thread too,so you're on latest twrp
but still facing error 7,If possible post a screenshot of error 7(coz it never happed for me)
4)coming to the issue at hand,could you able to mount cache,system and data partitions.In twrp go to wipe>>advanced wipe>>select "cache">>Repair/change filesystem and see if everything(regarding partition size)is ok there.
Then do same for system and data too and check how are those partitions,if possible post screenshots.
Post your relpy as soon as possible.
freeshared said:
1)Detailed instructions for returning back to default partitions are given in op under the sub header "PPS", nothing more to add to it,just follow as it is.
2)I myself havent faced any issues till now iam currently on cm14.1 6-12-2016 version
3)Saw your posts on cm41.1 thread too,so you're on latest twrp
but still facing error 7,If possible post a screenshot of error 7(coz it never happed for me)
4)coming to the issue at hand,could you able to mount cache,system and data partitions.In twrp go to wipe>>advanced wipe>>select "cache">>Repair/change filesystem and see if everything(regarding partition size)is ok there.
Then do same for system and data too and check how are those partitions,if possible post screenshots.
Post your relpy as soon as possible.
Click to expand...
Click to collapse
Thank you brother for your reply. Now i am on miui as i am not being able to go to CM14 anymore. But i can flash CM11. (it seems i can use only kitkat).
Here are the screenshots: for MOUNT, ADVANCED WIPE, CACHE, SYSTEM, DATA. And problem struck on patching system image unconditionally
My phone storage is filled with 36 gb of system storage like title says. I know solution is formating phone but i dont have access to a PC. So can anyone help me with this problem. I am currently using 8.1 custom rom
Install es explorer or something similar with a "storage-scanner" feature and you will find the folder where this extra space is being used, then take the decision of formatting the phone or deleting that folder.
Most likely it is leftover files from some previous app or something you manually transferred to "Android/Data" folder to hide them *wink*.
Let us know the result of storage-scan.
I fear that the issue is unrelated to an actual file taking the space, 36 GB is ungodly for /system, after all.
The issue usually crops up due to an incorrect encryption, or something in the neighbourhood of that. The common fix to it is by reformatting /data through fastboot then TWRP/recovery, but fastboot requires access to a computer, something that OP states they cannot have for the time being.
Check if you have the folder /data/media/TWRP and either delete it or move it to /data/media/0/TWRP
@F4uzan You had the right answer i couldnt find any other solution . In the end i formatted everything from fastboot. Thanks anyways
Ahmetcenk07 said:
Admin Note: This is a special Q&A-formatted thread. Please follow this link to view it in your browser:
Click to expand...
Click to collapse
Do a backup of anything you need to keep in TWRP to an external drive (SD card, USB or PC) if you haven't got these you will have to backup, reboot, then transfer to cloud (Mega = 50gb free)
Then do a FULL wipe (everything), go back to wipe again but don't select any partitions just click the FORMAT DATA button, this will completely format your phone to factory again with no forced encryption etc etc, only the original 3 GB system image left, then you just need to re-flash your chosen ROM again and restore anything you need from your backups.
Hope this helps.