yashsingh1/xdaforums huggingface dataset:
[Android Software/Hacking General [Developers Only]] rush2ashu:
I am completely out of mind.

hi dk_zero-cool,

I seriously need your help.

I think I have screwed my SDCARD. I am not able to mount my FAT32 partition on SD CARD in Android OS.

I was using this until there was some problem with this app to sd application and no support from the DEV. Here.

I am currently using CM 10.1 Jenkins ROM on my P500.

During Flashing of this ROM, I have made a mistake or Running the sd-ext_patch-signed-vXX.zip before actually running the ROM zip file.

That has corrupted my Partition's file.

I have a 32GB card. around 27 GB is FAT32 Primary partition which is set to Active.

I have around 2GB of EXT4 partition which is logical and set to inactive. I am able to see the FAT32 partition in ClockwodRecovery, but when i boot into the ROM. I am not able to see the SD-CARD.

Mounts2SD reports invalid init.d scripts. I can't open any application which refers to SD_card like camera, rom manager or anything.

Here is the partition info that is displayed under settings->About Phone -> Partition info

/System

190MB/190MB

/data

162MB/200MB

/cache

1.14MB/64.00MB

/sdcard (FAT)

0.00B/207MB

/sd-ext (EXT)

0.00B/0.00B

I tried numerous times flashing the ROM.. different rom... but nothing happened.

Another thing, I wanted to add here is when I am trying to clear all data and install a new rom.

I get a error in Recovery when i Wipe /sd-ext

E: Can't mount /dev/block/mmcblk0p2 ( Invalid Argument)

Error mounting /sd-ext/ !

