[SCRIPT] Enabling Darktremor a2sd on Samsung s5830 Galaxy ACE - Android Software/Hacking General [Developers Only]

Hello,
In this guide I will show you how to enable Darktremor's a2sd (i.e. extending your internal memory using SD card, so you can install more applications easily).
This method has been tested on a rooted Galaxy ACE running Android 2.2.1. It might work on other devices, but I don't guarantee.
This guide assumes that your phone is rooted, and you have a basic knowledge in adb shell.
Please note that this script sleeps for 8 seconds at boot time to make sure that the SD card is loaded before mounting (thanks devetle and KoGi77GR).
REMEMBER: The steps below will not extend your phone's internal memory, you still have to install a2sd (link provided below) to complete the job.
1- Backup all data, both on your phone and your SD card.
Click to expand...
Click to collapse
2- Partition your SD card as following: 1st partition FAT32, 2nd partition ext2. I'm not sure about the optimal partition size of ext2, but you can start with 1-2 GB. Make sure that you use ext2 only, as ext3 and ext4 are not supported by the kernel (by default. See Bonus section below). Here's a good guide to help you out.
Click to expand...
Click to collapse
3- Insert your SD card and make sure that your phone recognizes it correctly.
Click to expand...
Click to collapse
4- Connect your phone in Mass Storage mode, then extract the attached script file to your SD card root directory.
Click to expand...
Click to collapse
5- Disconnect mass storage and login to ADB shell as root:
Code:
adb shell
su
Click to expand...
Click to collapse
6- Type in the following commands (try copy-paste each line then hit enter):
Code:
cp /sdcard/a2sd_enabler.sh /data/local/tmp/
chmod 755 /data/local/tmp/a2sd_enabler.sh
/data/local/tmp/a2sd_enabler.sh
If you got any error messages (starting with "ERROR") please post them here. Otherwise, continue to step 7.
Click to expand...
Click to collapse
7- To double check everything, reboot your phone and login again as root through adb, then run the following command, and find a line similar to the highlighted line in the output below:
Code:
su
df
Output
Code:
/dev: 142220K total, 12K used, 142208K available (block size 4096)
/mnt/asec: 142220K total, 0K used, 142220K available (block size 4096)
/cache: 25656K total, 12K used, 25644K available (block size 4096)
/data: 185240K total, 36768K used, 148472K available (block size 4096)
/system: 213376K total, 211520K used, 1856K available (block size 4096)
[B][COLOR="Red"]/system/sd: 1032088K total, 38512K used, 993576K available (block size 4096)[/COLOR][/B]
/mnt/sdcard: 6783016K total, 190356K used, 6592660K available (block size 4096)
/mnt/secure/asec: 6783016K total, 190356K used, 6592660K available (block size 4096)
Click to expand...
Click to collapse
8- Now you're good to go. Follow the directions as described in Darktremor's thread here:
http://forum.xda-developers.com/showthread.php?t=715116
Click to expand...
Click to collapse
Bonus for the experts
Now you can mount ext3 and ext4 partitions too using kernel mods. You can find them here: http://forum.xda-developers.com/showpost.php?p=12845360&postcount=17
I managed to setup a2sd on ext3 successfully, and planning to test ext4.
Thanks peeter123
Click to expand...
Click to collapse

Hi,
the link to script is broken. please upload it again! thanx!

harrythescorpion said:
Hi,
the link to script is broken. please upload it again! thanx!
Click to expand...
Click to collapse
You seem to have trouble downloading files from the forum. Here you go:
http://www.4shared.com/file/zn2vNQrH/a2sd_enablersh.html

Hi majedev,
thank you. I rooted the phone and followed the way in this thread.
I can mount ext2 (2nd partition of sdcard), but my S5830 seems not running install-recovery.sh at start up. I don't know why... Please helppppppppp
Here's what "cat /system/etc/install-recovery.sh" shows:
#!/system/bin/sh
/system/bin/mount -t ext2 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
I'm wondering is that any issue that can prevent the install-recovery.sh from running at start up...

devetle said:
Hi majedev,
thank you. I rooted the phone and followed the way in this thread.
I can mount ext2 (2nd partition of sdcard), but my S5830 seems not running install-recovery.sh at start up. I don't know why... Please helppppppppp
Here's what "cat /system/etc/install-recovery.sh" shows:
#!/system/bin/sh
/system/bin/mount -t ext2 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
I'm wondering is that any issue that can prevent the install-recovery.sh from running at start up...
Click to expand...
Click to collapse
It might be permissions issue? Try "chmod 755 /system/etc/install-recovery.sh"
If that didn't help, please run this command as root to copy "init.rc" to your sd card, then post the file here:
Code:
cp /init.rc /sdcard/

majedev said:
It might be permissions issue? Try "chmod 755 /system/etc/install-recovery.sh"
If that didn't help, please run this command as root to copy "init.rc" to your sd card, then post the file here:
Code:
cp /init.rc /sdcard/
Click to expand...
Click to collapse
thanks~
I checked the permission, it is 755 rwxr-xr-x.
the init.rc is attached herewith.

devetle said:
thanks~
I checked the permission, it is 755 rwxr-xr-x.
the init.rc is attached herewith.
Click to expand...
Click to collapse
Hmm, your init.rc seems fine, it executes install-recovery.sh at boot:
Code:
service flash_recovery /system/etc/install-recovery.sh
oneshot
Could you please type "mount" after mounting your ext2 partition and post the output?
By the way I noticed some differences on your init.rc wlan configuration, what's your firmware?

mount says: /dev/block/mmcblk0p2 /system/sd ext2 rw,relatime,errors=continue 0 0
I saw another thread. It adds "sleep 10" before mounting ext2 so that the sdcard is "ready". And someone said that is not necessary.
I'm really confused.
BTW, my firmware is:
Android version
2.2.1
Baseband version
S5830ZCKC1
Kernel version
2.6.32.9-perf
[email protected] #1
Wed Mar 16 19:45:24 KST 2011
Build number
FROYO.ZCKC1

devetle said:
mount says: /dev/block/mmcblk0p2 /system/sd ext2 rw,relatime,errors=continue 0 0
I saw another thread. It adds "sleep 10" before mounting ext2 so that the sdcard is "ready". And someone said that is not necessary.
I'm really confused.
BTW, my firmware is:
Android version
2.2.1
Baseband version
S5830ZCKC1
Kernel version
2.6.32.9-perf
[email protected] #1
Wed Mar 16 19:45:24 KST 2011
Build number
FROYO.ZCKC1
Click to expand...
Click to collapse
Okay, let's check if install-recovery is actually run at boot. Execute the attached script which will add some checks on boot time, and reboot your phone. Then check if the following files exist and post their contents:
/data/local/tmp/test1
/data/local/tmp/test2

Sent from my HTC HD2 using XDA App. Yvyg hggvhbhggbgggggvb vgghbhvggvbvv556r5rrdvvby6t

