Need Help on Updater-Script - Upgrading, Modifying and Unlocking

Hi I'm trying to format my System partition but not succeeding because it has EMMC partition not MTD and also i cant find the mount points of my devices so if any one here could help me to delete ALL THE FILES AND FOLDERS IN THE SYSTEM folder(i dont want the system folder to be deleted just all the contents of it)?

Related

A question about the /cache folder.

What for is this folder used anyway ? Maket cache, rom updates, installing programs from pc? Does anyone has a clue? Beacuse I see 130 MB of free space there (nand I suspect - which is FAST compared to SD).
/cache is a partition:
Code:
/dev/block/mtdblock4 on /cache type yaffs2 (rw,nosuid,nodev)
unless you want to repartition the nand (which nobody has done yet afaik) you won't be able to use this space... at least not really practicable.
First I want to know what it is used for, how much space will be used and in what condition. I have several ideas how to use it, but first I need to know how much space I have to play with.
The easy way to go is to use loop files for directories and mount them in the /data/ folder. The hard way is to go in recovery mode copy the contents of /data/ to SD linux partition, use tools provided from recovery and resize /data/ ana /cache/ then copy the backed-up contents on the SD to /data/.
Somebody ?
Not certain, but I thought the /cache was for an RUU downloading the HEROIMG.ZIP file that it needs to perform the update. Also, I though fastboot used it to store the img file temporarily when booting or flashing an image.
Not sure though, so might need more investigation.
DeXa said:
The easy way to go is to use loop files for directories and mount them in the /data/ folder. The hard way is to go in recovery mode copy the contents of /data/ to SD linux partition, use tools provided from recovery and resize /data/ ana /cache/ then copy the backed-up contents on the SD to /data/.
Click to expand...
Click to collapse
i don't think any of this is gonna happen, but don't let that stop you from anything. here are my worries:
- loop file for dirs: so then you have a (let's say) 80mb directory in /data. what are you going to with it? for me that would be to small for apps, it is even less than the regurlar internal /data.
- do you have tools to repartition the internal nand? i am just wondering, because it seems nobody has done it so far. or do you have reports of successfull partitioning? should it even work with parted?
kendong2 said:
i don't think any of this is gonna happen, but don't let that stop you from anything. here are my worries:
- loop file for dirs: so then you have a (let's say) 80mb directory in /data. what are you going to with it? for me that would be to small for apps, it is even less than the regurlar internal /data.
- do you have tools to repartition the internal nand? i am just wondering, because it seems nobody has done it so far. or do you have reports of successfull partitioning? should it even work with parted?
Click to expand...
Click to collapse
My idea was to use the loop file for dalvik-cache for example or any other dir that does not go beyond for example 80 megs. For partitioning there are nand tools available on the net, and it is not so hard to compile them for arm arch. Bul all of this is poinless if we do not know how much space is gonna be used from the /cache folder. And what for it is used by Android OS.
I don't really thing it will work too, but nobody knows till it's tested. This are just thoughts. Last night I found out that OS deletes the whole contents of the /cache folder on successful boot, all except dirs. That was strange for me cause last evening I had a couple of "Download.app, Download-1.app and so on" files which survived successful reboot, bug suddenly they were deleted. So the only thing that's left to experiment with is repartition nand, but for that ... again the min. free space has to be known.

Trying to understand the file structure.

Hi everyone!
I currently am running Glazed ICS 6-16-2012 Rom and I am attempting to understand the file folder structure within my Kindle Fire.
This comes about after playing around with different roms, and after running the TB restore, a few games I play not having the data, requiring me to start over. In an attempt to try and manually recover the data from a twrp recovery I did, I realized didn't have a good idea of the folder structure within Android. Thus I am hoping to get some clarification with the following questions. Thank you in advance for any advice.
1- what folders, if any are required on my sdcard if say I were to start with a fresh rom, with no apps installed other then what is included in the Rom? Using ES File Manager now, it looks to me like an completely unorganized folder ".estrongs, burstlyImageCache, game_cache" etc.
2- Could I copy my TB backup folder off the Kindle Fire then wipe the whole SD card, copy the TB backup back and restore to clean up excess junk folders?
3- Do apps/games put their save data wherever they chose, or is it kept in the program folder in the internal memory, /mnt/sdcard/...?
Thank you again for reading my ramble, cheers.
Silverbrain
1.: Usually Application you installed in SD card partition is under /mnt/sdcard/android/data/<application folder> . now this contains all the information and other data of the games, i think you can back-up this portion aside from using titanium back-up.
For application specific folder, they are usually located in /mnt/sdcard/.<appname> but this folder usually contains caches and can be deleted, since the app will just create them once run again.
2. I do not suggest to wipe your SD partition since technically this is not a standard SD card but partition part of the whole system.
Note: I'm not expert on this, but after playing around with a couple of android devices already, the structure is basically the same.
I think (if it is a unix derivative) the /sdcard is the partition location and /mnt/sdcard is where the system finds what is there. kindle fire does it this way because there is no removable memory card, so it creates an artificial one with a partition. So, for us human types, the locations refer to the same thing. /sdcard is the partition and /mnt/sdcard is where the system mounts it.
Thank you for the replies.
Ixthusdan- I get what you mean regarding the unix and the mnt folder, I technically cannot wipe that is it is just a spot on the internal memory.
vertcam9- I started looking around where you mentioned, and I am starting to understand a little better
The actual name of the partition is "media" and that's how it's identified to the system.
Where the media partition gets mounted is dependent on what gets booted. For example, TWRP will mount the media partition on /sdcard while CM7 will mount it on /mnt/sdcard and create a /sdcard symbolic link that points back to /mnt/sdcard. Most people generically will refer to the media partition as the /sdcard partition because that's what's visible on the system.
I believe the /sdcard thing is an android convention. Because many apps expect the /sdcard to be the primary "large" storage area easily accessible by the user, apps that expect to find large files... music or video files for example... will look there.
Most apps will store settings and small databases in the /data partition. I don't play many games, but someone decided to install Angry Birds on my KF. That game stores most of its files in /data/data/com.rovio.angrybirds. On the other hand, Titanium Backup will put most of its files on /sdcard/TitaniumBackup because it needs more space for backup files and because the /data partition is much more likely to get deleted when you switch ROMs, etc.
For the most part, even if you completely reformat the /sdcard partition, most of your android and app settings will remain intact because that is stored on /data.
kinfauns - Thank you for the extended explanation! I see what I think I need in the /data/data folder

Using SDCARD as /data

I have a problem with my phone.
I believe that the internal partitions are messed up.
I have tried a couple of guides to fix this but no luck. I get "error formatting /data!" on recovery. I also tried using the formatting tools from adb shell (e2fsck, gparted).
The main problem is that when i restart my phone the /data partition gets wiped, and the phone reboots in blank, no apps no setting (some of them remain).
I wonder if i can solve this by setting my sd-card to be the new /data. I doesn't matter if i have to leave the sd-card on all the time. i mainly use this phone for developing apps.
Thanks.:good:
Felivel said:
I have a problem with my phone.
I believe that the internal partitions are messed up.
I have tried a couple of guides to fix this but no luck. I get "error formatting /data!" on recovery. I also tried using the formatting tools from adb shell (e2fsck, gparted).
The main problem is that when i restart my phone the /data partition gets wiped, and the phone reboots in blank, no apps no setting (some of them remain).
I wonder if i can solve this by setting my sd-card to be the new /data. I doesn't matter if i have to leave the sd-card on all the time. i mainly use this phone for developing apps.
Thanks.:good:
Click to expand...
Click to collapse
It could probably be done if you could get the sdcard to mount at boot, not sure if thats possible. You would need to create a flashable much like the ext4 mod, that edits the init.inc.rc file to mount the sdcard and /data to it. You would want to partition your sdcard with an ext3 or ext4 partition and use that for data.
Yes it can be done. That's how boot manager works, by modifying the ramdisk to load images from sdcard or emmc instead of the partition. I think I have an idea on how to make your request work.
Edit: If you feel like trying a project, what needs to be done is create a file data.img and mount it as loopback using busybox (ROM needs a working busybox).
Then the boot.img needs to be updated replacing the mount /data entry in init.inc.rc with the location of the loopback device and a loopback setup prior to this. The data.img created needs to be formatted ext3 or ext4. I know it's not too detailed but rather just a summary.

[Q] Possible to convert to data/media file structure?

This might be a very noob-like question, but I was wondering if it would be possible to convert the file structure in use by the system.
Newer devices don't have a seperate sdcard partition anymore, there's just a single user partition "data" and the sdcard get mounted to "data/media". The advantage is that space between apps and your sdcard is shared, so you have a choice of filling your internal storage with media or with apps.
Sooo would it be possible to switch to that file structure?
Cheers

[Q] [HELP] War with HTC

Hi
Im new on XDA and I have problem
I have war with HTC about updating Desire Z to android ICS or JB
HTC said the cant update 2.3.3 to 4.0 because you will lost your data
So I have idea how to protect data while istalling update to new android, but Im N00b and cant write program that will protect /data from wipe.
Possibilities:
1 Copy /data partition to sdcard as ./data
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
2 Dump /data to data.img/data.zip to your sdcard
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
3 Format /system , dump /data to .img or .zip , copy to ./system
Then format all partitions (EXCEPT /system)
Restore /data from /system/data.img
Add /data files from new ROM
Format /system
Add /system files
Im a programming N00b, so can You tell me:
1. Is it possible?
2. Can You write this script for any ICS Sense 4 (or 5) ROM? (HTC Desire Z)
Sorry for my English. Im a Polack from Poland
I installed Flinny's Andromadus CM10.1 over my previous CM7 installation I had been using for years, it worked perfectly fine with no data loss really. Quite a few of the settings transferred over surprisingly. HTC isn't interested in updating 3 year old devices let alone your carrier, your warranties are up and you own the phone by now. You're on your own and it's now the community's job to support it which is slowly petering out.
Go root and flash
Hi,
I switched very soon to Custom ROMs and had a long list of ROMs on my DZ from the Virtuous ROMs to Andromadus and slimBean. I'm now back to Andromadus Mimicry which is a Android 4.0.4 ROM (I tried Slimbean but it has no car mode, go for it when this doesn't bother you, it's 4.2).
Please keep in mind that the DZ is a rather old device and slow compared to the actual ones. HTC wants its Sense on Android which significantly slows the DZ down. So I went for more custom ROMs and have come Sense feeling eith the Apex Launcher. The only thing I really miss is the Sense contacts app that aggregates different addresses of a user (Exchange/Xing/LinkedIn/Facebook/Twitter) into one single contact. I didn't find a replacement for that.
Re. data: Which unique data do you have on the phone? Most of my data sits on the SD card and that is not affected when you flash a new ROM. All the calendar/contact/mail data can be re-synced from Google or Exchange or whatever you use. Use Titanium Backup and make Backups with Clockworkmod and you're perfectly fine. I tried out a ROM last evening and was back to my old ROM and up again in a hour. A Nandroid backup keeps the complete state of the phone so it's easy to roll back.
Apart from this (and some waiting moments here and there) a DZ with a Custom ROM is absolutely useable. I'm a 48 year old freelancer who uses the phone for work so I need a reliable phone and a keyboard for Emailing - and I've got that now.
Have fun and use all the Howtos to root and flash your phone
Cheers, Ralf
FotelPL said:
Hi
Im new on XDA and I have problem
I have war with HTC about updating Desire Z to android ICS or JB
HTC said the cant update 2.3.3 to 4.0 because you will lost your data
So I have idea how to protect data while istalling update to new android, but Im N00b and cant write program that will protect /data from wipe.
Possibilities:
1 Copy /data partition to sdcard as ./data
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
2 Dump /data to data.img/data.zip to your sdcard
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
3 Format /system , dump /data to .img or .zip , copy to ./system
Then format all partitions (EXCEPT /system)
Restore /data from /system/data.img
Add /data files from new ROM
Format /system
Add /system files
Im a programming N00b, so can You tell me:
1. Is it possible?
2. Can You write this script for any ICS Sense 4 (or 5) ROM? (HTC Desire Z)
Sorry for my English. Im a Polack from Poland
Click to expand...
Click to collapse
What kind of data is it that you really want to save?
Contacts, Call Logs and SMS can be easily saved by apps available on the Play Store. Super Backup, SMS Backup + for example. Your contacts get synced to Gmail so you don't really need to save those.
If you are worried about application data, get an app like Titanium Backup Pro, root your phone and back the whole lot up. All the app settings and data gets backed up to your SD card.
Do a Nandroid backup in any case. You can restore stuff from that too. Wipe, flash new ROM and restore everything from Titanium one by one. Is there anything else specifically that you don't want to lose?
War with HTC
Yeah, I know
By "Data" I mean whole /data partition (contacts, apps, appdata etc.)
My friends have root on their DZ's, but they dont want to backup everything before installation of new ROM, and install everything again on new ROM (ex. Migration from GB to ICS/JB)
I think its really annoying
FotelPL said:
Hi
Im new on XDA and I have problem
I have war with HTC about updating Desire Z to android ICS or JB
HTC said the cant update 2.3.3 to 4.0 because you will lost your data
So I have idea how to protect data while istalling update to new android, but Im N00b and cant write program that will protect /data from wipe.
Possibilities:
1 Copy /data partition to sdcard as ./data
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
2 Dump /data to data.img/data.zip to your sdcard
Then format /data /system /boot /cache /dalvik-cache etc
Copy system files to /system and /data
Restore /data from sdcard
Add /data , /system files
3 Format /system , dump /data to .img or .zip , copy to ./system
Then format all partitions (EXCEPT /system)
Restore /data from /system/data.img
Add /data files from new ROM
Format /system
Add /system files
Im a programming N00b, so can You tell me:
1. Is it possible?
2. Can You write this script for any ICS Sense 4 (or 5) ROM? (HTC Desire Z)
Sorry for my English. Im a Polack from Poland
Click to expand...
Click to collapse
You have no choice but to loose data such as Games etc... BUT you can backup your contacts, appoitmnets (Calendar) and messages by using
SMS Backup+ for your messages and call logs and even MMS
Sync your phone with google to backup contacts and calendar remonders (I know you know how to do that )
War with HTC
I know how to do that, but AppData backup dont exist, sms too but contacts are incolmpete (In Google backup, of course)
FotelPL said:
I know how to do that, but AppData backup dont exist, sms too but contacts are incolmpete (In Google backup, of course)
Click to expand...
Click to collapse
There are many ways to back up app data, many ways to back up contacts, really I can't think of what you can't back up completely
Google completely backs up contacts so long as its synced to gmail
And to answer the op this is a standard song and dance that OEMs give when they don't want to continue developing for an old device, there are many ways they could solve the app loss issue, even if they didn't they could but a build on their website you have to download as an RUU with disclaimers and not an ota. This way they could keep both groups of users happy
Unfortunately they don't find it t be in their best interest supporting old devices, one of many reasons xda and other sites exist
Sent from my Nexus 4 using Tapatalk 2

Categories

Resources