HOW TO: Manually partition your SD card for Android Apps2SD with MT3G Slide - myTouch 3G Slide Android Development

This article is for people with rooted Android phones and having trouble with eugene's method. Everyone else please ignore. There are dozens of ways to partition your SD card and I would like to share the one that has worked for me every time. I prefer to manually partition my SD card because it gives me complete control.
Requirements before getting started:
Already Rooted Mytouch 3G Side
Clockwork recovery
SD Card (Class 6 suggested but any will work)
Android Device Bridge(ADB): Comes with the Android SDK.
Command Prompt on your computer
These instructions apply to both the Windows command prompt and the Mac terminal. I was using Windows 7. You can partition your SD card at any time, but you might as well do it before you flash a new build of Android. As always, back up your data when performing any hacks. Partitioning your SD card will erase all data on it. Read the whole thing before starting.
I'm Not Responsible for Any Damage to your Phone or Memory Card
All commands you need to type are in bold (my comments are in parenthesis). If you do not know how to use ADB, leave a comment for help or read ADB for Dummies over in the forums.
Step 1.
Step 1: Connect your phone to your computer via USB. Reboot into Clockwork recovery mode. Make sure your phone is seen by adb. After your phone has booted into the clockwork recovery and seen on the recovery screen. Go to the partition menu and unmount sdcard.
Next:
Command: adb shell (type this after your phone has booted into the clockwork recovery and seen on the recovery screen. it should take you to a # prompt)
Step 2.
Step 2: Open parted to partition your SD card.
Command: parted /dev/block/mmcblk0 (opens parted and mounts your SD card)
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Step 3.
Step 3: Check the size and partitions of your SD card. The print command will display this info. You can see the size of my SD card is 7944 MB (8 GB). I have 1 partition which is fat32. If your SD card is blank and no partitions are listed, you can skip to Step 5.
Command: print (displays SD card information)
Step 4.
Step 4: Remove all existing partitions. If you have multiple partitions, remove each one at a time.
Command: rm 1 (deletes partition number 1)
Command: rm 2 (if needed. keep going till all partitions are removed)
Command: print (check when you are done to make sure all partitions are removed)
Step 5.
Step 5: Create your new partitions. You can make these any size, but the most common setup is 32 MB linux-swap partition, 512 MB ext2 partition, and remaining free space as a fat32 partition. In order to work properly, the partitions must be created in this order: fat32, ext2, linux-swap.
The linux-swap partition is used for a swap file on some builds. Not all builds use linux-swap, but I create one just in case I ever need it.
The ext2 partition is where your apps will be installed. I use 512 MB which gives me plenty of room but you can go larger like 1024 MB if you want. Parted only creates ext2 partitions.
When using the Linux command mkpartfs, you must tell it where to start and and end each partition. This can be done by taking the total SD card size and subtracting the linux-swap then ext2 partition sizes. See the following example for my 8 GB card that came with phone.
Command: mkpartfs primary fat32 0 7400 (start is 0 and end is Total C)
Command: mkpartfs primary ext2 7400 7912 (start is Total C and end is Total B)
Command: mkpartfs primary linux-swap 7912 7944 (start is Total B and end is Total A)
7944 Total A
-32 linux-swap
7912 Total B
-512 ext2
7400 Total C
Partition sizes for a 8 GB SD card.
Step 6.
Step 6: Check the sizes of your partitions. Use the command print again to display the partition sizes. If you made any mistakes you can return to Step 4 and remove them.
command: print (displays your partition information)
Step 7.
Step 7: Exit parted. For most users this is the final step.
command: quit (exit parted and return to # prompt)
Now you have a partitioned sdcard for A2SD

how to upgrade to EXT 3

That's a good question. I don't think the script eugene used has the upgrade feature. I couldn't upgrade_fs to get to ext 3 neither. That's why I left it out.

Some will probably want to know this as well... If I am trying to go back to a full SD card of just a FAT partition, I imagine when making the partitions, you would simply use:
Command: mkpartfs primary fat32 0 7944
And thats all, using your 8gb example size, correct?

lstevens86 said:
That's a good question. I don't think the script eugene used has the upgrade feature. I couldn't upgrade_fs to get to ext 3 neither. That's why I left it out.
Click to expand...
Click to collapse
thanks for the info. wish he added it cause i really wanted the lenged rom wit app2sd and i require ext 3 to work

PS C:\androidsdk\tools> adb shell
~ # parted /dev/block/mmcblk0
parted /dev/block/mmcblk0
/sbin/sh: parted: not found
~ #
So what do I do here? My Slide is rooted, I'm in clockwork, the SD card was unmounted (says mount /sdcard in the partitions menu)...
ADB shows the device is connected in recovery.

fermunky said:
Some will probably want to know this as well... If I am trying to go back to a full SD card of just a FAT partition, I imagine when making the partitions, you would simply use:
Command: mkpartfs primary fat32 0 7944
And thats all, using your 8gb example size, correct?
Click to expand...
Click to collapse
Yes this is correct, just make sure you rm 2 for ext 2 and rm 3 for swap
Sent from my T-Mobile myTouch 3G Slide using XDA App

lesstalk said:
PS C:\androidsdk\tools> adb shell
~ # parted /dev/block/mmcblk0
parted /dev/block/mmcblk0
/sbin/sh: parted: not found
~ #
So what do I do here? My Slide is rooted, I'm in clockwork, the SD card was unmounted (says mount /sdcard in the partitions menu)...
ADB shows the device is connected in recovery.
Click to expand...
Click to collapse
I've done 3 different sdcards so far. just make sure the card isn't mounted.
Sent from my T-Mobile myTouch 3G Slide using XDA App

so after i do this, and the partitions are good, how do i actually get my apps to the sd.

jefwallbanger said:
so after i do this, and the partitions are good, how do i actually get my apps to the sd.
Click to expand...
Click to collapse
Yes if the rom you install allows it

clockwork
Okay here's what I don't get....on eugenes guide to rooting the mt3gs, it says there is support for apps2sd....so my question is will eugenes method of rooting/clockwork recovery give me a2sd or will I need a rom with a2sd support in addition to root??? If not, how do I get a2sd to work with a rooted phone with the stock ROM?

lesstalk said:
PS C:\androidsdk\tools> adb shell
~ # parted /dev/block/mmcblk0
parted /dev/block/mmcblk0
/sbin/sh: parted: not found
~ #
So what do I do here? My Slide is rooted, I'm in clockwork, the SD card was unmounted (says mount /sdcard in the partitions menu)...
ADB shows the device is connected in recovery.
Click to expand...
Click to collapse
Im having the same issue. It can't seem to find "parted"
EDIT: Nevermind I formatted my card using windows and now its working. I'm guessing you just need to reformat and you should be good to go.

blaquerain79 said:
Okay here's what I don't get....on eugenes guide to rooting the mt3gs, it says there is support for apps2sd....so my question is will eugenes method of rooting/clockwork recovery give me a2sd or will I need a rom with a2sd support in addition to root??? If not, how do I get a2sd to work with a rooted phone with the stock ROM?
Click to expand...
Click to collapse
The stock Rom doesn't support a2sd. So you need to install one that does. It has nothing to do with the recovery. Eugene's SlideMeRoot5r1 is pretty much stock with A2SD. You should install it and check it out

Everytime i try this i keep getting not found i even formatted through windows not clue on whats going on any ideas the sd card wasnt mounted in recovery i dunno what to do?

Yeah the same thing is happening now. And whats worse is now my 8 gig card is now only 6. :/ lol
EDIT: If the ~ tilde shows up it doesnt work. But if it doesn't show up it works. I'm not to sure why or whats causing this but its something.

This is sweet been looking for this. Thanks.

I guess is not just me. I have tried this many times and still not able to get any results from this process.
Is there something we all missing or there is a step not mentioned on the istructions that we can't seen to overcome. This just another tedious process to get a partition on your sdcard sucessfully.
I think I have a class 2 4G

riverajuan said:
I guess is not just me. I have tried this many times and still not able to get any results from this process.
Is there something we all missing or there is a step not mentioned on the istructions that we can't seen to overcome. This just another tedious process to get a partition on your sdcard sucessfully.
I think I have a class 2 4G
Click to expand...
Click to collapse
On a 4gb card the numbers are different
Sent from my T-Mobile myTouch 3G Slide using XDA App

Cammarratta said:
Im having the same issue. It can't seem to find "parted"
EDIT: Nevermind I formatted my card using windows and now its working. I'm guessing you just need to reformat and you should be good to go.
Click to expand...
Click to collapse
so you got apps2sd working w/o changing to a different rom????

Your using a command shell... adb doesn't come with parted. You have to dl the command and push it to /system/bin
Google "Linux command gparted binary"
Sent from my T-Mobile myTouch 3G Slide using XDA App

Related

Looking for a Partition Manager thats works with sdcards

I accidentally made an extra partition on my sd that i want to remove
im not looking to spend money on partition software
can anyone help me out
TIA
gparted should work and is free.
had no luck with that one......
Ra recovery can partion
The sd card for you if you're root
-------------------------------------
Sent via the XDA Tapatalk App
format the card in your phone from settings
format the card in your phone from settings
Click to expand...
Click to collapse
This fill only format the fat partition not any others. I thought the same when I partitioned my card with ext2, then formatted and my ext2 wad still there while the fat was clean.
-------------------------------------
Sent via the XDA Tapatalk App
t2noob said:
This fill only format the fat partition not any others. I thought the same when I partitioned my card with ext2, then formatted and my ext2 wad still there while the fat was clean.
-------------------------------------
Sent via the XDA Tapatalk App
Click to expand...
Click to collapse
thanks everyone i had success with this tutorial
maybe we can sticky this for anyone who needs it here you go
http://forum.xda-developers.com/showthread.php?t=534714
How about just booting into Amon_RA's recovery boot (v 1.6.2) and using "sdparted" ???
Note I said sdparted, not "parted".
Obviously, if you want to save junk from either the FAT or ext[2,3,4] partition on your card beforehand, you need to take steps to do so. (Hint: adb is running when Amon_RA recovery boots, and "adb pull" works recursively, if you want - but you will need enough Linux smarts to mount partitions on the SD card yourself).
Code:
$ adb shell
/ #
/ # sdparted --extsize 0M --swapsize 0
checking script requirements...done
unmounting all partitions...done
to continue, all existing partitions must be removed.
this action will remove all data from your sdcard.
do you want to continue? (Y/n) Y
removing all partitions...done
total size of sdcard=7948MB
the following actions will be performed:
-create 7948MB fat32 partition
do you want to continue? (Y/n) Y
performing selected actions...
creating fat32 partition...done
retrieving current sdcard information...
Model: SD SU08G (sd/mmc)
Disk /dev/block/mmcblk0: 7948MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 512B 7948MB 7948MB primary fat32 lba
script log is located @ /data/sdparted.log
bftb0
bftb0 said:
How about just booting into Amon_RA's recovery boot (v 1.6.2) and using "sdparted" ???
Note I said sdparted, not "parted".
Obviously, if you want to save junk from either the FAT or ext[2,3,4] partition on your card beforehand, you need to take steps to do so. (Hint: adb is running when Amon_RA recovery boots, and "adb pull" works recursively, if you want - but you will need enough Linux smarts to mount partitions on the SD card yourself).
Code:
$ adb shell
/ #
/ # sdparted --extsize 0M --swapsize 0
checking script requirements...done
unmounting all partitions...done
to continue, all existing partitions must be removed.
this action will remove all data from your sdcard.
do you want to continue? (Y/n) Y
removing all partitions...done
total size of sdcard=7948MB
the following actions will be performed:
-create 7948MB fat32 partition
do you want to continue? (Y/n) Y
performing selected actions...
creating fat32 partition...done
retrieving current sdcard information...
Model: SD SU08G (sd/mmc)
Disk /dev/block/mmcblk0: 7948MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Number Start End Size Type File system Flags
1 512B 7948MB 7948MB primary fat32 lba
script log is located @ /data/sdparted.log
bftb0
Click to expand...
Click to collapse
thanks friend but i got thigs all situated thanks to that tutorial i posted right above you i did everything like you said though....i think we should add the info to the stickies
DS36 said:
thanks friend but i got thigs all situated thanks to that tutorial i posted right above you i did everything like you said though....i think we should add the info to the stickies
Click to expand...
Click to collapse
My bad for not reading every post and all links. That one is much more comprehensive, including descriptions of possible errors.
LOL, that thread is written by the maintainer of the script used on Amon_RA's recovery. No wonder it's detailed!
One thing he didn't cover is that the script has a help menu, too; if you give
/ # sdparted --help
a shot, it's plain to see that that script should be easy enough for a noob to use...
..especially since it does protective checks and also does the post-partitioning FS formatting.
bftb0

[Tut/Guide] A2SD setup (uses EXT partition) for Froyo FRF50/FRF83/FRF85B

I've seen numerous questions on how to do this and feel its very necessary since we only have 200960KB of space in /data.
Running out of space so quickly on your superphone is no fun.
First off: If your not technically inclined you'd do well to use a ROM with A2SD (EXT) pre-installed.
What this does:
Moves ALL your apps to the EXT partition on your SD card
Moves even the dalvik cache to the SD card
Gives you the space you need to install every single live wallpaper, widget, or app you want.
Prerequisites:
You have a rooted Froyo ROM. (without A2SD of course)
Your SD card has a working EXT2 or EXT3 partition. See the Darktremor thread on how to create one. (check the references section below)
You have a good recovery image installed. I use AmonRa 1.70
You have the command line tools ADB and FASTBOOT installed, and the Nexus USB driver installed.
The steps that should get you there:
Download and put "a2sd-2.7-update3-signed.zip" on the root of the sd card. Get the latest from the Darktremor thread.
Download a boot.img that has the required init.rc changes needed to automatically start A2SD. Get it from here (mediafire)(Thanks Leonnib4) or here (rapidshare) or from a kang-o-rama ROM.
Make directory /system/sd
Code:
adb remount
adb shell mkdir /system/sd
Reboot to recovery
Code:
adb reboot recovery
(in recovery, phone) Nandroid backup.
(OPTIONAL, in recovery) Wipe SD:EXT partition. (not the whole SD CARD, just the EXT partition). Useful if you had junk lying around from a previous ROM. Note that this will delete all the apps you had on the ext partition.
(in recovery, phone) Flash "a2sd-2.7-update3-signed.zip"
(in recovery, phone) Power off the phone. (not reboot)
Start the phone in bootloader mode, with the USB cable plugged in.
While the phone is off, hold the trackball down and then press the power button.
(in bootloader mode, desktop console). On your desktop/laptop open a shell (start->run->cmd in windows) and run the following commands.
Code:
#check if the phone is connected ok, you should see your device after running the first command
fastboot devices
#flash the boot image.
fastboot flash boot boot.img
#reboot your phone
fastboot reboot
Either as your phone starts, or after its ready, Run the following commands via adb. I ran it as soon as the phone connected to adb. (nexus loading animation)
Code:
adb remount
#enable a2sd
adb shell a2sd install
#also move the dalvik cache to sd card.
adb shell a2sd cachesd
#check if all is ok
adb shell a2sd check
#reboot to test that the phone starts ok
adb reboot
You're all set. To check that its running do one or all of the following:
- run: adb shell a2sd check
Code:
C:\Users\me\Desktop>adb shell a2sd check
Starting Darktremor A2SD version 2.7 Update 3
[ ] Mounting /system as read-write
[ ] Starting A2SD in check mode
[ ] Running A2SD Check Program.
[ ] Searching for Mount Point...
[x] Mount point /system/sd located.
[ ] Checking for ext partition
/dev/block/mmcblk0p2 /system/sd ext2 rw,noatime,nodiratime,barrier=1,data=ordered 0 0
[x] Ext partition is mounted.
[ ] Checking A2SD links.
A2SD Status Report
===============================================================
Apps - [-] Linked to SD Card.
[-] File .noa2sd not found.
[COLOR="red"][x] Programs run from SD card[/COLOR]
To run from internal storage, type a2sd remove
Private Apps - [-] Linked to SD Card.
[-] File .noa2sd not found.
[COLOR="red"][x] Private Programs run from SD card[/COLOR]
To run from internal storage, type a2sd remove
Dalvik Cache - [-] Symbolically Linked.
[-] File .dalvikcache found.
[COLOR="red"][x] Dalvik runs from SD card[/COLOR]
To run from internal storage, type a2sd nocache
To run from /cache partition, type a2sd cachepart
Swap - [!] Partition not present.
[!] Swap does not start.
ZipAlign - [!] Not running at boot.
Property Patch - [-] File System Ready property
found.
[COLOR="red"][x] Boot image init.rc patched.[/COLOR]
[ ] Setting File System Ready property to 1.
[ ] Remounting /system to read-only.
- run: adb shell df
Code:
C:\Users\me\Desktop>adb shell df
/dev: 201636K total, 12K used, 201624K available (block size 4096)
/mnt/asec: 201636K total, 0K used, 201636K available (block size 4096)
/system: 148480K total, 111248K used, 37232K available (block size 4096)
[COLOR="Blue"]/data: 200960K total, 60716K used, [B]140244K available[/B][/COLOR] (block size 4096)
/cache: 97280K total, 1672K used, 95608K available (block size 4096)
[COLOR="red"]/system/sd: 702873K total, [B]172189K used[/B], 530684K available[/COLOR] (block size 1024)
/mnt/sdcard: 14898512K total, 9349176K used, 5549336K available (block size 8192)
/mnt/secure/asec: 14898512K total, 9349176K used, 5549336K available (block size 8192)
/mnt/asec/com.google.android.stardroid-1: 3124K total, 1504K used, 1620K available (block size 4096)
/mnt/asec/com.tmsoft.whitenoise.lite-1: 7276K total, 5856K used, 1420K available (block size 4096)
-run: adb shell ls -l /data
Code:
C:\Users\me\Desktop>adb shell ls -l /data
drwxr-x--- root log 2010-05-24 09:04 dontpanic
drwx------ system system 2010-06-26 23:18 backup
drwxrwx--x system system 2010-06-26 22:16 data
drwxrwxrwx root root 2010-06-26 18:57 a2sd
drwx------ root root 2010-06-26 18:57 property
drwxrwxr-x system system 2010-06-26 18:57 anr
drwxrwx--x shell shell 2010-06-26 18:57 local
lrwxrwxrwx root root 2010-06-26 19:07 [COLOR="Red"]app -> /system/sd/app[/COLOR]
lrwxrwxrwx root root 2010-06-26 19:07 [COLOR="red"]app-private -> /system/sd/app-private[/COLOR]
lrwxrwxrwx root root 2010-06-26 19:07 [COLOR="red"]dalvik-cache -> /system/sd/dalvik-cache[/COLOR]
drwxrwx--t system misc 2010-06-26 23:18 misc
drwxrwxr-x system system 2010-06-26 23:18 system
drwxr-xr-x system system 2010-06-26 18:57 tombstones
drwxrwx--- root root 2010-05-24 09:04 lost+found
Referenced Threads:
Darktremor A2SD (Apps2SD)
NexusOne Q&A thread
Notes:
I am not responsible if something goes wrong. nandroid backup and understand what you are doing!
This will probably work on other Froyo ROMS too.
You can install a custom kernel after installing this boot image. Just dont install a complete boot image. Boot image= ramdisk+kernel.
Thanks to Darktremor/tkirton and leonnib4.
nice post!
great tip, been looking to get ext apps2sd in froyo for a while and kmobs and the rest of the team refuse to share.
after doing this you can flash any kernel. this should be included in all froyo roms
Nice job per usual britoso
Awesome post...
Nice job by summing up all that in one thread.
-- nevermind --
So I see you did not solve the boot.img issue. Just wanted to warn you that I rapidly put mine on rapidshare because I thought it was just for you -- so it might be limited to 10 downloads.
-- nevermind --
I also wrote a set of only 3 scripts that seems to do the job:
- one that mounts the ext partition if exists, at boot (boot.img + 10a2sd)
- one that can put app2sd on or off (xbin/a2sd)
- one that can put dalvik2sd on or off (xbin/swap)
- and also one for auto zipalign at boot (zaab)
yeah... that maked four. basicly a2sd takes only 2 scripts
All also inspired from Darktremor's work (from a2sd-2.7-2 from another thread).
All those scripts are on my github repo.
See if it works.
Thanks to Darktremor, britoso, Cyanogen and all of you who made it possible. So much free space now!!!
Thanks for the info.
Is this a different method of apps2sd than implemented on Paul's MoDaCo r19 with apps2sd? If I have that installed already do I need to go through this process? Thanks
i used leo's custom spare parts and it enabled a2sd for me. i'm running frf83 deoxed. i tried partitioning my sd card via amonra and via terminal on my mac, and i couldn't it to work right. i'll try your method method later on.
jamaa124 said:
i used leo's custom spare parts and it enabled a2sd for me. i'm running frf83 deoxed. i tried partitioning my sd card via amonra and via terminal on my mac, and i couldn't it to work right. i'll try your method method later on.
Click to expand...
Click to collapse
partitionning via amon_ra did not work?
unlikely...
leonnib4 said:
partitionning via amon_ra did not work?
unlikely...
Click to expand...
Click to collapse
no dude, i couldn't get it to work for me.
jamaa124 said:
no dude, i couldn't get it to work for me.
Click to expand...
Click to collapse
Very unlikely.
Is your sdcard ok? I mean, really?
Because even with darktermor method you ll need to partition your sdcard..
Maybe try another recovery..
leonnib4 said:
Very unlikely.
Is your sdcard ok? I mean, really?
Because even with darktermor method you ll need to partition your sdcard..
Maybe try another recovery..
Click to expand...
Click to collapse
my sdcard is fine. i thought that there was something wrong with it at first, but there was nothing wrong with it. now, once installed the spare parts that you include in your roms, everything seems to work fine for me.
jamaa124 said:
my sdcard is fine. i thought that there was something wrong with it at first, but there was nothing wrong with it. now, once installed the spare parts that you include in your roms, everything seems to work fine for me.
Click to expand...
Click to collapse
Ok good.
So it means you sdcard has been partitioned.
Im interrested in your case: how did you knew partinioning did not work on recovery, then with your mac?
In fact: what did not work how did you know and have you any error message?
Thx
leonnib4 said:
Ok good.
So it means you sdcard has been partitioned.
Im interrested in your case: how did you knew partinioning did not work on recovery, then with your mac?
In fact: what did not work how did you know and have you any error message?
Thx
Click to expand...
Click to collapse
i couldn't tell that there was a problem from the bootloader or from my mac because everything seemed fine. if i encountered any problems while trying to partition my card, i would reformat the entire card and start over. i followed all of the directions...from xda and various youtube videos. if you go under disk utilities on a mac, it'll show whether or not your sd card has been partitioned. everything seemed fine. i didn't notice the problem until i went move few apps to my sdcard and that's when i realized that the button was still dark. i think that i may have messed up using terminal, somewhere along the route. i'm guessing that your spare parts must've filled in the missing line for me. everything is working fine now.
Will this work for the frf85b build?
does it work with AOSP 2.2 FRF83?I pushed the boot.img and the A2SD version 2.7 Update 3r1 but it can't mount the ext partition
billp said:
does it work with AOSP 2.2 FRF83?I pushed the boot.img and the A2SD version 2.7 Update 3r1 but it can't mount the ext partition
Click to expand...
Click to collapse
I built the boot.img for FRF83.
It won't only work with that boot.img...
What have you tried?
What are the errors?
leonnib4 said:
I built the boot.img for FRF83.
It won't only work with that boot.img...
What have you tried?
What are the errors?
Click to expand...
Click to collapse
I followed the instructions above. here's the result...
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
I renamed the boot.img to app2extboot.img to recognize it
I remind you that I use AOSP 2.2 FRF83 and NOT LeoFroyo or Kang-o-rama. Is it compatible or not?
billp said:
I followed the directions above. here's the result...
I renamed the boot.img to app2extboot.img to recognize it
I remind you that I use AOSP 2.2 FRF83 and NOT LeoFroyo or Kang-o-rama. Is it compatible or not?
Click to expand...
Click to collapse
I could bet you did not create your ext partition under Amon_RA's recovery
Your filesystem contains unsupported flags.
Try again with Amon_RA's: ext2 then ext3
Market issue
I am having a huge issue with the market when i use the ext3 a2sd, i have had a ext3 partition since i had my g1 and everything worked fine, but every froyo A2SD old style, i go to market to install a app and it downloads and get stuck at installing. When i go to applications all of my apps that are on my ext3 partition are constantly "computing" it is really getting on my nerves i have tried 4 different roms and can never get past the market issue....
anyone else experiencing this issue?

How to boot UrukDroid from internal flash disk on Archos 70IT (Update: Uruk 0.6)

Install Uruk 0.3 on second internal flash disk of Archos
UPDATE
At the last end of this guide you will find the steps necessary to upgrade to Uruk 0.6 from Uruk 0.3 or 0.4.
Near the end of this guide you will find the steps necessary to upgrade to Uruk 0.4.2 from Uruk 0.3 or to install it for the first time.
Please note.
If you are upgrading from Uruck 0.3 to 0.4.2 and installed google market hack before upgrade, after upgrade the market will be broken. To solve the problem reed the last step of this guide.
I've manage to boot from the second partition of the second internal flash of 8GB (/dev/block/mmcblk1p2) of my Archos 70IT Urukdroid vers 03 prepared by $aur0n on this post.
Thanks $aur0n for your awesome work.
It may work for other archos generation 8 too, except Archos 70 IT 250GB (i think that model doesn't have a second internal flash disk to boot from for SDE, but the owners can do it creating the 2 needed partitions on the HDD).
I've done it because:
- my micro sdcard is slow compared to internal flash
- i can mount correctly micro sdcard and second internal flash disc in Windows and linux by connecting Archos via USB and
- my sdcard is free. I can boot without sdcard in, take off from archos every time i want and upload files from a card reader or connecting the archos 70 via usb.
If you want to try it, be sure on what you are doing (linux knowledge is needed).
Try it on your own risk.
I don't have any responsibility if you brick your device (actually is hard to brick it following the guide, but pay attention please).
So if you are sure, read carefully this post and ask before if something is not clear enough for you.
I will try to answer as soon as possible (I'm actually a bit busy :-()
First of all install SDE, if you haven't already done (you can get information about it and download the SDE firmware from archos web page archos web page
Attention: Doing that You void your warranty...
Here the Archos notes:
Important notices to be acknowledged before downloading and installing the SDE firmware:
Once the SDE firmware is installed on a device, this device will be watermarked and ARCHOS will be able to detect that this firmware has been installed once.
Installing the SDE firmware is considered by ARCHOS as a voiding of the warranty and ARCHOS declines all liability and responsibility for any issues resulting from the installation of this SDE firmware.
ARCHOS strongly advises that only experts in embedded software development should install this firmware.
This firmware is provided "as is" and is not supported by ARCHOS.
Before following the steps required to install Uruk 0.3 some clarifications:
What you need to have:
- Archos 70 IT with terminal and SDE installed.
- Linux machine (nativly, visualized or LiveCD)
- Optionally Windows PC
Storage map of Archos 70 IT:
a) The first internal flash disk is of approximately 500MB (device /dev/block/mmcblk0) which is used by stock archos firmware and not changed by this guide.
Pay great attention playing with it, you may brick forever your Archos.
This flash disk have 4 partition and the block devices, mountpoints, filesystems type and size are as the following:
The first devices is "/dev/block/mmcblk0p1", mountpoint "/mnt/rawfs", type of filesystem "rawfs", size 32MB
The second devices is "/dev/block/mmcblk0p2", mountpoint "/mnt/system", type of filesystem "ext3", size 119MB
The third devices is "/dev/block/mmcblk0p3", mountpoint "/cache", type of filesystem "ext3", size 30MB
The fourth devices is "/dev/block/mmcblk0p4", mountpoint "/data" (mountpoint only by archos firmware), type of filesystem "ext3", size 300MB
b) The second internal flash disk is of approximately 7,5GB (device /dev/block/mmcblk1) which is used by this guide to boot SDE from and to accommodate the /data mountpoint (not any more on the "/dev/block/mmcblk0p4").
By stock archos firmware it has 1 partition (device /dev/block/mmcblk1p1), mountpoint "/mnt/storage", type of filesystem "fat32", size 7,5GB
After Uruk 0.3 installation it will have 3 partitions and the block devices, mountpoints, filesystems type and size will be as the following:
The first devices will be "/dev/block/mmcblk1p1", mountpoint "/mnt/storage", type of filesystem "fat32", size 5,5GB
The second devices will be "/dev/block/mmcblk1p2", mountpoint root "/", type of filesystem "ext4", size 500MB
The third devices will be "/dev/block/mmcblk1p3", mountpoint "/data", type of filesystem "ext4", size 1GB
C) The sdcard on device /dev/block/mmcblk2. On my case it have 1 partition (device /dev/block/mmcblk2p1), mountpoint "/mnt/storage/sdcard", type of filesystem "fat32".
Let's go:
The first step to do is to backup everything from your second internal flash disk (as above, it has 1 partition formated in fat32, 7,5GB capacity), just for backup purpose.
The simplest way is to connect your archos via usb to your linux box and copy directly that directory to a new directory on your linux with the default graphical file explorer of your distribution.
In my case it mounts automatically to /media/A70S (device is /dev/sdb1):
/dev/sdb1 on /media/A70S type vfat (rw,nosuid,nodev,uhelper=hal,uid=1000,utf8,shortname=mixed,flush)
Click to expand...
Click to collapse
If doesn't mount automatically in your case, find it using "dmesg" command on a terminal after connection complete and mount it manually.
Or you can copy it on your Windows PC (connect Archos via usb, drive mount automatically to A70S).
After backup, don't disconnect your Archos from linux. You have to resize the mounted Archos disk form 7,5GB to 5,5GB.
The easiest way is to do it graphically with your distribution partition manager utility.
First umount it by right click->umount, then resize it letting on the right side of the disk 1,5GB free space.
Create other 2 partition on that free space, first of 500MB and the other with the remaining space approx. 960MB.
Then apply the changes on the partition manager and you will have now 3 partition on the second internal flash disk of your Archos.
The first one with 5,5GB and formated on fat32, the second one 500MB not formated and the third partition of 960MB not formated.
On my case the devices are respectively /dev/sdb1, /dev/sdb2 and /dev/sdb3.
The next step is to format the second and third partition with ext4 filesystems without huge option (as from $aur0n post) on a linux terminal as root:
mkfs.ext4 -O ^huge_file /dev/sdb2
mkfs.ext4 -O ^huge_file /dev/sdb3
Click to expand...
Click to collapse
When finished, just remove safely archos from your linux box.
From the archos open a terminal and just type:
ls /dev/block/mmcblk1*
Click to expand...
Click to collapse
The result will be:
/dev/block/mmcblk1 /dev/block/mmcblk1p1 /dev/block/mmcblk1p2 /dev/block/mmcblk1p3
Click to expand...
Click to collapse
The second partition (/dev/block/mmcblk1p2) will be your new rootfs
and the third one (/dev/block/mmcblk1p3) your new application area (/data).
On this step you are going to copy all the staff on /data (device /dev/block/mmcblk0p4 mounted on /data)
to the third partition of the second internal flash (/dev/block/mmcblk1p3).
Mount the third partition first:
mkdir /tmp/data
mount /dev/block/mmcblk1p3 /tmp/data
Click to expand...
Click to collapse
and copy:
cp -rp /data/* /tmp/data
sync
umount /tmp/data
Click to expand...
Click to collapse
If you get any problems on coping (permissions) then the only way to do it correctly is to use "tar" to make a archive of data to a file on the first partition of the second internal flash disk (/dev/block/mmcblk1p1 mounted on /mnt/storage) like:
tar -cfvz /mnt/storage/data_app.tar.gz /data/
Click to expand...
Click to collapse
and then connect archos via usb to your linux computer (your three partition of the internal flash now will mount in automatic, let say /media/A70S, /media/disk1 and /media/disk2 from the devices /dev/sdb1, /dev/sdb2 and /dev/sdb3)
Now you have to extract the previous tar file (data_app.tar.gz) to the /media/disk2 (the third partition of archos internal flash disk mounted supposedly at /media/disk2):
cd /media/disk2
tar -zvxf /media/disk1/data_app.tar.gz
sync
umount /media/disk2
Click to expand...
Click to collapse
The next step, download the Uruk 0.3 version of rootfs (rootfs.tar.gz) from this link, and kernel image (zImage) from from this link on the /tmp directory of your linux box. I want to remember that this files are prepared and postet from $aur0n on this post.
If you are still connected via usb with your archos (if not, connect it),extract the rootfs (rootfs.tar.gz) directly on the mount point of the second flash partition (as above in my case is /dev/sdb2 mounted on /media/disk1) on linux:
cd /media/disk1
tar -zvxf /tmp/rootfs.tar.gz
Click to expand...
Click to collapse
Change the following lines of the init.rc file (mount point of root filesystem):
mount ext3 /dev/block/mmcblk0p4 /data noatime nosuid
# Uncomment this
# mount ext4 /dev/block/mmcblk2p2 /data noatime
with those:
#mount ext3 /dev/block/mmcblk0p4 /data noatime nosuid
# Uncomment this
mount ext4 /dev/block/mmcblk1p3 /data noatime
Change the line on the file/media/disk1/syste/etc/vold.fsatb:
#dev_mount_lun volume_sdcard /mnt/storage/sdcard 3 /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk2p3
with that:
dev_mount_lun volume_sdcard /mnt/storage/sdcard auto /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk2
sync
umount /media/disk1
Click to expand...
Click to collapse
and remove safely archos from the linux box and shutdown Archos.
Download the initramfs.cpio.gz_Uruk_0.3.zip from here (or from the attachment on the end of this post) and unzip it on the /tmp folder of you linux box.
Flash the initramfs.cpio.gz and zImage (remember , you downloaded zImage on the step 4 and placed it already on /tmp) on SDE environment doing:
- While power on your archos, press the "Volume -" button
- Go to "Recovery System",then "Developer Edition Menu"
- Select "Flash kernel and Initramfs".
- Attach your Archos via USB to linux computer. Archos will automatically mount, in my case is A70S_REC mounted on /media/A70S_REC/. Copy the files (initramfs.cpio.gz and zImage) from /tmp folder.
cp initramfs.cpio.gz zImage /media/A70S_REC/
Click to expand...
Click to collapse
Disconnect safely archos, then push "Ok", power and the archos will reboot.
- Press the "Volume -" to boot to the ""Boot Menu" and choose "Developer Edition" or just while booting press both "Volume -" and "Volume +" to boot directly to the "Developer Edition".
You are done.
Enjoy booting from internal flash (SDE edition).
Update: Uruk 0.4.2
There are 2 possibilities:
- You want to upgrade from Uruk 0.3
- Install Uruk 0.4.2 for the first time (You are on stock archos firmware).
Let's begin with the upgrade from Uruk 0.3 to Uruk 0.4.2
First of all download the Uruk 0.4.2 rootfs prepared from $aur0n UrukDroid-0.4.2-rootfs.rar on your linux box.
Download also UrukDroid-0.4.2-kernel.rar from here (or from the attachment on the end of this guide).
It's is $aur0n's one with the modifications to boot and mount /data from second internal flash.
Copy the above 2 files on the folder /tmp/archos of your linux machine. In my case is the 2 downloaded files are
under /home/shklifo/Download folder:
mkdir /tmp/archos
cd /tmp/archos
cp /home/shklifo/Download/UrukDroid-0.4.2-kernel.rar /home/shklifo/Download/UrukDroid-0.4.2-rootfs.rar .
Click to expand...
Click to collapse
Unrar both of them (if you don't have rar utility, just install it), giving the command:
rar x UrukDroid-0.4.2-kernel.rar
rar x UrukDroid-0.4.2-rootfs.rar
Click to expand...
Click to collapse
When the unrar process goes ok you will see the following on terminal (example of UrukDroid-0.4.2-kernel.rar):
[email protected]:/tmp/archos# rar x UrukDroid-0.4.2-kernel.rar
RAR 3.90 beta 2 Copyright (c) 1993-2009 Alexander Roshal 3 Jun 2009
Shareware version Type RAR -? for help
Extracting from UrukDroid-0.4.2-kernel.rar
Extracting zImage OK
Extracting initramfs.cpio.gz OK
All OK
Click to expand...
Click to collapse
After that you will have the following files on /tmp/archos:
[email protected]:/tmp/archos# ls -lrt
totale 245668
-rw-r--r-- 1 root root 0 2011-01-17 12:10 UrukDroid-copy_data.cmd
-rw-r--r-- 1 root root 120854073 2011-01-21 17:34 UrukDroid-rootfs-upgrade.tgz
-rwxr-xr-x 1 root root 2255648 2011-01-21 17:57 zImage
-rw-r--r-- 1 root root 1733826 2011-01-22 10:26 initramfs.cpio.gz
-rw-r--r-- 1 root root 119128315 2011-01-22 10:26 UrukDroid-0.4.2-rootfs.rar
-rw-r--r-- 1 root root 3985013 2011-01-22 10:36 UrukDroid-0.4.2-kernel.rar
Click to expand...
Click to collapse
You are upgrading and you have all the applications on second internal flash disk already, so just remove the UrukDroid-copy_data.cmd, you don't need it:
rm UrukDroid-copy_data.cmd
Click to expand...
Click to collapse
Now you have to copy UrukDroid-rootfs-upgrade.tgz to the rootfs of the archos (second partition of the second internal flash disk mounted on / of type ext4 with 500MB space).
To do that just connect archos via usb to your linux box and all the tree partition of archos second internal flash will be mounted automatically.
To verify where those partition are mounted just type:
mount
Click to expand...
Click to collapse
on a linux terminal and on my case is as following:
[email protected]:/tmp/archos# mount
...
/dev/sdb1 on /media/A70S type vfat (rw,nosuid,nodev,uhelper=hal,uid=1000,utf8,shortname=mixed,flush)
/dev/sdb2 on /media/disk type ext4 (rw,nosuid,nodev,uhelper=hal)
/dev/sdb3 on /media/disk-1 type ext4 (rw,nosuid,nodev,uhelper=hal)
/dev/sdc1 on /media/disk-2 type vfat (rw,nosuid,nodev,uhelper=hal,uid=1000,utf8,shortname=mixed,flush)
Click to expand...
Click to collapse
and "df -m" like:
[email protected]:/tmp/archos# df -m
/dev/sdb1 5622 2897 2725 52% /media/A70S
/dev/sdb2 485 244 216 53% /media/disk
/dev/sdb3 973 268 656 29% /media/disk-1
/dev/sdc1 15266 1157 14110 8% /media/disk-2
Click to expand...
Click to collapse
So in my case the second partition of the second internal archos flash disk of 485MB is:
/dev/sdb2 485 244 216 53% /media/disk
Click to expand...
Click to collapse
mounted on /media/disk
Then just copy the UrukDroid-rootfs-upgrade.tgz file on the second partition of the second internal archos flash disk, like in my case:
cp /tmp/archos/UrukDroid-rootfs-upgrade.tgz /media/disk/
Click to expand...
Click to collapse
Safely disconect archos from the linux box and shutdown completely your archos.
Now you have to flash initramfs (initramfs.cpio.gz) and kernel (zImage) to your archos from "Recovery Menu" (you know already how to do it),
or if you forget it just do the following:
- While power on your archos, press the "Volume -" button
- Go to "Recovery System",then "Developer Edition Menu"
- Select "Flash kernel and Initramfs".
- Attach your Archos via USB to linux computer. Archos will automatically mount, in my case is A70S_REC mounted on /media/A70S_REC/. Copy the files (initramfs.cpio.gz and zImage) from /tmp/archos folder.
cp initramfs.cpio.gz zImage /media/A70S_REC/
Click to expand...
Click to collapse
Disconnect safely archos, then push "Ok", power and the archos will reboot.
- Press the "Volume -" to boot to the ""Boot Menu" and choose "Developer Edition" or just while booting press both "Volume -" and "Volume +" to boot directly to the "Developer Edition".
You will see the UruckDroid 0.4 screen with "Initramfs: Loading ...." than Rootfs: Loading .... and finally you will see the Uruck Desktop.
Enjoy
Install Uruk 0.4.2 for the first time
For those who whant to install Uruk 0.4.2 for the first time (now it's simplier that Uruk 0.3) will do:
a) First backup, create the partitions and filesystems on the second internal flash disk of archos (step 1
and step 2 of the Uruk 0.3).
You don't need anymore step 3 (copy of /data folder), because Uruk 0.4.2 do it automatically.
b) Then following step by step the guide Let begin with the upgrade from Uruk 0.3 to Uruk 0.4.2, except removing UrukDroid-copy_data.cmd file, because you need it to copy automatically /data files.
When you are on the step "copy the UrukDroid-rootfs-upgrade.tgz file on the second partition of the second internal archos flash disk", you need to copy additionaly UrukDroid-copy_data.cmd like:
cp /tmp/archos/UrukDroid-rootfs-upgrade.tgz /media/disk/
cp /tmp/archos/UrukDroid-copy_data.cmd /media/disk/
Click to expand...
Click to collapse
Than follow till the end the guide Let begin with the upgrade from Uruk 0.3 to Uruk 0.4.2.
Enjoy
OPTIONAL: Install google market.
If you have already istalled google market (using gAppsInstaller for example), you have to uninstall it (market/vending) first.
Then download UrukDroid-0.4.2-GoogleMarket.zip and copy it on the root (/) filesystem of archos (see above on the upgrade section an do the same steps of copying UrukDroid-rootfs-upgrade.tgz to archos rootfs).
Reboot archos.
NOTE
If you are upgrading from 0.3 version to 0.4.2 and installed before the google market from kenyu73 like i did, then the market will be broken and doesn't work any more.
To get it back, you have to remove all the google applications from SDE (Uruk 0.4.2) including the kenyu73's installer (gAppsInstaller).
Then install the market as on the previuos step OPTIONAL: Install google market downloading the file UrukDroid-0.4.2-GoogleMarket.zip and following the instructions.
After rebooting archos on SDE, you need to fix it, because you can't access the whole market (missing some "protected applications" like copilot etc).
To fix just do the following steps as kenyu73 explain on his post :
Go to Settings-->Manage Applications-->All-->Market (Clear Cache then 'Force Stop', DO NOT clear data).
Setting-->Manage Applications-->All-->Google Services Framework (Clear data then 'Force Stop').
Reboot.
Click to expand...
Click to collapse
I've done it twice the fix step, and after that no problem anymore. All the google applications (downloaded from the fresh working market) are working correctly as before.
Update: How to upgrade to Uruk 0.6 from Uruk 0.3 or 0.4.2
There are 2 possibilities:
a) The first one is the simplest one.
Just download the $auron Uruk 0.6 UrukDroid_0.6-EasyInstall.rar posted on this post, extract it on your computer and delete the file initramfs.cpio.gz, because we don't need it.
Then download the file initramfs.cpio_Uruk_0.6.gz.rar in attachment on the end of this post and extract it on the same directory of your computer (this is the initramfs that you will flash on SDE prepared from $auron and can be found on the /root/ directory of $auron new rootfs UrukDroid-install.tgz).
Then boot Archos on stock Android and connect it to your linux box via USB. The root filesystem of Archos (/dev/block/mmcblk1p2 on Archos) will be mounted on some directory on linux automatically, just find it or manually mount it (it's the filesystem with 500MB space, to be sure just type "df -h" on a terminal).
With root on a linux terminal go to that directory (in my case was /media/Disk-1) and remove all the files there:
Code:
rm -rf *
Then copy the UrukDroid-install.tgz extracted before from UrukDroid_0.6-EasyInstall.rar on the above directory.
So, you will have only the file UrukDroid-install.tgz on your rootfs directory of Uruk.
Then disconect safely Archos from your linux box and flash initramfs.cpio.gz and zImage files on SDE (you know how to do that ...) and boot to SDE.
That is
Uruk 0.6 will automatically copy everything needed as you will see on the boot time.
You have to do a last thing to be able to mount automatically the sdcard on Uruk 6. Uncomment the sdcard line on the file /system/etc/vold.fsatb like:
Code:
dev_mount_lun volume_sdcard /mnt/storage/sdcard auto /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk2
This is needed on the second method too (the one below).
Who want to install Uruk (version 0.6 in this case) for the first time on internal, must create and format the 2 partitions of the second internal flash disk (like on the beginning of this post described) and follow step by step the above method and at the end copy everything from the data partiotion (last partition of the first internal flash /dev/block/mmcblk0p4) to the third partition of the second flash disk (/dev/block/mmcblk1p3).
b) The second method is more complicated, but works also good.
You just install Uruk 0.6 to a sdcard like on this $auron post, than shutdown Archos, put the microsd card on a card reader connected to a linux PC and with root make a tar archive of the entire rootfs (root filesystem) of Uruk 0.6 (the second partition of the sdcard with 500MB of space on ext4 filesystem) to a tar file that you can put to the first partition of the sdcard (the fat partition of the sdcard).
Eject the sdcard and put on Archos. Turn on Archos and from a terminal on Uruk as root mount the second partition of the flash disk (/dev/block/mmcblk1p2) on a directory and just delete ("rm -rf") everything on there and then extract the tar archive there.
So, you just put everything from rootfs of the sdcard to internal flash, with correct permissions, timestamp, ownership etc.
Now just shudown Archos, take off the sdcard and boot.
This time it will Uruk 0.6 will boot from internal flash
Enjoy it
I wish I could understand more clearly how to do this with a fresh install...
This is what I am looking to do, using it on internal... but this might be a little too complicated for me.
What about 101?
Does this method applicable to Archos 101 model too?
If someone already have been tried it on 101, please reply with details here, if any troubles you have after installation or any changes need to be done.
Also I am curious about does anyone have tried to connect USB thumb drive to the tablet with modified rom and root access? Do we still have any issues with USB drive recognition?
Is this applicable for UrukDroid 4.1 and The Archos IT 35?
well great work but i dont know if i get it to work and Im a little bit confused -
is it writable in windows per media player (mtp) or per explorer or both (with ext-x driver)?
yura-a said:
Does this method applicable to Archos 101 model too?
If someone already have been tried it on 101, please reply with details here, if any troubles you have after installation or any changes need to be done.
Click to expand...
Click to collapse
Why not. The 101 model have the second internal flash (8 or 16GB) as the 70 S model have. To be sure just type mount and df -m on a terminal in Archos device and you will see the flash drive (/dev/block/mmcblk1p1) formated in fat32 and mounted on /mnt/storage.
I only changed the mounting point on the file init, init.rc and /system/etc/vold.fstab from $aur0n files to be able to boot SDE from the second internal flash disk and doesn't change anything else, configuration file of specific model included.
yura-a said:
Also I am curious about does anyone have tried to connect USB thumb drive to the tablet with modified rom and root access? Do we still have any issues with USB drive recognition?
Click to expand...
Click to collapse
I'm still excpecting my host cable from Hong-Kong and can't try that, but i think will not be a problem.
good work
thanks
svennimann said:
Is this applicable for UrukDroid 4.1 and The Archos IT 35?
Click to expand...
Click to collapse
I do not own your device (it is a Archos 32 IT?), but if is that model, it got a 8GB internal flash like archos 70 IT. The firmware is the same for all archos generation 8 devices (with same configuration files change), but i haven't change them (and $aur0n too i think, but he can answer himself).
So just try it, if you have no problem of understanding all the steps on the first post. You can't break anything. And if it will not work (worse case) or have other problems you just have SDE installed (you can remove it if you want) and 2 more partition on the internal flash disk with some files on them.
You can just delete the partitions and risize (increment) the first partition as from stock. In all situation we are able to boot to stock firmware.
I only change the mountpoints as i wrote in the previous posts on the files init, init.rc and vold.fstab from uruk 0.3.
So mine and $auron solution changed only on the boot partition (mine is booting form the second partition of the internal flash disk, him from the second partition of sdcard) and the application data partition (mine on the third partition of the internal the flash, him on the third partition of the sdcard). All the other files are from him (thanks $aur0n).
I've not installed yet the 0.4.1, i got little free time actually and of the market problem (if i install the 0.4.1, i must uninstall the market on stock firmware and will be not able to access it from original/stock firmware).
But if i decide to install it, i will report here.
svennimann said:
well great work but i dont know if i get it to work and Im a little bit confused -
is it writable in windows per media player (mtp) or per explorer or both (with ext-x driver)?
Click to expand...
Click to collapse
Thanks, as i say above you don't loose anything trying to install it, only time
So, if i understand well your question, on my archos i'm able to access the first partition of the flash disk (it's a fat32 as from stock, only risezed in 5,5 GB) on my windows XP PC by usb connection to archos.
The second (boot partition 500MB) and the third (data application area of 1GB) partitions of internal flash disk are ext4 formated (stock ext3) and can't be mount on a windows PC, and for me have any sense mounting them on a PC.
The sdcard is accesible via usb connection (archos to PC) or via card reader. If you format it fat32 is in r/w mode (as i've done), ext3 or ext4 in readonly mode i think (not yet tried), because actually isn't out a driver to be able to write a linux partition on Windows.
From Ubuntu (connecting archos via usb) i can mount all in r/w mode (all the 3 partitions of the internal flash disk and sdcard too).
Later i will post some picture/command output (mount,ls) from Ubuntu.
In attachment a picture of the flash disk (A70S E: ) and sdcard (Disco rimovibile F: ) on my Windows XP macchine.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Just a suggestion.. Please be consistent with your instructions, 1 step your instructions are for linux and the next step would be for archos.
It's really hard to follow what needs to be done or how it should be done properly, considering you're messing around with the internal storage there's bigger chance of bricking your device.
I appreciate all your hard work and contributions here, it's just that it's not that user friendly.
GrandStar said:
Just a suggestion.. Please be consistent with your instructions, 1 step your instructions are for linux and the next step would be for archos.
Click to expand...
Click to collapse
Just to be clear, from archos terminal you have to do only 1 thing, copy or tar the "/data" mountpoint/directory, because this is the 4-th partition of the first internal flash disk (/dev/block/mmcblk0p4) and it can't be mounted on linux via usb connection.
All the other steps are from linux (the first step, you can do it from Windows too).
It's really hard to follow what needs to be done or how it should be done properly, considering you're messing around with the internal storage there's bigger chance of bricking your device.
Click to expand...
Click to collapse
There are 2 internal flash disk in Archos, /dev/block/mmcblk0 of 500MB (used by archos architecture and nobody is touching this flash disk, it's dangerous and you may brick your device) and /dev/block/mmcblk1 of 8GB which is used by the this guide to boot SDE from. So, if you are able to understand what you are doing and don't touch the first flash disk, than nothing can happens.
I appreciate all your hard work and contributions here, it's just that it's not that user friendly.
Click to expand...
Click to collapse
With that i'm in line with your thoughs, thanks. I will try to do it more simple and understandable.
I've followed all the instructions exactly. I'm good with linux, so it wasn't very hard, but when I booted into the Developer Edition at the end, I was at the Initial Setup Screen, like it didn't mount the /data partition. Also, I can't get ES to show the file system, so it doesn't seem to be rooted. Any ideas what's going on?
EDIT: You have a typo in the init.rc the change should be to mmcblk1p3, not mmcblk1p2.
EDIT: Another typo: "dev_mount_lun volume_sdcard /mnt/storage/sdcard auto /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk1" should be mmcblk2, not 1.
Now my data is there, and I can mount SD cards, but I still can't connect to a computer with a USB cable.
EDIT: All Fixed. I flashed a new kernel from http://forum.xda-developers.com/showthread.php?t=897877 and now have USB Storage working. I used the zImage from ardatdat's kernel with your initramfs.cpio.gz and the changes I listed above. Everything seems to work perfectly, and it's way faster than it was before. I was using Ardatdat's full kernel and booting from internal memory before. When I rotated the screen it used to take almost 10 seconds to update all the icons on the home screen. Now it takes less than 2-3 seconds to update. Great work on the EXT4 conversion! If you'll permit me, I'm going to write up a guide that incorporates my experience, and of course give you full credit.
Update: Just updated to UrukDroid 0.4.1. Needed a little more customization, but usb storage worked with the default 0.4.1 kernel instead of needing ardatdat's kernel. Currently testing to see which is better. Uruk says it's kernel has usb charging enabled, a very exciting possibility, but I kind of doubt it works on the A101IT.
msticninja said:
EDIT: You have a typo in the init.rc the change should be to mmcblk1p3, not mmcblk1p2.
EDIT: Another typo: "dev_mount_lun volume_sdcard /mnt/storage/sdcard auto /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk1" should be mmcblk2, not 1.
Now my data is there, and I can mount SD cards, but I still can't connect to a computer with a USB cable.
EDIT: All Fixed. I flashed a new kernel from http://forum.xda-developers.com/showthread.php?t=897877 and now have USB Storage working. I used the zImage from ardatdat's kernel with your initramfs.cpio.gz and the changes I listed above. Everything seems to work perfectly, and it's way faster than it was before. I was using Ardatdat's full kernel and booting from internal memory before. When I rotated the screen it used to take almost 10 seconds to update all the icons on the home screen. Now it takes less than 2-3 seconds to update. Great work on the EXT4 conversion! If you'll permit me, I'm going to write up a guide that incorporates my experience, and of course give you full credit.
Update: Just updated to UrukDroid 0.4.1. Needed a little more customization, but usb storage worked with the default 0.4.1 kernel instead of needing ardatdat's kernel. Currently testing to see which is better. Uruk says it's kernel has usb charging enabled, a very exciting possibility, but I kind of doubt it works on the A101IT.
Click to expand...
Click to collapse
Thanks for the corrections (you pay the needed attention), but i just modified the first post radically (easier).
Sure, you can do your own thread with your experience on the installation.
I will install Uruk 0.4.1 too, and update the first post.
WORKING
I had to add a new line into the init.rc file, but afterwards I was able to get Uruk 0.4.1 to boot internal
***mount ext4 /dev/block/mmcblk1p2 / noatime*** - I don't htink you have this in your steps...
After I did this, it works. I also am able to see both the internal and external storage in windows.
I didn't know if you need that line or it was left out of your steps process. All I did to get this to work on an existing 0.4.1 was:
1. Move the data off the internal inside windows to a saved directory on my PC.
2. Partition the 3 partitions like you describe on the internal and formated as you describe...
3. Mount the partitions inside my VMplayer Ubuntu sdb2, sdb3, sdc2, and sdc3 (sdb was the internal formated like you describe and sdc was my 16 0.4.1 SD card fromatted using uruk already)
Su terminal CODE:
$su
***password
#
#cd
#cd /tmp
#mkdir sdb2
#mkdir sdb3
#mkdir sdc2
#mkdir sdc3
#mount /dev/sdb2 /tmp/sdb2
#mount /dev/sdb2 /tmp/sdb3
#mount /dev/sdb2 /tmp/sdc2
#mount /dev/sdb2 /tmp/sdc3
4. Copy through terminal everything from sdc2 --> sdb2 using below code and Copy through terminal everything from sdc3 --> sdb3 using below code
**CODE I used:
#cp -rp /tmp/sdc2/* /tmp/sdb2
#sync
#cp -rp /tmp/sdc3/* /tmp/sdb3
#sync
6. Add in the lines inti init.rc to mount the sdb2, and the sdb3 instead of sdc2 and sdc3
mount ext4 /dev/block/mmcblk1p2 / noatime
mount ext4 /dev/block/mmcblk1p3 /data noatime
7. Add the line into tmp/sdb2/system/etc/vold.fsatb (Which is where I mounted that..)
dev_mount_lun volume_sdcard /mnt/storage/sdcard auto /devices/platform/usb_mass_storage/lun1 /class/block/mmcblk2
**I believe in 0.4.1 it is already like this, so i really made no changes to vold.fsatb....***
Unmounted all 4 I had mounted into /tmp using terminal ubuntu
CODE (I was already inside cd /tmp/sdb2 and i had edited the init.rc and saved it):
#sync
#cd..
#umount /tmp/sdb2
#umount /tmp/sdb3
#umount /tmp/sdc2
#umount /tmp/sdc3
EDIT: after this step, you will need to mount the Archos back into Windows, and copy the files you saved into a folder on your windows PC back into the Internal Fat32 storage. This was why you backed it up in the first place.... You might have to reboot and boot into your stock OS to get the internal to mount back into Windows, i did...
Reboot and go into the developer menu
Reflashed your initramfs and Uruk 0.4.1 Zimage and booted to developers edition...
***Remember this will only work if you have a preexisting 0.4.1 on an SD card where it is formatted with #1 fat32 for dtorage #2 500Mb and #3 1G and it already has been working using $auron's method.
BIG thanks to $aron and shklifo and msticninja... I am very happy using my internal memory to boot with instead of the SD card. i will prob keep the SD card I have and use it whenever I need to boot to SD and just get a different one for Videos and Music.
JW
sublimejosh2000 said:
I had to add a new line into the init.rc file, but afterwards I was able to get Uruk 0.4.1 to boot internal
***mount ext4 /dev/block/mmcblk1p2 / noatime*** - I don't htink you have this in your steps...
After I did this, it works. I also am able to see both the internal and external storage in windows.
I didn't know if you need that line or it was left out of your steps process.
JW
Click to expand...
Click to collapse
I really appreciate your feedback.
But you don't need to add the line:
Code:
mount ext4 /dev/block/mmcblk1p2 / noatime
on the file init.rc, because it is present on the init file included on initramfs.cpio.gz.
If you extract the initramfs.cpio.gz attached on my first post with this command on a shell:
Code:
gunzip initramfs.cpio.gz && cpio -i -d -H newc -F initramfs.cpio --no-absolute-filename
You will find the following line:
Code:
$MOUNT -t ext4 -o noatime,errors=continue /dev/mmcblk1p2 /new-root
To upgrade to $aur0n 0.4.2 now it's really simple.
I'm preparing the new initramfs.cpio.gz. And putting the new rootfs of 0.4.2 on the rootfs of our archos (just to remember it is on the second partition of the second internal disk on device /dev/block/mmcblk1p2 mountet on /) and flashing the new initramfs.cpio.gz and zimage, when booting up on "Developer Edition" it will upgrade automatically.
Is there a reason why we want to be on 0.4.2?
I am not having problems with Market, is there other benifits of this update?
JW
BTW: Thanks for this halp on getting to internal.. I am not sure why we wanted to not do this in the first place.. I guess because some SD cards are faster, mine is working pretty fast and I think the internal is at least class 6
sublimejosh2000 said:
Is there a reason why we want to be on 0.4.2?
I am not having problems with Market, is there other benifits of this update?
JW
BTW: Thanks for this halp on getting to internal.. I am not sure why we wanted to not do this in the first place.. I guess because some SD cards are faster, mine is working pretty fast and I think the internal is at least class 6
Click to expand...
Click to collapse
Just see on the $aur0n post about the new version log change. We will have upgraded module, new wifi, more services like samba sshd etc.
I to havn't any speed problem with internal flash. It is fast enough (with dd copying speed test got till 16 mbit/s write speed) on the internal flash and it is way faster than my sdcard class 4.
0.4.2
Well.. I already reverted back to the origional wifi config file using terminal, and my Market is good to go.
I'm not sure that there are any major differences between 0.4.1 --> 0.4.2
If I am wrong, i think it requires to uninstall all google apps to make that upgrade, which I don't think I need to do.
Am I wrong?
sublimejosh2000 said:
Well.. I already reverted back to the origional wifi config file using terminal, and my Market is good to go.
I'm not sure that there are any major differences between 0.4.1 --> 0.4.2
If I am wrong, i think it requires to uninstall all google apps to make that upgrade, which I don't think I need to do.
Am I wrong?
Click to expand...
Click to collapse
From $auron post on Uruk doesn't seem to be difference between 0.4.1 and 0.4.2, except google applications. With the 0.4.2 you can install the google staff separatly with UrukDroid-0.4.2-GoogleMarket.rar. If you have those apps allready on your 0.4.1 than nothing change, you don't need to upgrade.
Thanks and no problem with your methods.
My 16GB microSD card isn't very good and boot / use of archos 101 is very slow with Uruk0.4.2 installed on external SD.
Now it's fast installed on internal SD...
Maybe this help:
if can't mount ext4 partition on your linux box, you can do:
tune2fs -E test_fs /dev/sdbx (sdb2 for instance)
and then:
mount -t ext4dev /dev/sdbx /mnt/sdcard
trouble with fresh install for 0.4.2 $auron....
I was able to create 3 partition internally (sdb1(vfat), sdb2(ext4), sdb3(ext4))
I was able to move rootfs and cmd script to sdb2
I was able to flash initramfs and zImage
But I'm stuck when rebooting into SDE (the screen is all messed up)
Any suggestion?
I didn't modify init.rc and vold.stab since this is a fresh install
yura-a said:
Does this method applicable to Archos 101 model too?
If someone already have been tried it on 101, please reply with details here, if any troubles you have after installation or any changes need to be done.
Also I am curious about does anyone have tried to connect USB thumb drive to the tablet with modified rom and root access? Do we still have any issues with USB drive recognition?
Click to expand...
Click to collapse
Yes this procedure works the same way on the A101. I have the 16GB version so I made the 1st partition a bit bigger but that was the only deviation.

[KERNEL][MOD][08-03-2012] I/O Boost - Data2SD

K, time to give this a proper OP, if anyone wants any of the info that was here before you can look here
_________________________________________________________________________________________________
So, the whole idea here started with me reading an article on how part of the whole I/O problem with the transformer is partially caused by the hardware used as internal storage. I wanted to find out if this had any merit and I figured the best way to do it would be to "replace" the internal storage. I did this by mounting the /data partition to the exteral SD (which according to my research, my specific SD Card is better at writing speeds - allegedly the main problem with the transformer's internal storage hardware wise). Then I ran a bunch of benchmarks and have been running it that way for about 24 hours and so far it feels great. Anyone is welcome to give it a try, and hopefully with help, suggestions and feedback from the community, we can all take as much advantage of this idea as possible.
Before I go any further I want to give credit to those who helped me so far, because without them I would still be completely clueless, and not only have they helped be accomplishing what I got so far, but thanks to them I've also learned a bunch of things I didn't know before. So here it goes:
Rayman - For suggesting the method for mounting /data to the external SD.
lilstevie - For helping me get the new kernel flashed right.
Turge - For showing me how to properly repack the kernel.
Parastie - For suggesting doing the same thing to /cache (working on that now).
dagrim1 - For SQL patch and for suggesting a temporary remount (even though it didn't work it was a good thing to try).
_motley - For all his work on his awesome kernel.
_________________________________________________________________________________________________
Updates:
Update 1 (08-01-2012 File boot-data+cache+internal-AOKP6.1base.zip) :
Now both /data and /cache are moved to the external SD card. This means you need a third partition mmcblk1p3 in order to use this modification.
It will also mount the internal storage (previously inaccessible) to /mnt/sdcard_internal
It also attempts to (fail at this point) to mount the internal sd partition (what used to be /sdcard) to /sdcard/Internal_SD (which is why you will always see that folder get created but stay empty). If anybody knows how to make it work please advise.
Modified Lines:
init.cardhu.rc
Code:
# TweakerL MOD > original mount = mmcblk0p8 /data | mmcblk0p3 /cache
mount ext4 /dev/block/mmcblk1p2 /data wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
mount ext4 /dev/block/mmcblk1p3 /cache wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
# TweakerL MOD > added mounts for internal storage
mkdir /mnt/sdcard_internal 0000 system system
mount ext4 /dev/block/mmcblk0p8 /mnt/sdcard_internal wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
# TweakerL MOD > give access to internal SD from /sdcard
mkdir /data/media/Internal_SD 0755 media_rw media_rw
mount /mnt/sdcard_internal/media /data/media/Internal_SD wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
Update 2 (08-01-2012 About backing up/restoring in recovery) : - READ UPDATE 5
One thing that worried me was that by using this mod people wouldn't be able to backup their data partition properly, but now I know that it's possible to do it. It will only work on TWRP though since it has basic terminal access and keyboard. To do it, go into Advanced > Terminal and in there type:
umount /dev/block/mmcblk0p8
mount /dev/block/mmcblk1p2 /data
And until you reboot, any backup/restore should use the external SD data partition instead of the internal. The same should be doable with the cache partition in case you want to backup/restore that.
Update 3 (08-02-2012 File flashme-kernel-motley305-aokp-data+cache2SD.zip) :
Put together a flashable zip that will install motley's 3.0.5 aokp kernel using this mod. Works like a charm so far though I only tried flashing on TWRP. Also, internal storage can be accessed in /data2 and internal sd can be accessed in /sdcardi . Current changes are as follow:
Code:
# TweakerL MOD > move /data and /cache to external SD card || original mount = mmcblk0p8 /data | mmcblk0p3 /cache
mount ext4 /dev/block/mmcblk1p2 /data wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
mount ext4 /dev/block/mmcblk1p3 /cache wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
# TweakerL MOD > create mount for internal storage
mkdir /data2 0000 system system
mount ext4 /dev/block/mmcblk0p8 /data2 wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
# TweakerL MOD > symlink internal sd to a couple of easily accessible locations
symlink /data2/media /mnt/sdcard_internal
symlink /data2/media /sdcardi
Update 4 (08-03-2012 File boot-cm10-unofficial-data+internal.zip) :
Running the unofficial CM10 (no cherrypicks one) using this mod and so far it's pretty amazing. The rom itself is pretty stable and even snappier with /data mounted to external SD. Benchmarks are at the bottom. Current modifications:
fstab.cardhu:
Code:
#TweakerL MOD > Move /data to external SD and internal /data to /data2
/dev/block/mmcblk1p2 /data ext4 rw,nosuid,nodev,noatime,user_xattr,acl,barrier=1,journal_async_commit,nodelalloc,data=writeback wait
/dev/block/mmcblk0p8 /data2 ext4 rw,nosuid,nodev,noatime,user_xattr,acl,barrier=1,journal_async_commit,nodelalloc,data=writeback wait
init.cardhu.rc:
Code:
# TweakerL MOD > create mount for internal storage
mkdir /data2 0000 system system
mount_all /fstab.cardhu
# TweakerL MOD > symlink internal sd to a couple of easily accessible locations
symlink /data2/media /mnt/sdcard_internal
symlink /data2/media /sdcardi
Update 5 (08-03-2012 About backing up/restoring in recovery) :
So after doing some tests, and paying more attention to TWRP, I noticed something rather useful:
When you have this mod enabled, or whenever you have a mmcblk1p2 partiion, TWRP will have the sd-ext menu enabled. This means that to backup your data you can simply backup the sd-ext partition and to restore your data you can simply restore your sd-ext partition. No need to worry about manually switching the mount point for /data in recovery. I guess it was a whole lot easier than I thought.
Also congratulations and thanks to everyone who has contributed with this so far.
WE MADE IT TO FRONT PAGE ON XDA (08-03-2012)
_________________________________________________________________________________________________
Requirements:
There are a few things you will need to do in order for this to work right for you, and a couple of things you'll have to research before you even try it.
#1. Obviously, you have to be rooted/unlocked because you're not gonna be able to change much around otherwise.
#2. You MUST repartition your external SD. The kernel I've put together so far WILL ONLY mount /data to mmcblk1p2, which basically says "mount /data to the second partition in the external SD." also, the ramdisk expects that partition to be ext4, so essentially:
Make sure you have an external SD with at least two partitions and that the second partition is formatted to ext4. I personally use Gparted to repartition my stuff, but feel free to use whatever rocks your boat. Even if you're on windows you can still use gparted by using virtualbox, so I'm not gonna go look for a different windows solution.
#3. This is the research part... This will be beneficial or detrimental to each user depending on the SD card used. If you have a slow SD card this probably will do you no good. However, just because you have a class 10 SD card, that doesn't mean it will benefit you either. On my own research I have found that some class 6-10 SD Cards have extremely slow random write speeds, so if you happen to have one of those, even if it's a class 10, this might not be for you. This means that you're gonna have to do some research to find out if your SD Card will benefit you or not. You can always just give it a try, as far as I know this is entirely reversible, how easy or hard being just a matter of how bad you mess up on meeting the requirements and following the instructions.
#4. At this point (07-30-2012) I'm doing all this stuff using the AOKP milestone 6.1 kernel as base for my modified kernel, so if you're not using AOKP milestone 6.1, flashing my kernel might borke your system. You've been warned, feel free to proceed otherwise at your own peril.
_____________________________________________________________________________________________________________
Installation:
#1. Download attached file (boot-data2SD-AOKP6.1base.zip) and extract it to the root of your internal storage (/sdcard).
#2. Open a terminal.
#3. Type the following:
Code:
su
dd if=/sdcard/boot.blob of=dev/block/mmcblk0p4 bs=1
#4. Wait for it to complete.
#5. Reboot.
Upon rebooting you will know that it worked because it will look just as if you just flashed a new rom, that is, you'll get the device setup screen (assuming that the tablet booted at all lol). If you're planning to use TB to restore your apps, you'll probably want to copy the TB folder to your external SD's first partition so that you can copy it back once you're done with the device setup (at this point you will have no access - unless you manually mount it - to your internal storage).
_______________________________________________________________________________________
Reverting:
Follow the same exact steps for installation but use boot-default-AOKP6.1.zip instead.
_______________________________________________________________________________________
Optional:
#1. If you want to have access to everything you had on your data partition in the new data partition, you'll have to clone everything from one to the other. To do this, make sure that your new data partition (the one in your external SD) has enough storage space to fit everything you currently have in your data partition (the one in your internal storage). Then run the following command in your terminal.
Code:
dd if=dev/block/mmcblk0p8 of=dev/block/mmcblk1p2 bs=4096 conv=notrunc,noerror
BEWARE that if you have a lot of stuff this can take quite a while and even though I've read a way of getting the progress for this in Linux I'm not sure that you can check the progress on Android.
_______________________________________________________________________________________
Next steps in development:
#1. Move /cache as well.
#2. Find out what happens with recovery backups when the partitions are changed.
#3. Attempt to apply mod to motley's kernel.
#4. Create a script that is run on boot to eliminate need for replacing the kernel.
#5. With help from the community, find the best SD Card for this.
#6. Run the modified system for a while to have a good feel for performance benefits
#7. Come up with other interesting uses for this other than getting better I/O (maybe an easy - kinda easy - way to dual boot with ubuntu, maybe other stuff, dunno).
_______________________________________________________________________________________
How can I set my kernel to do this?
I didn't do a whole lot, and it's not like I want it to be a secret, so as I modify things I'll try to keep the steps listed here so that anyone modifying their own kernel who would like to try this modification can go ahead and do it.
You'll need to know how to unpack/repack a kernel. Turge has a SUPER EASY explanation here on how to do it on windows (I'll pack together the necessary binaries for linux later, maybe).
Mount /data to the second partition in your external SD (formatted as ext4 filesystem):
After unpacking the kernel navigate to the folder that has the ramdisk and open it
(DON'T USE ANY ASCII BASED TEXT EDITOR BECAUSE IT WILL PROBABLY MESS THINGS UP I USE NOTEPAD++)
Around line 26 change:
Code:
mount ext4 /dev/block/mmcblk0p8 /data wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
to
Code:
mount ext4 /dev/block/mmcblk1p2 /data wait noatime nodiratime nosuid nodev nodelalloc,errors=panic
_______________________________________________________________________________________________________
SD Cards tested:
Samsung 32GB Class 10 MicroSDHC High Speed Memory Card - Very Good Results
SanDisk® microSDHCTM 8GB Memory Card - Very Good Results
"Either way, with this mod, the tablet feels like it should have right from the start. It's speedy and responsive, and apps being installed don't stall the system." - Turge - Post #59
_______________________________________________________________________________________________________
Benchmarks:
/data mounted to mmcblk0p8 (Internal Storage):
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
/data mounted to mmcblk1p2 (External SD):
RL Benchmark WITHOUT dagrim1's sql patch as per request:
/data mounted to mmcblk0p8 (Internal Storage):
/data mounted to mmcblk1p2 (External SD):
*Important thing to note: When running the benchmark with data in the internal SD it was about 220 seconds in the first run, then about 180, then about 130 and finally 118; whereas running it from the external SD was consistenly between 63 and 65 seconds every time. I think this more than proves that A) Asus used a cheap I/O storage, B) No matter what software changes are made, more than likely running the rw partitions from a better I/O storage, i.e. an external SD is a good idea.
As promised here are benchmarks on a JB rom (Unofficial CM10). Also sorry it took me a while to get these, I was going to use eos3 but I started getting random reboots. Then I decided to try cm10, and I messed up a flash and had to redo a bunch of things. Anyway, the only change here is the mod itself (no custom kernel or anything). Though one thing to note is that I moved /cache back to the internal partition after some thought that this allows /data and /cache to be written at the same time to different locations thus lowering the bottleneck.
/data mounted to mmcblk0p8 (internal storage):
/data mounted to mmcblk1p2 (external storage):
Now, as you can see, JB did bring a major improvement to I/O, bringing the benchmark down from about 115sec to 68 (almost reaching the modded ICS at 60 seconds). But as I expected, better software works better on better hardware and now the modded JB is running at 50 seconds instead of 60. Next I'm going to put dagrim1's sql patch and see how low the benchmark goes. Also will be posting the modded blob in just a little bit for anyone who wants to use it on CM10.
We don't have sd-ext it's an old trick when phones had very little /data partitions, you have the possibility to create a sd-ext partition on an external sdcard and mounting it as a secondary data. (like opt partition on Linux).
To see what block device is data just run 'mount' command in terminal emulator. I don't have my device here.
sdcard cache is already set to 2048 if I'm correct.
Your script would mean creating a sd-ext partition on an external sdcard, modify fstab to have it correctly mounted then applying the script.
Not really easy for common users.
I would rather look at kernel drivers (not I/O schedulers but drivers handling with file system format) but it's quite a hard work.
Hmmm...
Was talking to Rayman and it doesn't actually seem that hard to do... Just gotta change the init.cardhu.rc in the ramdisk to mount /data to /dev/block/mmcblk1p2 instead of /dev/block/mmcblk0p8
The thing is, that while I know every step that I have to take to get it done, I haven't used linux in forever and quite honestly I couldn't even compile blobtools right now if I wanted to to extract the ramdisk from the boot blob to make the necessary change... so yea anyone who knows how to edit a kernel should be able to do it, and then just repack it as a blob... I'll probably look into it later, but if anyone wants to type the terminal commands for to to get/compile blobtools I'll appreciate it...
As in just a mount of data to mmcblk1p2?
Would a temp solution (just to check if it works) be to remount data manually? (Tried it, to mmcblk1p1 btw since 1p2 didn't seem to exist for me, but it still mounts to mmcblk0p8.
Using:
mount -o remount,rw -t ext4 /dev/block/mmcblk1p1 /data
(as su in terminal)
dagrim1 said:
As in just a mount of data to mmcblk1p2?
Would a temp solution (just to check if it works) be to remount data manually? (Tried it, to mmcblk1p1 btw since 1p2 didn't seem to exist for me, but it still mounts to mmcblk0p8.
Using:
mount -o remount,rw -t ext4 /dev/block/mmcblk1p1 /data
(as su in terminal)
Click to expand...
Click to collapse
Reason why mmcblk1p2 didn't work is because you have to repartition the sd card to have an ext4 partition... personally what I did was take my 32gb sd card and have the first partition as a fat32 partition for storage and set the rest to an ext4 partition... also, you have to do that because the /data partition is already expected to be an ext4 partition on most of the current ROMs... Trying to set it without doing that most likely won't work.
Also, another thing that's important is that for this to be beneficial you have to have an SD Card with higher random write speed than your internal storage speed... my internal storage speed is about .25 mb/s and my sdcard is about 1.5mb/s so there should be a big difference... Oh and if you happen to have a class 10 sdcard that doesn't necessary mean that it has high random write speed... you actually have to go look up the specs or run benchmarks on it.
TweakerL said:
Reason why mmcblk1p2 didn't work is because you have to repartition the sd card to have an ext4 partition... personally what I did was take my 32gb sd card and have the first partition as a fat32 partition for storage and set the rest to an ext4 partition... also, you have to do that because the /data partition is already expected to be an ext4 partition on most of the current ROMs... Trying to set it without doing that most likely won't work.
Also, another thing that's important is that for this to be beneficial you have to have an SD Card with higher random write speed than your internal storage speed... my internal storage speed is about .25 mb/s and my sdcard is about 1.5mb/s so there should be a big difference... Oh and if you happen to have a class 10 sdcard that doesn't necessary mean that it has high random write speed... you actually have to go look up the specs or run benchmarks on it.
Click to expand...
Click to collapse
Thanks, makes sense yeah... will have to check if it's worth the hassle for now. Not at this moment anyway, but interesting concept...
Stuck... again...
So I figured how to unpack the boot.blob, then unpack the boot.blob.LNX, then decompress the ramdisk... made the necessary change to init.cardhu.rc... compressed the ramdisk to the same format it was before, repacked the boot.blob.LNX, repacked the boot.blob... dd if=blob of=dev/block/mmcblk0p4 seek=28 bs=1 ... and ... nothing... reboot and where you're supposed to get the quick progress bar nothing seems to happen... I'm assuming I messed up on the recompressing ramdisk/packing the boot.blob... but I'm not sure how...
Anyway... I'll post exactly how I did it tomorrow so maybe someone with more experience can help me figure out where I messed up...
But so far, I wanna say thanks to rayman and lilstevie for all the help they've given me so far with this idea.
TweakerL said:
... compressed the ramdisk to the same format it was before, repacked the boot.blob.LNX, repacked the boot.blob... dd if=blob of=dev/block/mmcblk0p4 seek=28 bs=1 ...
Click to expand...
Click to collapse
Just wondering, why did you choose to use seek=28?
I believe the TFP will need the first 28 header signature to be there in order to flash through the staging paritition (p4).
Your other option would be to flash using fastboot:
1. If you've installed the AndroidRoot.mobi bootloader (if you have nvflash), then you can directly flash the boot.blob.LNX file, as this is a raw image.
fastboot -i 0x0b05 flash boot boot.blob.LNX
2. If you don't have AndroidRoot.mobi bootloader, then I suggest you get NVFlash working first and get a backup... if not, you can use the following to flash the blob:
fastboot -i 0x0b05 flash boot blobfileyou'vecreated
3. Use fastboot to flash to the staging partition:
fastboot -i 0x0b05 flash staging blobfileyou'vecreated
TweakerL said:
So I figured how to unpack the boot.blob, then unpack the boot.blob.LNX, then decompress the ramdisk... made the necessary change to init.cardhu.rc... compressed the ramdisk to the same format it was before, repacked the boot.blob.LNX, repacked the boot.blob... dd if=blob of=dev/block/mmcblk0p4 seek=28 bs=1 ... and ... nothing... reboot and where you're supposed to get the quick progress bar nothing seems to happen... I'm assuming I messed up on the recompressing ramdisk/packing the boot.blob... but I'm not sure how...
Anyway... I'll post exactly how I did it tomorrow so maybe someone with more experience can help me figure out where I messed up...
But so far, I wanna say thanks to rayman and lilstevie for all the help they've given me so far with this idea.
Click to expand...
Click to collapse
I've repacked the boot.img for the Prime before to add init.d support so I'll post my method and the files needed in a few minutes once I get to work. It'll involve getting cygwin installed (with Perl support I believe) if you're on Windows.
Would it be better to move cache and maybe dalvik cache (assuming the SD random read/write is faster then internal memory) ? Since you're only moving data and leaving cache on internal, that'll still hit the issues of having bad IO. Moving cache (which I believe would have more random access) I think would be better.
Thoughts?
dagrim1 said:
As in just a mount of data to mmcblk1p2?
Would a temp solution (just to check if it works) be to remount data manually? (Tried it, to mmcblk1p1 btw since 1p2 didn't seem to exist for me, but it still mounts to mmcblk0p8.
Using:
mount -o remount,rw -t ext4 /dev/block/mmcblk1p1 /data
(as su in terminal)
Click to expand...
Click to collapse
Thanks for the idea, I tried to do that but nothing seemed to happen (checking on file manager /data partition is still taking the same amount of space as it did before). It would've been a really good way of testing this whole thing though
kokopuphz said:
Just wondering, why did you choose to use seek=28?
I believe the TFP will need the first 28 header signature to be there in order to flash through the staging paritition (p4).
Your other option would be to flash using fastboot:
1. If you've installed the AndroidRoot.mobi bootloader (if you have nvflash), then you can directly flash the boot.blob.LNX file, as this is a raw image.
fastboot -i 0x0b05 flash boot boot.blob.LNX
2. If you don't have AndroidRoot.mobi bootloader, then I suggest you get NVFlash working first and get a backup... if not, you can use the following to flash the blob:
fastboot -i 0x0b05 flash boot blobfileyou'vecreated
3. Use fastboot to flash to the staging partition:
fastboot -i 0x0b05 flash staging blobfileyou'vecreated
Click to expand...
Click to collapse
I used seek=28 out of despair and by lilstevie's suggestions... dd with or without seek had the same exact result, the staging just ignoring the whole thing lol...
Sounds like a plan (flashing with fastboot)... I've got one dumb question though before I do that (and yea i've got nvflash setup and all the backups and stuff). How do I actually go about restoring the system with NVFLASH if I go and borke the system ? XD
Turge said:
I've repacked the boot.img for the Prime before to add init.d support so I'll post my method and the files needed in a few minutes once I get to work. It'll involve getting cygwin installed (with Perl support I believe) if you're on Windows.
Click to expand...
Click to collapse
That would be much appreciated, I don't mind steps for windows or linux, I'll go either way
Parastie said:
Would it be better to move cache and maybe dalvik cache (assuming the SD random read/write is faster then internal memory) ? Since you're only moving data and leaving cache on internal, that'll still hit the issues of having bad IO. Moving cache (which I believe would have more random access) I think would be better.
Thoughts?
Click to expand...
Click to collapse
I agree that moving the cache is a good idea, one of the main reasons why I'm testing with /data though is that it will be much easier to have solid evidence of whether this works or not that way since all the benchmark apps seem to benchmark on the /data partition. I know benchmarks aren't real world results, but if I can run benchmarks on the same partition and it's 5 times faster on the SD card than on the internal memory, I think it should mean something. After that, if there are positive results, I'm thinking of moving both /data and /cache partitions and run that way for a while to see how well it performs, and then to run with just the /cache moved and see how that performs.
Turge said:
I've repacked the boot.img for the Prime before to add init.d support so I'll post my method and the files needed in a few minutes once I get to work. It'll involve getting cygwin installed (with Perl support I believe) if you're on Windows.
Click to expand...
Click to collapse
Here are the steps for repacking the boot.img. Some involve running the commands via cygwin, others involve running them via the Windows Command Prompt.
The instructions for installing cygwin, extracting and repacking the boot.img were found here: http://www.freeyourandroid.com/guide/extract-edit-repack-boot-img-windows
Once you have setup cygwin, extract the attached files in a folder under your "home" folder in cygwin.
copy boot.blob to the same folder and run the following via the Windows Command Prompt to extract the boot.img from the boot.blob:
Code:
BlobUnpack.exe boot.blob
ren boot.blob.LNX boot.img
From the cygwin bash terminal window, switch to the same folder and run the following to extract the ramdisk from the boot.img:
Code:
./extractboot boot.img
You now have an out/ramdisk folder that contains the files you want to edit.
Once done, repack the ramdisk and kernel into boot_new.img with the following command (via cygwin once again):
Code:
./packboot
then from the Command Prompt repack boot_new.img into boot2.blob using the following:
Code:
blobpack -s boot2.blob LNX boot_new.img
You can now flash the boot.blob to the staging partition via a command in updater-script:
Code:
package_extract_file("/boot.blob", "/dev/block/mmcblk0p4");
or by using adb while in recovery/android:
Code:
dd if=/sdcard/boot2.blob of=/dev/block/mmcblk0p4
Did anyone think of running iotop? If we know what part of /data is contributing to the stalls, maybe an interesting idea would be to just mount that part of the tree on SD?
tyvm will get on it now, will report back any results
Sent from my Transformer Prime TF201 using Xparent SkyBlue Tapatalk 2
what's iotop?
Though regardless, the problem I'm trying to deal with is the fact that apparently, the storage hardware in the Prime has limited I/O capabilities, namely random write speeds, regardless of software. Because of this the stalls are at least partially caused by the "where" the /data is rather than the "content" in the /data.
Sent from my Transformer Prime TF201 using Xparent SkyBlue Tapatalk 2
TweakerL said:
what's iotop?
Click to expand...
Click to collapse
ffs. Why do I bother?
tshoulihane said:
ffs. Why do I bother?
Click to expand...
Click to collapse
You know, I can just google it, but the fact that you care enough to post your opinion but not enough to explain it is the kind of mentality that keeps people who could potentially contribute to the community from doing so because they have to go research all over the internet, possibly going through bad information, for something that might be very simple. Read a few posts up and you'll see the right kind of mindset. Turge could've just*given some halfassed response and sent me on a wild goose chase but instead he took the time to explain in a way that anyone with any amount of knowledge could understand...
And I hope that since you can't bother to give an useful response, that you can't bother wasting you "precious time" justifying and complaining about how people ask questions that they could just look for elsewhere...

? How to recover deleted files on rooted Android without USB Debug & PC connection?

? How to recover deleted files on rooted Android without USB Debug & PC connection?
Hello.
I have removed some important files in my DCIM folder on internal memory of my Android device. The USB socket of the phone is broken so I couldn't use any recovery software that using USB debug mode but I have Team Win I want to use the terminal of Team Win to make an image and copy it to SD Card of my Android device. I know that there is a command dd but how to use it in a proper way to make a full image of the partition including also free space.
Thank you very much in advance!
Yes, dd command could be used simmilar to this:
open terminal, cd to external SD folder
dd if=/dev/block/block/bootdevice/by-name/userdata of=data.img
or if you know number of partition
dd if=/dev/block/mmcblk0p18 of=data.img (p18 is on Huawei LDN, image size is that same as partition size 16GB/32GB/64GB..etc, so for bigger then 32GB need to use NTFS sdcard or exFAT sdcard and TWRP also has to support NTFS or exFAT).
Or edit etc/*.fstab and repack twrp. You can back up files from /data for now (as ext4 or f2fs). Just add line to back up full image of /data (as emmc).
If /data has ext4 filesystem it can easilly mount/unpack/scan/rip image. But if /data has f2fs ... got not cure.
Example:
/data f2fs /dev/block/bootdevice/by-name/userdata flags=length=-16384;backup=1;settingsstorage;encryptable=footer;
/data_image emmc /dev/block/mmcblk0p55 flags=display="Data Image";backup=1;flashimg;
adeii said:
Yes, dd command could be used simmilar to this:
open terminal, cd to external SD folder
dd if=/dev/block/block/bootdevice/by-name/userdata of=data.img
or if you know number of partition
dd if=/dev/block/mmcblk0p18 of=data.img (p18 is on Huawei LDN, image size is that same as partition size 16GB/32GB/64GB..etc, so for bigger then 32GB need to use NTFS sdcard or exFAT sdcard and TWRP also has to support NTFS or exFAT).
Or edit etc/*.fstab and repack twrp. You can back up files from /data for now (as ext4 or f2fs). Just add line to back up full image of /data (as emmc).
If /data has ext4 filesystem it can easilly mount/unpack/scan/rip image. But if /data has f2fs ... got not cure.
Example:
/data f2fs /dev/block/bootdevice/by-name/userdata flags=length=-16384;backup=1;settingsstorage;encryptable=footer;
/data_image emmc /dev/block/mmcblk0p55 flags=display="Data Image";backup=1;flashimg;
Click to expand...
Click to collapse
Thank you very much for you point to point reply!
Finally, I choose to use that option with some modifications because vfat doesn't support files larger than 4GB.
Code:
dd if=/dev/block/bootdevice/by-name/userdata conv=noerror,sync bs=100M | gzip -c | split -b1000000000 - mybackup.img.gz
I have mounted this *.img partition using OSFMount for Windows. But after the scanning process (I was using R-Studio that supports ext4 file system I found my deleted files in the tree structure /media/0/DCIM/Camera but all of the deleted files has 0 bytes size and have 2 flags: deleted, wiped.
I couldn't understand how that happened. I mean I didn't use my phone after deleting files at all. I also mounted this *.img as raw disk in Active Undelete but the result is actually the same all of the deleted files have 0 bytes file size.
Is that a bug of the program? Or I have made an image using wrong command? Or Android 9 actually wiping files after deletion?
The files have been accidentally deleted by AirDroid-web app but I don't think so that this app is wiping deleted files it doesn't make sense...
RaTr said:
Thank you very much for you point to point reply!
Click to expand...
Click to collapse
You are welcome. Thank you are for note about 4GB file size limit on vfat/fat32, will save us from a lot of headache.
---------- Post added at 10:03 AM ---------- Previous post was at 09:49 AM ----------
RaTr said:
actually the same all of the deleted files have 0 bytes file size.
Click to expand...
Click to collapse
Maybe to try DiskDigger on phone if it is rooted to scan internal sd?
PhotoRec for Windows/Linux: https://www.cgsecurity.org/wiki/PhotoRec_Step_By_Step
There are few programs to try on your image on GNU/Linux like extundelete, ext4magic, AnalyzeEXT, ext3grep ...
Source: https://askubuntu.com/questions/217606/undelete-files-on-ext4
I am trying to use ext4magic to recover deleted files. But I need a copy of the journal when I am trying to use command
Code:
debugfs -R "dump <8> /var/tmp/home.journal" /dev/mapper/home
I see that Team win terminal do not have this command how to add it or how to make a copy of the journal of my ext4 partition where I am trying to recover my files.
adeii said:
Maybe to try DiskDigger on phone if it is rooted to scan internal sd?
Click to expand...
Click to collapse
I have tried to use DiskDigger. When I am putting a filter to show only deleted files it doesn't show anything. Which is pretty strange.
adeii said:
There are few programs to try on your image on GNU/Linux like extundelete, ext4magic, AnalyzeEXT, ext3grep ...
Source: https://askubuntu.com/questions/217606/undelete-files-on-ext4
Click to expand...
Click to collapse
Next program that I have tried was TestDisk but looks like it doesn´t support ext4 file system.
Thank you for the advice about PhotoRec. It has support of ext4 system. But it won't help. So, there are still some options. I will try to use extundelete as the next one.
If you have an image of EXT4, then you can use 7-Zip Archiver to read all the files inside it.
jwoegerbauer said:
If you have an image of EXT4, then you can use 7-Zip Archiver to read all the files inside it.
Click to expand...
Click to collapse
7-Zip will show deleted files also?..
I have tried 2 more utilities:
1. ext4magic without external journal file. It has done the job but I couldn't find any files that I need.
2. extundelete that program restored less files and also no files that I want to recover.
One more strange thing:
I have installed R-Studio and opened my image there. I fount full list of my deleted files, but all of the records of my deleted files have 2 flags: deleted, wiped and it shows me that the size of that specific files is 0 bytes.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
I have checked other files from different dates, they can be recovered, there is no flag wiped and also I can see the size, in some of them there is a flag cross-link, but I think it is normal, that means part of that file is already overwritten by another one.
RaTr said:
I have tried 2 more utilities:
1. ext4magic without external journal file. It has done the job but I couldn't find any files that I need.
2. extundelete that program restored less files and also no files that I want to recover.
One more strange thing:
I have installed R-Studio and opened my image there. I fount full list of my deleted files, but all of the records of my deleted files have 2 flags: deleted, wiped and it shows me that the size of that specific files is 0 bytes.
I have checked other files from different dates, they can be recovered, there is no flag wiped and also I can see the size, in some of them there is a flag cross-link, but I think it is normal, that means part of that file is already overwritten by another one.
Click to expand...
Click to collapse
I am stuck in the same situation bro
See it here I described the issue very similar to yours. Any luck in trying to recover that `ext4` data
RaTr said:
I found my deleted files in the tree structure /media/0/DCIM/Camera but all of the deleted files has 0 bytes size and have 2 flags: deleted, wiped.
Click to expand...
Click to collapse
expected.
emmc/ufs flash storage is handled different from hard disk drive. there is FTL controller with own firmware that is wear-leveling whole storage all the time. not to mention files are fragmented.
file system sends TRIM on each deletion of file. note the discard mount flag for userdata partition.
Android 4.3 Update Brings TRIM to All Nexus Devices
www.anandtech.com
Hi, I tried dd command, and it returned
Code:
dd: data.img: Read-only file system
But ./adb pull /dev/block/mmcblk0p57 57.img worked, and created a NDIF image.
Why dd did not work?
And which format of image would dd create?
Thanks.
you're trying to write into phones / rootdir. you cannot dump partition into phone itself. external MicroSD card or OTG pendrive is required. but you could redirect to stdout into remote file (note the quotes make the difference where > redirection is executed)
Code:
adb root
adb shell 'dd if=/dev/block/mmcblk0p57 bs=1m status=none' > data.img
open data.img file with HxD editor and have a look into first bytes. search for magic 53 ef at offset 0x438 to confirm it's ext4 image.
dd is useful in case no usb connection available (topic of thread). the result is same as adb pull. you can increase speed with block size (bs= default 512 bytes) up to 1 MB.
Note: on FDE encrypted phone one can't pull userdata directly. instead pull whatever is mounted /data (like /dev/block/dm-0)
aIecxs said:
you're trying to write into phones / rootdir. you cannot dump partition into phone itself. external MicroSD card or OTG pendrive is required. but you could redirect to stdout into remote file (note the quotes make the difference where > redirection is executed)
Code:
adb root
adb shell 'dd if=/dev/block/mmcblk0p57 bs=1m status=none' > data.img
open data.img file with HxD editor and have a look into first bytes. search for magic 53 ef at offset 0x438 to confirm it's ext4 image.
dd is useful in case no usb connection available (topic of thread). the result is same as adb pull. you can increase speed with block size (bs= default 512 bytes) up to 1 MB.
Note: on FDE encrypted phone one can't pull userdata directly. instead pull whatever is mounted /data (like /dev/block/dm-0)
Click to expand...
Click to collapse
Thanks for your reply.
What would be the differences between
adb shell 'dd if=/dev/block/mmcblk0p57 bs=1m status=none' > data.img
and
the method described in this message: https://stackoverflow.com/a/41214172 ?
Thanks.
streaming over netcat avoids unwanted characters using stty raw. on macOS probably result is no difference (after unpacking gzip).
you don't need this as you wrote adb pull worked (which is the easiest method)
aIecxs said:
streaming over netcat avoids unwanted characters using stty raw. on macOS probably result is no difference (after unpacking gzip).
you don't need this as you wrote adb pull worked (which is the easiest method)
Click to expand...
Click to collapse
Thanks.
I searched Hex in 57dd.img created by adb shell 'dd if=/dev/block/mmcblk0p57 bs=1m status=none' > 57dd.img.
It showed
Is the 53EF on line 1080 in the image above is the one you mentioned "at offset 0x438"?
right, that is ext4 magic at offset/byte hex (0x438)16 = (1080)10 dec
I have a slightly different but related question /problem. My apologies if this is not the right place to post.
On my Samsung A10e, TWRP (and other recoveries) gives me a tarfork 255 error when trying to backup userdata. Normally this should be 32GB in size from Samsung specs.
I have used two alternatives :
* adb pull /dev/block/by-name/userdata data.img which creates a 26G file on my linux PC, that I can mount and inspect. When I run filesystem check it throws out errors, probably due to some of the data being encrypted - I am running AOSP Android 11 gsi. Perhaps the same errors that prevents TWRP from working ?
* alternatively I have put in a clean 32GB SD card, then via adb shell run dd if=/dev/block/by-name/userdata of=/dev/block/mmcblk1p1 to copy the full userdata partition over to the SD card. Once removed from the phone and put in a card reader, again this can be inspected on my linux PC, and gives the same filesystem check errors. I also ran dd if=/dev/external_sd of=data2.img on my linux PC to create a similar image file as adb pull but it is now the full 32GB that I would have intially expected.
So why the size difference between adb pull and dd ?? Does adb pull actually get everything - in other words if I try and restore with adb push will the phone recover to previous state and boot ?
I was hoping to then reduce the size of my data copy to 16GB since on my phone I am only using 12GB of the 32GB, but file errors are preventing me at the moment.
I was thinking about wiping data and then with arm32 parted and adb shell creating a 16GB userdata partition and an additional 16GB user shadow partition - the latter only to be used locally via dd to do backup and restore and avoid TWRP errors.
that is very lightly due to encryption issues....esp Magisk is known to break encryption.
if you can decrypt at TWRP level and then proceed to backup user data via ADB shell to memory card that is your best bed and then wipe the partition and then restore your app data individually for apps that you need e.g. contacts db for contact an SMS. I strongly doubt if you will be able to restore that entire partition and boot to that original partition successfully.... it may have become what what we can call "encryption tainted"
excuse my typos

Categories

Resources