aaaaaaaaaaaaaaaaaaaaaaaaaaaa

aaaaaaaaaaaaaaaaaaaaaaaaaaaaaa

devetle said:
From the test script, the install-recovery.sh is running!
However, in the install-recovery.sh, the mount says: mount: No such file or directory.
It really looks like I need to add a sleep 10 here...I'll try.
Click to expand...
Click to collapse
Oh, it seems that I have the same thing "mount: No such file or directory" but it works just fine.
I'll consider adding sleep to my script. Thank you for your feedback

Thank you for your help!

Hi majedev,
i have tried running your script and it just runs fine. but still i am not able to see system/sd after rebooting the phone. i have installed darktremors a2sd(by booting into recovey and running update.zip) and the installation went just fine. but still my phone internal memory is showing the same. so what should i try now? i have tried installing recovery.sh that u posted. still doesnt works. i have tried rooting and unrooting the phone and then again tried all the steps but no go.
so please guide me what should i do next? may be flash the firmware? factory reset?

harrythescorpion said:
Hi majedev,
i have tried running your script and it just runs fine. but still i am not able to see system/sd after rebooting the phone. i have installed darktremors a2sd(by booting into recovey and running update.zip) and the installation went just fine. but still my phone internal memory is showing the same. so what should i try now? i have tried installing recovery.sh that u posted. still doesnt works. i have tried rooting and unrooting the phone and then again tried all the steps but no go.
so please guide me what should i do next? may be flash the firmware? factory reset?
Click to expand...
Click to collapse
If you were following the discussion then you most probably have the same problem as devetle did. I've updated the script so it sleeps for 5 seconds after mounting. You may want to redo the guide once again and download the updated script file.
I hope that helps.

I've made the kernel modules for ext3 and ext4. Kernel: 2.6.32.9-perf.
install-recovery.sh:
Code:
#!/system/bin/sh
insmod /system/lib/modules/jbd.ko
insmod /system/lib/modules/jbd2.ko
insmod /system/lib/modules/ext3.ko
insmod /system/lib/modules/ext4.ko
mount -t ext2 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
Haven't tested it yet, but the modules insmod just fine. And a2sd says ext3 and ext4 are supported.
Maybe someone with knowledge and guts can test it by converting the partition to ext4, so install-recovery.sh becomes:
Code:
#!/system/bin/sh
insmod /system/lib/modules/jbd.ko
insmod /system/lib/modules/jbd2.ko
insmod /system/lib/modules/ext3.ko
insmod /system/lib/modules/ext4.ko
mount -t ext4 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
Pls don't test it if you have the dalvik cache on your sd. You can end up with an bootloop if it doesn't work.