Please help me... :eek: :rolleyes: :(
[Android Software/Hacking General [Developers Only]] efuzone:
I can use adb and fasboot so please tell me if you can provide me fix for it i will do it? if i will move apps and leave dalvik on internal it will full my internal space.. and safemod is already disabled..
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
First off my script has nothing to do with the regular fat32 partition. It does not use it and does not touch it in any way. This is most likely a ROM issue or a flash corruption issue. I would try to format the system partition and reflash the ROM. Also make sure that you have enough space on your system partition to contain the ROM image. Just check the size of /system after flashing and make sure that you have more than 0MB left. If you continue to have this issue, then you will need to raise this issue on your ROM's thread.
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
adb and fastboot will not help you. Init.d is executed from init.rc which is placed inside the ramdisk (boot.img). The only way to alter this is to pull the boot.img from your device, split the parts (kernel and ramdisk), alter init.rc, reassemble the boot.img and reflash it. The procedure for this depends on your device and is not always as easy as it sounds.

But if you can provide me with your boot.img, I can take a look at it.
[Android Software/Hacking General [Developers Only]] efuzone:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Sure i can provide u my device is htc explorer tell me from where i will get boot.img to send u
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Can't tell you as this is also device depended. Each type of device has it's own partition table structure and each manufacturer has it's own tools to work with. As this is an HTC you do have fastboot which can dump partition images, but which partition I can't say. Never had an Explorer my self. You could also extract it from your ROM zip.

I will gladly edit your boot.img, but you will have to figure out how to extract it yourself.
[Android Software/Hacking General [Developers Only]] efuzone:
Hello,

Please check attachment i have attached an boot.img file, I extracted my cyanogen from zip file and found boot.img file on it, please find out and please fix it if you can..
[Android Software/Hacking General [Developers Only]] arquitekno:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

I have FC on developer and backup settings with cm10.1

I think it's because of the script.

Any sugestion?

Enviado desde mi HTC Desire usando Tapatalk 2
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Looked at it and it already have proper init.d implemented, so safe-mode has no affect for you whether it is enabled or disabled. Your problem lies elsewhere, as this being a ROM issue and not related to the script.

Disable r-mount, this is a known issue that will be fixed in the next release
[Android Software/Hacking General [Developers Only]] imkhalid:
I have installed mount2sd from google play and it works flawlessly, but there is a small issue, whenever i reboot my phone it optimizes all the apps every time before coming to main screen, is it normal ??? :(
[Android Software/Hacking General [Developers Only]] efuzone:
No its not normal same issue we are also facing but the developer is saying its not script issue so we have to face it always.. nobody has any solution here..
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Enable debug in the app settings, reboot and provide me with the log. You can save the log to the sdcard from within the app, just go to the Log Viewer and hit menu
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Actually no, I said in your case it is something else. Your ROM has proper init.d implemented which means that dexopt is NOT running when M2SD is being executed. This means that dalvik is not rebuild at any time until after all mount points has been set, which means that the script cannot be the problem.

Your problem is properly that your CM ROM is building system dalvik on your cache partition and that this is being deleted during boot by Android due to missing lines in your init.rc files. However this would be a ROM issue and not a problem that should be handled in this thread. So like I said, raise this issue in your ROM's thread.
[Android Software/Hacking General [Developers Only]] imkhalid:
Find attached log file
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Your ROM is placing system dalvik on /cache. Try to disable the cache option (Not the most important option). That would properly help. If so, I will have a look at the cache option as it should handle CM's system dalvik correctly.
[Android Software/Hacking General [Developers Only]] imkhalid:
'Cache' is set on automatic and 'Dalvik Cache' is checked, now which one should i change ???
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
You should change 'cache' to off. The dalvik-cache option has nothing to do with this as we are not talking about the dalvik-cache for apps, but the one for system apps and framework. Some CM ROM's places this on the cache partition if the cache partition is big enough. However if you have cache set to automatic, then your cache partition is only 40mb or below. That is not good enough to have that feature enabled and I would talk to the one making/releasing your ROM.
[Android Software/Hacking General [Developers Only]] imkhalid:
I am using this ROM http://xdaforums.com/showthread.php?t=1821582 , build#9

I set 'Cache' off and it worked, now OS started normally without optimizing apps.

Thnx for supporting :good:
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Good, I will look into the cache issue, but you should be fine with this turned off
[Android Software/Hacking General [Developers Only]] efuzone:
Hello,

That was what my issue but you said it is rom related issue, i also disabled cache from app and restarted it works i am not getting optimizing issue again thanks..
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
No, I said it might be a ROM issue

OR

related to CM's system dalvik being build on /cache. What I find strange is that your ROM's even build system dalvik on /cache. In CM's commit where they added this feature, they wrote that this feature was made for devices containing at least a 60MB cache. It should not be enabled on devices with less than 40MB as the cache will be filled and might cause app download issues or boot loops. You might want to parse this to your ROM's developer and tell them to consider adding "

dalvik.vm.dexopt-data-only=1

" to the build.prop
[Android Software/Hacking General [Developers Only]] jukooz:
It's my first post on XDA. I was using Link2SD till now and thinking about moving (reinstalling fresh ROM). I don't fullly understand how Mounts2SD works and want to ask few questions. My phone is ZTE Blade with very little internal memory and Class 10 SD card.

1. Speed. Are apps that are on SD slower than those on internal memory? Does Mounts2SD move all my apps to SD? What are recommended Mounts2SD settings? Can I choose "group" of applications for a particular app (I read here that there are 3 groups in Mounts2SD). I use SwiftKey and want it to be as fast as possible - should I treat it in any special way?

2. Does Mounts2SD moves application from internal to SD after their installation like Link2SD does, or it install on SD automatically?

3. I need to have SD-ext partition for it, is EXT2 filesystem ok? What are recommendations regarding SWAP?

Thanks
[Android Software/Hacking General [Developers Only]] gu5t3r:
1. Depends of SD Card Class (Speed), I think class 6 and 10 are same speed as internal...

2. Mounts2SD replaces mounts you select, you can move 3 mounts, /data/app, /data/data, /data/dalvik-cache. If you select to move /data/app and /data/dalvik-cache, whatever you put into this folder is on sd-ext. Apps are automatically installed to sd-ext. There is no annoying linking message and lag...

3. The same sd-ext EXT2 you use for Link2SD is good for Mounts2SD. Swap has linux swap file system, there is no choice.

If you want to migrate, Before all, make a CWM backup.

Install Mounts2SD... Delete Link2SD script in init.d, delete /system/etc/install-recovery.sh, umount /data/sdext2 and rmdir /data/sdext2

This is how I migrated from Link2SD to Mounts2SD, just follow the steps...You need to have kernel that has "exec" init.d support...Easiest way to check is to open /init.rc and search for word "exec", usually there is line "exec /sbin/sysinit" or "exec /system/bin/sysinit"...
[Android Software/Hacking General [Developers Only]] jukooz:
Thanks. I was doing completely fresh install and was installing everything new, so didn't have to "migrate" from Link2SD, but great that this info is here.

One more question: When I connect phone to PC to copy files between PC and SD, does it have impact on SD-ext mount?
[Android Software/Hacking General [Developers Only]] gu5t3r:
When you connect Phone to PC, it only mounts 1st FAT32 partition (/sdcard) to PC, 2nd /sd-ext and 3rd swap partition stay mounted to phone...

The only thing you should care is not to start phone without that mSD card...That could mess up your data because Phone will not found apps and thus may delete their data...
[Android Software/Hacking General [Developers Only]] iamsankalp:
Didn't work

I tried by clearing the dalvik cache but still having the same issue.

Did i need to do something else also with this, regarding app configuration?

Thanks!
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

It seams to be related to cm's system dalvik. You can disable the cache option until I get it fixed
[Android Software/Hacking General [Developers Only]] iamsankalp:
Works! Thank you!

just disabled the cache option from configuration and it worked. Any side-effects?
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Well, seen as M2SD only moves the cache, when set to auto, when the cache is below 40MB, the CM System Dalvik option should not even be enabled on your ROM. The CM System Dalvik is for cache partitions above 60MB. This could cause problems as all your system files dalvik cache will use most of your cache partition which could cause download issues now that M2SD no longer moves the main cache area somewhere else.
[Android Software/Hacking General [Developers Only]] post-mortem:
SD card speed rating (class) is measured by contiguous read/write, while mobile devices mostly read/write small pieces of information. This makes the 4KB random read/write tests more applicable to real-world scenarios. It is generally recommended, therefore, to use a class 4 or 6 SD card. If you're going to record digital video, that's another story (higher class rating is better).

-- Sent from my TouchPad using Communities
[Android Software/Hacking General [Developers Only]] efuzone:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Have you got any fix for cache? For cm9 rom
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

I am currently building a completely new script and doing a complete app rebuild. A am not gonna do any minor fixes on the old script, so until I am done, just keep cache disabled or disable CM's system dalvik (build.prop).
[Android Software/Hacking General [Developers Only]] :
Mounts2SD installed and running, but doesn't swap

(Sorry if this issue has already been discussed in this thread, I frankly don't feel like reading its whole 100+ pages... If so, please point me to the right post.)

I managed to install Mounts2SD 2.2.0 (from the Google Play market) on my brandnew Acer Liquid Z110 Duo (rooted by this method: http://xdaforums.com/showthread.php?t=2073563 , i.e. with stock ROM, custom boot and Clockworkmod recovery, which all work fine). A 4 GB ext3 partition and a 256 MB swap partition are active and detected on my 16 GB SD card, init.d custom scripts are enabled (I used this method successfully: http://xdaforums.com/showthread.php?t=1422061 ; it apparently worked although the ZIP file wouldn't flash from recovery), busybox and sqlite3 are installed, up and running, the Mounts2SD init script is too. The init script starts up okay and Mounts2SD then gives me "green" as its status (though showing the apparently usual "Sqlite3 binary absent" message in its log).

The only trouble is: it doesn't swap internal and external memory (which is the whole point of me installing it ; Link2SD proved unsatisfactory to me). Internal and external memory are shown correctly and reverse mounting is configured correctly, but no swap towards sd-ext is done. What am I missing here? Could it be it's a matter of scripts start-up order in the init process (e.g. stock mounts happening before the swapped mounts and thus impeaching them)? Something to hack in init.rc maybe? In that case I'd need some help, I'm not familiar with init.rc tricks.

Thanks a lot in advance for your thoughts/hints.
[Android Software/Hacking General [Developers Only]] BleedingIris:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

@cocotte67

Post a log screen shot after enabling debug

It should be inside the app.

CM10 HTC A310E ?>? & ??

▶LâTêS†↭ⓛⓘⓝⓚⓢ™◀
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

You do not have to read 100+ pages, just the OP would have been fine. Then you would know about safe-mode.

Also the init.d method that you are using is a very ugly hack which should never be used and which I will not provide support for. Init.d should be implemented directly into the ramdisk and not merged into a file that has a completely different purpose.
[Android Software/Hacking General [Developers Only]] :
See attached file. But dk_zero-cool is right, it's obviously the safe mode that deactivates the mount swap.
[Android Software/Hacking General [Developers Only]] :
You're right. I read your OP before installing, but I completely missed the point about safe-mode.

Looks like I'll have to get to implement init.d in a different way, suggestions anybody? (My phone's stock ROM is Gingerbread, v2.3.6, and the only custom ROM I found so far doesn't use the dual SIM function I Ibought this phone for.)
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
First of all to clarify. The problem in general with the way you implemented init.d and why it should not be used. Init.d (A Linux term, old one actually as to day these scripts works completely different in Linux), is a set of scripts which should be executed during boot. The problem with your way is that the file you added it to is executed AFTER the phone has booted, just before the UI is started. At this point the device is using all of the data content and start moving it around at this point is not a good idea. Your current setup in the app seams to work for you (Because of the safe-mode configurations), but you may encounter a lot of issues at some point, even with safe-mode activated.

About a solution. You could try looking in your device forum section. My guess is that there is a bunch of custom kernels (Also for Stock firmware) which includes a better init.d solution (Maybe not the best one, but at least a much better than what you have now). The upside to this (Other than the init.d part) is that you will get a better kernel. Stock kernels always sucks as the vendors does not spend enough time fine turning them. I would never recommend running any stock kernel. Stock firmware however is a mater of taste (Unless you like Samsungs Touchcrap, then you don't have any :D ). But never stock kernels.
[Android Software/Hacking General [Developers Only]] jkkk88:
You're right but some of us thanks also for this ugly solution. You know when you have locked bootloader :(
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Seriously? Did not think that they still existed. Never the less, it will not be well supported by these types of scripts as most of the work requires doing before UI bootup.
[Android Software/Hacking General [Developers Only]] :
I looked around as you suggested, but no luck so far. My phone is pretty new on the market, so apparently no custom kernels are available yet. Hopefully some developers will look into it soon.

Anyway, thanks a lot for your answers.
[Android Software/Hacking General [Developers Only]] gabrygaggio19:
cm 10

Hi, are unofficial cm 9 and cm 10 for HTC Explorer (Pico) compatible with mount2sd? i tried to install it on cm10 but after reebot the phone didn't restart.

Thanks
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
If you have root access, busybox, init.d and an external sdcard with a second sd-ext partition then yes, it is compatible. My suggestion is to keep the default settings during the first boot. This makes it easier to locate whatever setting might cause you trouble. The default settings are pretty harmless and should not be able to produce many issues.
[Android Software/Hacking General [Developers Only]] BleedingIris:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Why do I see Fat32 as partition type,if mount2SD doesn't support it in the first place?

CM10 HTC A310E ?>? & ??

▶LâTêS†↭ⓛⓘⓝⓚⓢ™◀
[Android Software/Hacking General [Developers Only]] post-mortem:
Which partition are you talking about? The only partition which should be fat32 is the 1st partition of the sd card, which does not get special treatment from Mounts2SD (or other mounting scripts).
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Mounts2SD supports any filesystem which is supported by the kernel. So you would be able to use Fat32 for the sd-ext. Only problem is that Android will properly cause problems as it depends on certain file/folder permissions which is not supported on Fat32 systems.

So, like mentioned above, only Fat32 should be the first partition on the sdcard (External Storage). The second should be a linux file system like Ext(2,3,4), XFS (If supported by the kernel) etc...
[Android Software/Hacking General [Developers Only]] frogerra:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

It's my first time using Mounts2SD, I'm install from Playstore. There's an issue. Some of my app fc after install this app. Any solution to fix this issue? Keep your great work mate.

Edit:

I'm using Xperia Ray, Stock ICS 4.0.4. Ext = 500 mb.

It's X-Ray with Tapatalk!
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
I will need a log, but I can say that if you are using Android 4.2 with R-Mount enabled, then that is your problem. This is known and a fix will come.
[Android Software/Hacking General [Developers Only]] Muhammadsaqlain:
Great solution for my low internal memory

hi Sir ,

First of all I am thankful to you this great script in an app form that is so easy ,simple to handle and safe to use.

I have some odd problems, whenever I move my dalvik cache to sd ext it reduces my internal data (in mount2sd app main screen ) by a large amount. for example it goes from 67mb to 120mb out of 150mb. Also even if I move all my apps to sd ext , after installing some apps my internal data (same screen|) gets filled and I start getting low memory errors or package is invalid errors. Lastly after reboot some apps that are supposed to automatically restart after boot like swift key, setcpu , auto-killer memory optimizer and beats audio , they don't start on their own but I have to open each of them manually to turn them on.(if i move apps to sd )

thankyou for your help
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Do you have R-Mount enabled? Because that reverses the mount points which means that enabling options will move content from external to internal as they have been switched.

A log would help to see how to whole thing is setup
[Android Software/Hacking General [Developers Only]] Muhammadsaqlain:
Sure , this my log file

Please note I have disabled my app to sdext option because of the issues and also internal memory oddly gets fillled up much quiecky in that mode and thirdly becasuse it caused my some fc in some apps.

I have R mount enabled
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
With your current setup, you have app data stored internally and dalvik and apps stored externally. When you enable an option (data, dalvik or app), M2SD will NOT move the content from internal to external. It will instead move the content from /data to /sd-ext. When you have R-Mount enabled, internal is mounted on /sd-ext and external is mounted /data. So by enabling, let's say, dalvik, you will move dalvik-cache from /data (External) to /sd-ext (Internal).

It all depends on the mount points, not the storage devices them self. So where data is moved to depends on where which storage is mounted (Whether R-Mount is enabled or not).
[Android Software/Hacking General [Developers Only]] Muhammadsaqlain:
That was very helfpful indeed.

So this means when I have R mount enabled , I should disable all options that move something to sd ext , to correctly keep them in sd card .Right?
[Android Software/Hacking General [Developers Only]] BleedingIris:
Re: [App/Script] Mounts2SD - An All-in-one sd-ext solution (2.2.0/5.5.0 - Jan 26, 201

Yup.

Unless you want something in your real internal memory

CM10 HTC A310E ?>? & ??

▶LâTêS†↭ⓛⓘⓝⓚⓢ™◀
[Android Software/Hacking General [Developers Only]] dk_zero-cool:
Yes. And if you find it hard to figure out, just uncheck R-Mount in the app, setup the rest and then check R-Mount again. The app will then automatically reverse the rest of the options to keep all data where you just configured them to be.
[Android Software/Hacking General [Developers Only]] ztsoft:
when i use your script on my htc salsa，the progress is so fast,less than 2 seconds.

and i saved the log file,i found two error below,what caused the problem and how can i fix it? thanks so much.