Hi majedev,
now that worked! now if i run the df command i can see the system/sd that shows me a capacity of approx 964.1123mega bytes, which is the ext2 partition that i created. now the issue is that i cannot see my phone's internal memory increased.
its still the same.
when i run the diskcheck command in a2sd (a2sd discheck) , it says me that:: displaying disc space statistics on sd card :
-h: no such file or directory
/dev/block/mmcblk0p2: 144220k total, 12k used.
and in another of your posts, u have said that if the phone ,memory doesn't increases, try command: a2sd install, which i have also tried and gives me the following output: mv: cant rename ' data/app-private/*' no such file or directory and then it says, time, date, test, expr echo: applet not found etc..
i tried to move the delvik cache to sd card by using the command : a2sd cachesd, and it was successful, the free space increased by like 10mb's. then i ran a2sd check and it also verified the same that the cache is running from sd card. i also trying moving it back to phone, it also worked fine as well.
so where is the glitch? the card is mounted. i am able to see system/sd, i am able to move cache to sd, but still internal memory is showing as 91 mb free??
and moreover my apps and market etc have disappeared? (i have backed then up using titanium bacup, i think ill be able to recover them from there) so what should i do next?
PS: BTW i am using latest beta 4 version 2.7.5.3 of a2sd

harrythescorpion said:
Hi majedev,
now that worked! now if i run the df command i can see the system/sd that shows me a capacity of approx 964.1123mega bytes, which is the ext2 partition that i created. now the issue is that i cannot see my phone's internal memory increased.
its still the same.
when i run the diskcheck command in a2sd (a2sd discheck) , it says me that:: displaying disc space statistics on sd card :
-h: no such file or directory
/dev/block/mmcblk0p2: 144220k total, 12k used.
and in another of your posts, u have said that if the phone ,memory doesn't increases, try command: a2sd install, which i have also tried and gives me the following output: mv: cant rename ' data/app-private/*' no such file or directory and then it says, time, date, test, expr echo: applet not found etc..
i tried to move the delvik cache to sd card by using the command : a2sd cachesd, and it was successful, the free space increased by like 10mb's. then i ran a2sd check and it also verified the same that the cache is running from sd card. i also trying moving it back to phone, it also worked fine as well.
so where is the glitch? the card is mounted. i am able to see system/sd, i am able to move cache to sd, but still internal memory is showing as 91 mb free??
and moreover my apps and market etc have disappeared? (i have backed then up using titanium bacup, i think ill be able to recover them from there) so what should i do next?
PS: BTW i am using latest beta 4 version 2.7.5.3 of a2sd
Click to expand...
Click to collapse
Do you have BusyBox installed?

peeter123 said:
I've made the kernel modules for ext3 and ext4. Kernel: 2.6.32.9-perf.
install-recovery.sh:
Code:
#!/system/bin/sh
insmod /system/lib/modules/jbd.ko
insmod /system/lib/modules/jbd2.ko
insmod /system/lib/modules/ext3.ko
insmod /system/lib/modules/ext4.ko
mount -t ext2 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
Haven't tested it yet, but the modules insmod just fine. And a2sd says ext3 and ext4 are supported.
Maybe someone with knowledge and guts can test it by converting the partition to ext4, so install-recovery.sh becomes:
Code:
#!/system/bin/sh
insmod /system/lib/modules/jbd.ko
insmod /system/lib/modules/jbd2.ko
insmod /system/lib/modules/ext3.ko
insmod /system/lib/modules/ext4.ko
mount -t ext4 /dev/block/mmcblk0p2 /system/sd
/system/bin/sh /system/etc/init.d/dtapp
/system/bin/sh /system/etc/init.d/99complete
Pls don't test it if you have the dalvik cache on your sd. You can end up with an bootloop.
Click to expand...
Click to collapse
Dude these are hot stuff, I'll give it a shot after finishing my homeworks :'(
But don't you think ext3/4 journaling is too much I/O for sd cards?

Related

modified: Installing & Run application on sdcard

WARNING: Proceed at your own risk, this may damage your phone and/or make it unstable. This is for advanced users only and should only be attempted by those who understand the risks of the following changes
Original post: http://www.androidin.net/thread-1099-1-1.html
AS usual, this is for those WITH ROOT ONLY
Preparation:
1. Installed JF RC30 V1.2 (only if you are using JF RC30 1.2 , this is not compatible with RC8)
2. Make a NANDROID backup (you may get everything back to normal if the phone screw up)
3. A MICRO-SD card with 2 partitions divided : (1) a fat-32 partition, (2) a ext2, you need a linux/mac to format the sdcard with ext2 partition
* the fat 32 will be mounted as sdcard and the ext2 will be mounted as /sd for application data, make your own decision for the size*
4. insert the sdcard with 2 partition on the phone
5. set the phone to aeroplane mode for safe
Procedure:
1. adb pull /system/etc/mountd.conf /*somewhere you may want to back it up*
2. rm -f /system/etc/mountd.conf
3. using the modified mountd.conf, adb push /*the path of modified mount.conf */mount.conf /system/etc/mountd.conf
4. adb pull /system/init.rc /*somewhere you may want to back it up*
5. rm -f /system/init.rc
6. using the modified init.rc, adb push /*the path of modified init.rc*/init.rc /system/init.rc
7. reboot
8. busybox cp -a /data/app /sd/
9. rm -r /data/app
10. ln -s /sd/app /data/app
11. reboot
Now, the phone will install and run everyone on /sd, still mounting /sdcard as usual. It is possible that to mount or unmount /sdcard by usb without everything screwed up. Beware that your sdcard will be used as part of system, removing the sdcard may freeze the phone. If the phone get freeze because of removing the sdcard, plug the sdcard again and soft reset.
It is also possible that copy the application data to another card. If you want to change the sdcard, switch the phone off, mounting the sdcard to computer directory, copy the /sd partition to another sdcard with ext2 partition
Back to normal:
1. rm -f /system/etc/mountd.conf
2. adb push /*the backup of mountd.conf* /system/etc/mountd.conf
3. rm -f /system/init.rc
4. adb push /*the backup of init.rc* /system/init.rc
5. busybox cp -a /sd/ /data/app
6. rm -r /sd/
Change of mountd.conf:
changing /dev/block/mmcblk0 to /dev/block/mmcblk0p1
change of init.rc:
adding
insmod /system/modules/2.6.25-01843-gfea26b0/kernel/fs/ext2/ext2.ko
mknod /dev/mmcblk0p2 b 179 2 1000
mount ext2 /dev/mmcblk0p2 /sd noatime nodiratime
Any chance of this being simplified into the actual commands necessary for this!?
I'm a semi-noob at *nix stuff... I can format my SD card into 2 partitions, but I'm lost at step 4... What do we need to edit??
Changed step 4...just adb pull the mount.conf for editing..open the file in text editor..find "mmcblk0" and change it "mmcblk0p1" ..save the .conf...del the original one..push the new one to the original directory..
Yay. Now hopefully we can get this in an update.zip to flash
Yeah, I'm putting off doing this until someone makes an update.zip which I definitely know how to apply and get rid of if I screw anything up
REPLACES the internal memory...?
So the internal memory isnt used?
kinda the same trick as the browser cache and market cache, just a bit more complex as its an entire filesystem your moving, which wouldnt let the sys see the internal, mem, please correct me if im reading it wrong, Im not a total noob at linux but no guru dev either...
bhang
The internal memory is still used, just not for /data/app
19.rm -r /data/app
20.ln -s /sd/app /data/app
Click to expand...
Click to collapse
It should probably be /sdcard/app. In any case, this is a fairly complex mod that is not suited for Linux newbies. I would advise against folks considering this mod unless they understand and can test each step before attempting.
I agree and added a warning to the first post
Ummm yea, so what happens when you mount your sdcard for storage? I expect the phone goes crazy?
This tutorial, if you could call it that,(no offense) is really badly written and this process seems too risky for what you gain considering that if we are patient google will come out with this themselves.
Stericson
Stericson said:
Ummm yea, so what happens when you mount your sdcard for storage? I expect the phone goes crazy?
This tutorial, if you could call it that,(no offense) is really badly written and this process seems too risky for what you gain considering that if we are patient google will come out with this themselves.
Stericson
Click to expand...
Click to collapse
The procedure calls for two partitions on the microsd, one FAT32, other EXT. Theoretically it should work with mounting for mass storage. However, I agree that it's a rather sloppy hack.
There is talk about a similar strategy being officially implemented by the Android team. Instead of two partitions, it would be loopback mounted to a file in the FAT32. That would also provide some encryption security. See here. It's just talk though. Won't be a reality for at least a few months.
Well talk is certainly better than nothing...thanks for the info....
Stericson
I post a method withtout compiling the ramdisk.img but that do not force mounting the sd ext2 drive under rootfs but still workable...probably when i back to work I can compile 1 to flash
Am I the only one that thinks there are a few things that are getting 'lost in translation' here?
I'm not getting /sd mounted properly upon reboot...there's no way I'm going to continue attempting this till I see a better (no offense) tutorial or do a little more research on the command lines.
I would really shy away from this if you're an average user or don't know what mountd and init.rc files are used for....this could flat out wreck your phone.
TheDudeOfLife said:
Am I the only one that thinks there are a few things that are getting 'lost in translation' here?
I'm not getting /sd mounted properly upon reboot...there's no way I'm going to continue attempting this till I see a better (no offense) tutorial or do a little more research on the command lines.
I would really shy away from this if you're an average user or don't know what mountd and init.rc files are used for....this could flat out wreck your phone.
Click to expand...
Click to collapse
/sd is /sdcard (mount point for the micro sd card's partition)
I'm getting stuck right here:
8. busybox cp -a /data/app /sd/
9. rm -r /data/app
10. ln -s /sd/app /data/app
11. reboot
It's saying read only system blah blah, even though I have indeed mounted it is rw
pershoot said:
/sd is /sdcard (mount point for the micro sd card's partition)
Click to expand...
Click to collapse
No....no it is not.
/sd is a mount of the ext2 partition used for the 'copy' of /data/app (one of the things i disagreed with is picking /sd as a mount point for the second partition.)
/sdcard is the fat32 mount point...used as usual for mounting files.
IzzeLing said:
I'm getting stuck right here:
8. busybox cp -a /data/app /sd/
9. rm -r /data/app
10. ln -s /sd/app /data/app
11. reboot
It's saying read only system blah blah, even though I have indeed mounted it is rw
Click to expand...
Click to collapse
Type mount in adb shell and see if /sd is even mounted. I wasn't seeing it in my list. I don't think his mount command in the init.rc is correct, but I'm too busy with holiday stuff.
Don't rm -r /data/app if you have not 100% verified the copy works.
This line looks mangled (need flags in the args):
Edit: nevermind, looks like it should work in the init.rc
TheDudeOfLife said:
No....no it is not.
/sd is a mount of the ext2 partition used for the 'copy' of /data/app (one of the things i disagreed with is picking /sd as a mount point for the second partition.)
/sdcard is the fat32 mount point...used as usual for mounting files.
Click to expand...
Click to collapse
ahh yea. i just re-glanced over the instructions.
cool.
TheDudeOfLife said:
Type mount in adb shell and see if /sd is even mounted. I wasn't seeing it in my list. I don't think his mount command in the init.rc is correct, but I'm too busy with holiday stuff.
Don't rm -r /data/app if you have not 100% verified the copy works.
Click to expand...
Click to collapse
Yeah, don't see it. Hm.

Unable to mount loopback

I created a zeroed file with dd and attempted to mount it with:
mount -o loop /sdcard/test.img /data/test
and
losetup /dev/block/loop0 /sdcard/test.img
However, no loopback devices are displayed when I invoke mount. Can anyone clue me in? Feel like i'm missing something basic. By the way, I am running these commands from Saurik's busybox with the losetup /dev/block/loop fix.
p.s. I'd ask on the G1 hackers mailing list, but it's gone a bit bonkers in the past few days.
I'm not sure, but doesn't the image file you're trying to mount have to contain an actual file system?
Yea, I subsequently created a filesystem for it with mke2fs (which is mysteriously missing from busybox for android?). Still no go. Same when I tried to mount other partition-in-a-files like the module.cramfs or recovery.img
If I try to losetup the loop device then mount that, it returns error:
mount: mounting /dev/block/loop0 on /data/test failed: No such device
If I try to mount directly with -o loop, it returns:
mount: cannot setup loop device: No such file or directory
And yet Saurik seems to have been able to loop mount fine. Perhaps it is because I am testing on the qemu instead of hardware?
That might be it. You might try busybox's mount also.
But yeah, It definitely does work on the phone at least.
I've been trying to figure out how to load debian on the emulator, but I can't get the ext2 image mounted. I had to recompile the kernel first so support loadable modules, but even after that, it would not work (can't remember the specific error). Has anyone gotten an ext2 file system mounted on the emulator successfully?
The reason I'm doing this is so I can do native compiles, without actually having to do it on the phone. It has advantages in that I can crank up the clock speed and the RAM.
So I was able to mount loopback just fine on the actual hardware, but i'm having trouble getting it to run from the init.rc file. This is what i'm typing at the shell (it works):
(after insmod ext2.ko)
mount -o loop,noatime,nodiratime,nosuid,nodev -t ext2 /sdcard/loopy/app.img /data/app
It works fine and i'm able to install and run apks from the sdcard (/dev/block/loop2 on /data/app type ext2). Of course this is no good unless it can be mounted before the launcher starts (or it won't see any of our apks). The syntax for init mounting is different from sh, so I tried this (this is in /data/init.rc btw):
on userdata
#mount loopback file from sdcard
insmod /system/modules/2.6.25-01843-gfea26b0/kernel/fs/ext2/ext2.ko
mount ext2 /sdcard/loopy/app.img /data/app noatime nodiratime nosuid nodev loop
I know the script is being run since the ext2.ko module is getting installed. But the mount command isn't being executed. Can anyone shine a light on this? I'm not very familiar with the init daemon.
jashsu said:
So I was able to mount loopback just fine on the actual hardware, but i'm having trouble getting it to run from the init.rc file. This is what i'm typing at the shell (it works):
(after insmod ext2.ko)
mount -o loop,noatime,nodiratime,nosuid,nodev -t ext2 /sdcard/loopy/app.img /data/app
It works fine and i'm able to install and run apks from the sdcard (/dev/block/loop2 on /data/app type ext2). Of course this is no good unless it can be mounted before the launcher starts (or it won't see any of our apks). The syntax for init mounting is different from sh, so I tried this (this is in /data/init.rc btw):
on userdata
#mount loopback file from sdcard
insmod /system/modules/2.6.25-01843-gfea26b0/kernel/fs/ext2/ext2.ko
mount ext2 /sdcard/loopy/app.img /data/app noatime nodiratime nosuid nodev loop
I know the script is being run since the ext2.ko module is getting installed. But the mount command isn't being executed. Can anyone shine a light on this? I'm not very familiar with the init daemon.
Click to expand...
Click to collapse
Try
mount ext2 [email protected]/sdcard/loop/app.img /data/app noatime nodiratime nosuid nodev
JesusFreke said:
Try
mount ext2 [email protected]/sdcard/loop/app.img /data/app noatime nodiratime nosuid nodev
Click to expand...
Click to collapse
Tried that one earlier too. No love.
jashsu said:
Tried that one earlier too. No love.
Click to expand...
Click to collapse
I betcha the sdcard hasn't been mounted yet.
Is there anything in dmesg that looks relevant? Or maybe logcat?
Try temporarily moving the image file to /data, and see if you can get it to mount. That should verify that it has something to do with it being on the sdcard
JesusFreke said:
I betcha the sdcard hasn't been mounted yet.
Is there anything in dmesg that looks relevant? Or maybe logcat?
Click to expand...
Click to collapse
Agh! You're right. The mount daemon runs at line 192, in the services section. Long after the /data/init.rc is parsed.
service mountd /system/bin/mountd
socket mountd stream 0660 root mount
Any way around this short of manually mounting the sdcard in the /data/init.rc?
Edit: dmesg bingo:
<3>[ 1.920368] init: unable to mount [email protected]/sdcard/loopy/app.img to /data/app
as ext2
<6>[ 1.921498] yaffs: dev is 32505860 name is "mtdblock4"
<6>[ 1.922016] yaffs: passed flags ""
<4>[ 1.922322] yaffs: Attempting MTD mount on 31.4, "mtdblock4"
<4>[ 1.927204] yaffs: restored from checkpoint
<4>[ 1.927845] yaffs_read_super: isCheckpointed 1
<3>[ 1.960002] init: unable to mount /system/xbin.cramfs to /system/xbin as c
ramfs
<3>[ 1.965221] init: service 'console' requires console
<4>[ 2.161895] mmc_sd_init_card: Delay 250 ms
<4>[ 2.522535] mmc1: host does not support reading read-only switch. assuming
write-enable.
<6>[ 2.523359] mmc1: new SDHC card at address cd4e
On a side note, it looks like the mount action for xbin.cramfs in the main init.rc is failing because it's redundant with an earlier mount in /system/init.rc. I'm guessing this is a vestige of development on cramfs loopback mounting (mentioned here by Saurik).
6) at Jesus Freke's suggestion, setup /system/xbin (and later /system/modules) to mount from a compressed image
Click to expand...
Click to collapse
Yeah, I had left in an extra mount for xbin.cramfs in the base init.rc. I believe that's fixed in v1.3. I'll check again and make sure
So I gather the reason for wanting to mount a loopback device is to be able to create an ext2 fs as a file on the sdcard fat fs instead of creating 2 separate parittions on the sdcard , one for fat and one for ext2?
If this can be done, this would be a much better solution for getting apps to run on the sdcard than the previous hack which requires creating an ext2 partition on the sdcard.
Yeah that was what I was looking into. However as noted above, the I couldn't mount the image on the sdcard because the point at which /data/init.rc gets parsed occurs before the sdcard service starts up. The partition method doesn't have this problem because it creates a node for paritition #2 in the init.rc
jashsu said:
Yeah that was what I was looking into. However as noted above, the I couldn't mount the image on the sdcard because the point at which /data/init.rc gets parsed occurs before the sdcard service starts up. The partition method doesn't have this problem because it creates a node for paritition #2 in the init.rc
Click to expand...
Click to collapse
so u can't mount the sdcard in /data/init.rc?
dwang said:
so u can't mount the sdcard in /data/init.rc?
Click to expand...
Click to collapse
Not sure, I didn't try mounting partition #1. You could give it a shot by using mknod in /data/init.rc like the parted sdcard method. The sdcard service might not like that the card has already been mounted though.
There are two major reasons I abandoned this concept. The first is I didn't want to figure out how to get permission to mount /sdcard (since / is ro). The second is that making the sdcard available as a usb mass storage device makes it exclusively unaccessible from Android. I suppose that might not be so bad if you are only offloading /data/app, as long as you don't try to execute any new apps while your mass storage connection is going. It's non-ideal.
jashsu said:
Not sure, I didn't try mounting partition #1. You could give it a shot by using mknod in /data/init.rc like the parted sdcard method. The sdcard service might not like that the card has already been mounted though.
There are two major reasons I abandoned this concept. The first is I didn't want to figure out how to get permission to mount /sdcard (since / is ro). The second is that making the sdcard available as a usb mass storage device makes it exclusively unaccessible from Android. I suppose that might not be so bad if you are only offloading /data/app, as long as you don't try to execute any new apps while your mass storage connection is going. It's non-ideal.
Click to expand...
Click to collapse
I don't think the 2nd reason is that big of a deal. If google is planning on implementing the file based method for apps on the sdcard, they could just block access to apps when the sdcard is mounted to a pc. Its a lot better than the alternative of having to create a 2nd ext2 partition on the sdcard. Of course google should have really solved this issue before the g1 came out.
Anyways, I don't see /data/init.rc on my jf rc 1.2 g1. I only see /init.rc and /system/init.rc. Is /data/init.rc something that you created just for the purpose of mounting the file.
dwang said:
I don't think the 2nd reason is that big of a deal. If google is planning on implementing the file based method for apps on the sdcard, they could just block access to apps when the sdcard is mounted to a pc. Its a lot better than the alternative of having to create a 2nd ext2 partition on the sdcard. Of course google should have really solved this issue before the g1 came out.
Anyways, I don't see /data/init.rc on my jf rc 1.2 g1. I only see /init.rc and /system/init.rc. Is /data/init.rc something that you created just for the purpose of mounting the file.
Click to expand...
Click to collapse
Yeah it's referenced in /init.rc Easier to use since unlike /system/init.rc, it's not in a ro folder. You could use /system/init.rc too. Either way really.
jashsu said:
Yeah it's referenced in /init.rc Easier to use since unlike /system/init.rc, it's not in a ro folder. You could use /system/init.rc too. Either way really.
Click to expand...
Click to collapse
Ok.. I'll probably just stick with partitioning the sdcard into fat and ext2. Its working well for me and there really isn't a whole lot of advantages having the ext2 as a file on the fat partition.
I have 41 apps installed on the sdcard now (including some huge games like bonzai blast and brain genius deluxe) and I still have 59 megs of free internal storage. I think everybody that has a rooted g1 should put apps to the sdcard.

paragon problem

Ok, i searched and couldn't find much about my problem with trying to partition my sd card to get ext2. when i try to partition in paragon it tells me this when i click on the sd card:
A new partition cannot be created on this hard disk. Most probably, all primary slots are occupied and there is no extended partition.
I tried reformatting the memory card to see if that would help, but it didnt change anything. So why is my sd card only allowing one primary partition? Is there any way around this problem? I tried on a 1gb card i had laying around and it will let me do it just fine, just not to my 8gb.
It doesnt work with Windows 7 either. And i tried compatibility modes.
You have to go into the advance mode. which is on the bottom of the main blue screen when you open it up. Then you have to delete the partition on your card. After that hit Apply(the green checkmark at top). right click on your sd where its says unallocated space and create the fat32 partition to the size you want and then use the rest of the space to create the ext2 partition no bigger than 2gb. When you have the two partitions hit apply and follow the directions it gives you. It mostly runs on its own at that point but you will need to restart the computer when it asks you to. make sure you do this through an adapter and not usb because it will show an error message after restart.
OK i deleted the partition but it only gives me the option to test the surface or something like that, i've tried the apply button twice now, and it just takes a few seconds and says its done, it says its unallocated now but when i explroe it in paragon i can see all my files still but it doesnt show on the computer anymore. it still has the same name and everything in paragon, but i still can't format it or create a partition, so right now i can't do anything else with it in paragon. in disk management i can see its there though and format it so i tried creating a simple volume on it leaving 100mb open for ext2 but after i do that i can't do anything else with the unallocated space in disk management and paragon still only sees the fat32 part of it, so i deleted the whole partition again and just did fat32. is my sd card just pure **** or what?
DO this
I had the same problem till today until i first formatted sd to single partition ie. fat 32 and then used my phone to partition it using the following steps-
You will need to download the attached file
and dump mke2fs and sdsplit or http://www.mediafire.com/?d9ceg9sbi2g files on your sdcard
There should not be any data except the files you downloaded.
BEFORE WE BEGIN, THIS WILL ERASE YOUR SDCARD, BACKUP BEFORE YOU START!
Step 1 - We're going to Partition your sdcard
open terminal emulator
$ su
# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
# busybox cp -a /sdcard/mke2fs /system/
# busybox cp -a /sdcard/sdsplit /system/
# cd system
# chmod 777 mke2fs
# chmod 777 sdsplit
******************************************
This is important! What size is your sdcard? If it's a 1gb and you want to share 50-50 then move to the next step and use 500m otherwise you have some very simple maths to do. 1gb is 1000mb (not actually but for simplicity...) if your card is 4gb and you want 500mb app space you need to specify 3500m. if it's 8gb and you want 1gb you would specify 7000m take the size you want for apps away from the size of your sdcard, add an m to the end and that is your magic number.
*******************************************
# sh sdsplit -fs MAGICNUMBER --pmke2fs /system/mke2fs
DOnt forget to put m after magic number like write 7000m instead of 7000
If all goes well you now have 2 partitions to your sdcard: you should get a message like this
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1 62 7277445+ b Win95 FAT32
/dev/block/mmcblk0p2 63 968 497983 83 Linux
If you have, congrats. my next post in this thread will explain how to move your application, but pat yourself on the back, the hardest bit has been done!!!!!!
If any error come on copying data back to sd like can't mount sd dont worry.
It should be good till creating ext2 partition.
If not please follow go back to the beginning and follow these steps exactly.
Step 2 Mounting you're new linux partition.
Ok dump init.rc and mountd.conf on your sdcard (the windows portion - which is the only part that will appear) I highly recommend at this point you copy a update.zip onto your card just incase everything goes horribly wrong
Open Terminal emulator
$ su
# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
# mkdir /system/sd
# busybox cp -a /sdcard/mountd.conf /system/etc/mountd.conf
# busybox cp -a /sdcard/init.rc /system/init.rc
# reboot
I recommend a nandroid a before partition and wipe after partition.
Now everythings done. Download APPS to sd apps and move your apps.
COngrats.
.There may be other methods but others didn't work for me but this one did.
I also had the same problem exact same. I f****ed my sd with paragon and this saved me.
ok so after windows still wouldnt see the sd card in my computer, i checked it again and even though i assigned it a drive letter it didnt show up so i assigned it one again. so then the computer seen it so i decided to play with paragon again. this time though it let me partition it, idk why it was so goofy before but i got it setup now. i wanted to give 100mb to ext2 but since i have to use the slider i could only give 77 or 155, 77 a little low and 155 to high since the cards about filled as it is, so ill see how 77mb works. thanks for the help
do as said
Make it atleast 500 mb Will work better with it or u have to repartition it.

[DEV][DATA2SD] More space (and more I/O) for your Desire (Updated/EXT4/Flashable ZIP)

HI all.
I know it has been already done but I didn't find any detailed tutorial for the hTc Desire so I wrote one for you
Howto for a HTC desire with clockworkmod recovery:
I did this with a stock HTC sense 2.2 froyo rooted rom with init.d support and my own kernel, forked from richardtrip sense kernel v5e. I don't know for other ROMs or Kernels. Your ROM must support init.d boot scripts.
What you need is:
* Fast µSD card (Class 4 or 6 recommended. Lots of issues reported with class 10 on the Desire)
* busybox (http://www.busybox.net/downloads/binaries/) on c:\
* Kernel with EXT4 support. The kernel in original ROM does not provide ext4 support!!
* Rom with init.d script support (StarBurst (Froyo) or Supernova (Gingerbread) have a native DATA2SD support)
* If you already have app2sd+ or a similar script, don't do the following hack (or at your own risks) !!
* If you still want to try it, backup your A2SD scripts and roll-back to a pre-A2SD state. Don't ask me why it's not working, I never used APPs2SD so I can't help.
* To help you with ADB, you can use the GUI
If you feel a bit lazy or you're scared to make any mistake and want to skip all the manual installation, then go straight to the bottom of this post and download the flashable script made by droidzone. Many thanks to him!! You can also flash Supernova (Stock HTC gingerbread release) and you'll be good to go within no time.
If you already have this running but you flashed another rom, have a look here. droidzone posted another script to just update the rom you just flashed to get DATA2SD work properly
[size=+1]1/Get yourself prepared[/size]
A/ backup everything (nandroid).
B/ Make sure everything is backed-up
C/ Copy the content of you SD to your computer and keep it handy for a roll-back.
D/ make a copy !!!! (I think know that you've been warned )
[size=+1]2/ Make 2 primary Mb aligned partitions on your SD[/size]
Primary partition 1 will be your usual storage, must be FAT32.
To optimize it, I really recommend to have a look here
Primary partition 2 will be your new storage (/data).
You can use gparted or fdisk (I do prefer fdisk and wrote a guide here ) to partition your SD; but it's up to you and Gparted is working great too.
Use the MB align option of gparted to align your partitions. This helps big time to get a better R/W speed.
With the latest busybox, you can do that on your phone in recovery mode.
You will need also e2fs progs. They're all attached at the bottom of this howto.
[size=+1]3/ Boot your phone in recovery and get it prepared[/size]
Connect to your phone with "adb shell"
You should get a ~# prompt now.
mount /system
mount /data
mount /sdcard
exit
if mount /sdcard fails, try mount /dev/block/mmcblk0p1 /sdcard
You should get this as a result of a "mount" command:
Code:
~ # mount
mount
rootfs on / type rootfs (rw)
tmpfs on /dev type tmpfs (rw,relatime,mode=755)
devpts on /dev/pts type devpts (rw,relatime,mode=600)
proc on /proc type proc (rw,relatime)
sysfs on /sys type sysfs (rw,relatime)
/dev/block/mtdblock4 on /cache type yaffs2 (rw,nodev,noatime,nodiratime)
/dev/block/mmcblk0p1 on /sdcard type vfat (rw,relatime,fmask=0000,dmask=0000,allow_utime=0022,codepage=cp437,iocharset=iso8859-1,s
hortname=mixed,errors=remount-ro)
/dev/block/mtdblock3 on /system type yaffs2 (rw,relatime)
/dev/block/mtdblock5 on /data type yaffs2 (rw,relatime)
Replace you old busybox exec with the new one. It's located in /system/xbin/
adb push c:\busybox-armv6l /system/xbin/busybox
Add the script to init.d folder:
adb push c:\01data.txt /system/etc/init.d/01data
Add the fstab to /system/etc/
adb push c:\fstab.txt /system/etc/fstab
Extract e2fsprogs-arm.zip to c:\
Push all e2fs progs you've extracted from the zip to /system/bin/ the same way:
adb push c:\e2fsprogs\system\bin\e2fsck /system/bin/
adb push c:\e2fsprogs\system\bin\mke2fs /system/bin/
(etc.... for all apps)
Push all e2fs libs you've extracted from the zip to /system/lib/ the same way:
adb push c:\e2fsprogs\system\lib\libext2_blkid.so /system/lib/
adb push c:\e2fsprogs\system\lib\libext2_com_err.so /system/lib/
(etc... for all libs)
adb shell
cd /system/bin
chmod 755 e2fsck
chown 0.2000 e2fsck
(Do the same for all pushed apps.)
cd /system/lib
chmod 644 libext2*
chmod 755 /system/xbin/busybox
chown 0.0 /system/xbin/busybox
chmod 755 /system/etc/init.d/01data
chown 0.0 /system/etc/init.d/01data
Finally type this:
:> /system/etc/mtab
[size=+1]4/ Instant of creation[/size]
cd /
For a non-journaled version:
/system/bin/mke2fs -T ext4 -b 4096 -E stride=64,stripe-width=64 -O ^has_journal,extent,^huge_file -m 0 -L userdata /dev/block/mmcblk0p2
For a journaled version (safety/AOSP ROMs):
/system/bin/mke2fs -T ext4 -b 4096 -E stride=64,stripe-width=64 -O extent,^huge_file -m 0 -L userdata /dev/block/mmcblk0p2
stride and stripe-width are RAID options but they are used here to align the filesystem to the max erase block size of an SD card. In conjunction with EXT4 extents feature (not present in ext3), it gives a bit of extra performance thanks to block allocation. It's used and recommended for SSDs, so it should help our poor little cheap (SSDs) SD cards
I use 64 because 64x4 (4kb block size)=256Kb. 256Kb is the max erase block size per the SD standards.
Your card may have a smaller erase block size but 256K is at least compatible with every card.
If you want to change the block allocation size, change the "64" parameter.
Just change it to - say - 32 (32x4=128kb) etc ...
Tune this to your actual erase block size if you know it.
If you want journaling (better data integrity) at the cost of performance and probably sd card wear, use the journaled option when you format the ext4 partition. Journal will also use some space on your EXT partition.
Read this article or my tutorial for more details on aligning partition and file system on linux.
I'd like to mention at this stage that fortunately, HTC has implemented a nice and clean unmount of /data at shutdown. Unless you remove your phone battery while it is running or android completely crashes and the cache hasn't been flushed to the sd card, you shouldn't suffer from data loss. In that case though, I've implemented a forced check of the data partition to try to recover any errors on the ext4 partition before booting the phone. You can expect to have a fair amount of safety without journal as long as you turn off your phone with standard HTC menu on sense ROMs
Anyway, if you want to try DATA2SD on a AOSP ROM, you *must* use a journal!
[size=+1]5/ verbatim[/size]
type this:
mkdir /sd
/system/xbin/busybox mount -t ext4 /dev/block/mmcblk0p2 /sd
cd /data
cp -a * /sd
cd /
sync
All you data should copied now.
check with a "ls -l /sd" that you have a least the directory structure.
"df" should report the space used on the new filesystem and should be close to your /data.
/system/xbin/busybox umount /sd
[size=+1]6/ Reboot[/size]
Reboot.
Move all you apps (if you have used the Froyo AP2SD) back to the phone, which is now the SD.
Reboot to get a clean and stable phone
Make sure that you don't install any app in the future to the SD. Some apps are installed automatically to SD, move them back to the phone if it is so.
[size=+1]7/ Comments[/size]
IMHO, a readahead of 128kb could be a bit excessive and can penalise read speed when reading small amounts of data. I've reduced it on my phone to 64kb and noticed a slight improvement when for instance the phone reads data to show apps, icons and size when you open the application list in the settings/applications/manage applications menu. Some kernels have a default value of 4K. This is really bad for performance and it must be changed to get good read performance.
To change it, type this while android is running:
echo 64 > /sys/block/mmcblk0/queue/read_ahead_kb
This setting will be lost on reboot. Just add this line to the script if you want to keep it on reboot.
ownhere did a fantastic job at hacking the libsqlite.so library. I patched the original sense lib and I strongly recommend to replace it with the one attached below.
To do so, just boot into recovery mode, mount /system and backup your /system/lib/libsqlite.so file to your sdcard. Then push the patched lib to /system/lib/ and do a chmod 644 on the pushed file.
Reboot and VOILA!
Updates of the flashable ZIP are available here
If you're coming from previous version (2 FAT32 partitions, ext2 file and loop mount) and want to move to this new one, have a look at this post. You don't have to do everything from start and loose your data. You should get there all the needed info to backup your data and restore it to the new EXT4 partition.
ownhere posted a very interesting option to play with in this post. Apparently nodelalloc mount option is giving better score than delalloc on flash memories. I recently tested it and I had better Quadrant and TAP scores so check-it out!
If you want to impress your friends with Quadrant score, just add "noauto_da_alloc" in the mount option of the script or do this manually with adb shell : busybox mount -o remount,noauto_da_alloc /data
The effect is pretty similar on the final score than nodelalloc (at least on my phone/sdcard )
To get back to normal: busybox mount -o remount,auto_da_alloc /data
(Got this setting from here).
It is simply making the system (thus Quadrant) working in cache (RAM) instead of the SD card.
I'm not sure that this settings improves that much real life usage, but at least you'll get what you're looking for: A super (fake) Quadrand I/O score
I may add this setting in future release of DATA2SD. I'm testing it ATM on my phone.
Many thanks to ownhere and melethron for all their thinkings at bringing issues, help and updates to get to this new version.
Many thanks to too droidzone for his great work on a flashable ZIP and integrating DATA2SD in his ROM to make your life easier you flash maniacs
I hope that I didn't forget something. It's working for me so it should work for you.
Read the thread before asking a question !
This sounds really great ... 2 things :
1. your links are broken
2. Can't we generate the file for /data on the first fat32 partition ... would be a lot easier to format the sdcard with only one partition ...
thank you very much for this great information ...
fogbav said:
This sounds really great ... 2 things :
1. your links are broken
2. Can't we generate the file for /data on the first fat32 partition ... would be a lot easier to format the sdcard with only one partition ...
thank you very much for this great information ...
Click to expand...
Click to collapse
No because you won't be able to use your SD as an external drive when connected to USB.
Just checked the links and they're OK
i vouch for sibere's script... i'm one of first "live testers" for his script and it works great and very, very stable
and from what have been tested by several testers , it can work in these roms :
without a2sd+ :
- rooted stock
- leedroid no-a2sd
with a2sd+ :
- auraxtsense
- defrost
- leedroid
- alex-v
Sibere, allow me to add notes from AndroHero on using the script with a2sd+ rom :
- remove the data2sd (or in auraxt, stuff2sd) from system/etc/init.d in the rom zipfile, or if you have install the rom, just remove from system/etc/init.d
- do the sibere script
Regards
BL
I have follow this easyest tutorial and i'm ok.
All credits to AndroHero for tutorial and to sibere for the hack! I'm only copy and paste from the previous thread!
This tutorial is for all app2sd sense rom so you can follow this tutorial not onfly for lee droid.
As attachment the file that tutorial need.
I have made a 2gb partition for data and is an awesome to see 1.80gb internal memory at first boot!!!!
WOOOOW
Now let's start with tutorial!
------TUTORIAL BEGIN-------
WHAT YOU NEED:
1)Root
2)Android SDK
3)15minutes of time
ALWAYS MAKE A NANDROID BACKUP AND SD BACKUP!!!
LET'S START NOW!
1) download leedroid 2.2f (apps2sd version)
2) unzip the .zip file, open the folder, open the system folder, and then inside that open the folder called etc, you will see a folder called init.d, open that and delete the file called 40a2sd, now just navigate back to the root of the rom and re-zip it.
3) now you need to partition your sd card, use gparted to make 2 fat partitions, a large primary partition and a secondary one about 1gb in size.
4) once you have done that copy the leedroid.zip to the sd card, boot into recovery, do all your wipes and flash the rom, one fashed boot it up and set it up as normal.
5) once set up, hold the power button and choose the option to reboot into recovery.
6) once in recovery connect your phone to your pc, open a command prompt and navigate to the tools folder inside the android SDK.
7) now in the command prompt type the following one at a time:
adb shell
mount /system
mount /data
mount /sdcard
exit
8) now leave the command prompt open and download the file at the bottom of the screen, (i have had to zip it, just open the .zip and the 01data file is inside) and copy it to the root of the c:\ drive on your pc.
9) in the command prompt type (one at a time and always wait for the # to appear again before entering a new command)
adb push c:\01data /system/etc/init.d
adb shell
chmod 755 /system/etc/init.d/01data
cd /
mount /dev/block/mmcblk0p2 /sd-ext
dd if=/dev/zero of=/sd-ext/ext2 bs=1048576
/system/xbin/busybox mke2fs -F -L userdata /sd-ext/ext2
mkdir /sd
/system/xbin/busybox mount -o loop /sd-ext/ext2 /sd
cd /data
cp -a * /sd
cd /
/system/xbin/busybox umount /sd
exit
adb reboot
10) your phone will now reboot with a much bigger /data/ partition.
------TUTORIAL END-------
I suggest to activate the boost!
type in adb shell window with android running:
busybox mount -o remount,noatime,nodiratime /mnt/asec/ext/ext2 /data
sibere said:
No because you won't be able to use your SD as an external drive when connected to USB.
Just checked the links and they're OK
Click to expand...
Click to collapse
Sounds real logical ...8) ... Ups ... shortcut in brain ...8)
bluelavender said:
i vouch for sibere's script... i'm one of first "live testers" for his script and it works great and very, very stable
and from what have been tested by several testers , it can work in these roms :
without a2sd+ :
- rooted stock
- leedroid no-a2sd
with a2sd+ :
- auraxtsense
- defrost
- leedroid
- alex-v
Sibere, allow me to add notes from AndroHero on using the script with a2sd+ rom :
- remove the data2sd (or in auraxt, stuff2sd) from system/etc/init.d in the rom zipfile, or if you have install the rom, just remove from system/etc/init.d
- do the sibere script
Regards
BL
Click to expand...
Click to collapse
Year sure, you're free to add notes mate
will this increase the battery usage?
kakit526 said:
will this increase the battery usage?
Click to expand...
Click to collapse
No effect at all on the battery usage. the usage is around the same .
BL
only one question:
is it better than using a2sd+?
what is the difference?
i had a lot of memory issues with a2sd+ (internal memory decrease very quickly compared to a2sd storage until i get the 'low memory' error message), does this solve my problem?
thanks
bye
Alessandro
Does this really increase IO speed? Can anyone who managed to set this up please post ur Quadrant benchmark.
alessandro_xda said:
only one question:
is it better than using a2sd+?
what is the difference?
i had a lot of memory issues with a2sd+ (internal memory decrease very quickly compared to a2sd storage until i get the 'low memory' error message), does this solve my problem?
thanks
bye
Alessandro
Click to expand...
Click to collapse
Yes, it will solve the problem
The reason why internal memory still decreases with a2sd+ is because not every part of the apps are moved to sd-card . Some of the data parts are still in the internal memory.
This script moves entire data folder to sd card, so nothing in internal memory get decreased
It can be any size you want. So far, the maximum tested size is 2 gb i think was tested by mattiadj & androhero.
BL
I tried once, i got 1956 score (CPU at 998Mhz)
Does this preserve the data on the card? Or do you have to copy everything back on?
Of course I'll have backups, but just asking
coutts99 said:
Does this preserve the data on the card? Or do you have to copy everything back on?
Of course I'll have backups, but just asking
Click to expand...
Click to collapse
it will survive the boot... of course, if you wipe factory data, everything will be gone...but it is safe and survive normal reboot or recovery reboot
BL
This is what is on clean flash of leedroid and after this hack!
I have made a 2gb partition....
Image talks alone....one word: THANKS!
Great job!
Now I expect seeing this bundled into all ROMs around here...
Any improvements are welcome but beside the space can you feel the I/O at some points or is it just a number?
Dude you are legen........ wait for it........... DeRY =D
hope to find a little time to test this awesome tutorial =]
what would happen if the SD card failed? does this render the phone unuseable until a new rom is flashed?

Whatsapp with Multirom

I'm currently using multirom to test android L and use Kitkat, I want to use the same Whatsapp account.
Is it possible if I have the same emei and android id on both roms and I use Helium to sync Chatlogs?
I don't use multirom so I'm not familiar with the data structure but in the 2nd ROM, can you not symlink from the original /data/data/WhatsAppDir to the new one?
Sent from my Nexus 5 using Tapatalk
Do you mean ln -s /data/data/Whatsappfolder /2Rom/data/data/whatsappfolder?
That's a symlink, yes.
Sent from my Nexus 5 using Tapatalk
When trying with download folder I got a error that this function is not implemented (I have root and busybox)
You're maybe doing it the wrong way round. Also I'm not sure if it will work because I don't know the folder structure.
Sent from my Nexus 5 using Tapatalk
dav20011 said:
When trying with download folder I got a error that this function is not implemented (I have root and busybox)
Click to expand...
Click to collapse
I have never linked a data folder on android, but if "ln -s ..." doesn't work, maybe you should try "busybox ln -s ..." ?
keiwop said:
I have never linked a data folder on android, but if "ln -s ..." doesn't work, maybe you should try "busybox ln -s ..." ?
Click to expand...
Click to collapse
Just realised he tried to link the download folder. He cannot link that as it's on /sdcard. You can only link ext4 partitions, not FAT, exFAT, NTFS etc /system and /data are the only linkable directories
rootSU said:
Just realised he tried to link the download folder. He cannot link that as it's on /sdcard. You can only link ext4 partitions, not FAT, exFAT, NTFS etc /system and /data are the only linkable directories
Click to expand...
Click to collapse
Isn't the Nexus 5 /sdcard formatted as ext4 since it's just a FUSE virtual file system of part of the /data partition?
raptir said:
Isn't the Nexus 5 /sdcard formatted as ext4 since it's just a FUSE virtual file system of part of the /data partition?
Click to expand...
Click to collapse
No. /data is ext4 (or f2fs for some of us). /sdcard itself is not ext4. FUSE doesn't support symlinking
You can test it yourself
Code:
su
mkdir /data/data/test
ln -s /data/data/test /sdcard/test
function not implemented
ln -s /data/data/test /data/media/0/test
successful
You can see in /data/media/0/test that symlinking is working. Add a file and it appears in /data/data/test. However, /sdcard/test as it is a symlink, not directory, is not visible or accessible
Is the root dir also use able for symlink? I got a read only error but I changed everything rwx
Edit: Use terminal emulator chmod and not es file explorer
Last question: does anybody know where multirom saves the roms?
i know im late...
But: multirom stores the roms at /data/media/0/multirom/roms
Were you successful using whatsapp on 2 roms?

Categories

Resources