[Q] How to Mount Read Only External SDCard? - Motorola Droid 3

Is there a way to force mount my external SD card as read only? I'm fed up of constant loss of music and the lost.dir file going up. I have tried all sort of troubleshooting, this is just an android problem ( I never had an issue with my blackberry ).
I don't use my external SD memory for anything else since the phone has built in 16GB anyways, and was hoping there is a way to lock writes to the external card. I am rooted. Thanks!

You should be able to use root explorer or a pc, and change the properties of your music folder to read only. Root explorer option is under permissions with a long press on the folder, groups needs write unchecked, not sure what a read only sd card will do, might generate errors, not sure. Quick question, did you reformet the card using the cards format option when you moved it out of your blackberry?
Droid 1 Rooted (ChevyNo1 0.9MV Kernel, LGB2.6)
Droid 3 Rooted (Stock Kernel, Custom lite De-bloat)

verkerria said:
You should be able to use root explorer or a pc, and change the properties of your music folder to read only. Root explorer option is under permissions with a long press on the folder, groups needs write unchecked, not sure what a read only sd card will do, might generate errors, not sure. Quick question, did you reformet the card using the cards format option when you moved it out of your blackberry?
Droid 1 Rooted (ChevyNo1 0.9MV Kernel, LGB2.6)
Droid 3 Rooted (Stock Kernel, Custom lite De-bloat)
Click to expand...
Click to collapse
This ^ You could also do it via a command prompt or disk management. Depends on your skill set.

You can't set those properties on an SD Card. I will try to set the read-only checkmark on the filesystem, but it is FAT32 and file permissions aren't very good... I tried using an NTFS filesystem to no avail...

busybox mount -o remount,ro /mnt/sdcard-ext , it could be added to /system/bin/loadpreinstalls.sh for a permanent solution.

Could we just change permissions on the folder we keep music in? That way the phone can still write to the card if needed
I tried running chmod 055 /sdcard-ext/Music but when I check the permission in my file manager nothing has changed
Sent from my rooted xt860

Endroid,
The problem is that the FAT32 filesystem is too basic for anything including file permissions. The filesystem becomes corrupted because it isn't being properly dismounted (for whatever reason), so even if you denied write access to specific files using a different file system, I'm sure the the corruption would still happen.

danifunker said:
Endroid,
The problem is that the FAT32 filesystem is too basic for anything including file permissions. The filesystem becomes corrupted because it isn't being properly dismounted (for whatever reason), so even if you denied write access to specific files using a different file system, I'm sure the the corruption would still happen.
Click to expand...
Click to collapse
So ultimately no matter what I do my music is gonna keep moving to lost.dir. even if I reformat to NFTS
Sent from my rooted xt860

The phone doesn't even read NTFS... It only takes FAT32 as the SDCard. The best option is the one that was outlined by eww245, mounting the card as a read-only to avoid file corruption.
Although I am relieved to see that my device isn't the only one that is experiencing this sort of issue.

has anyone tried remount the sdcard-ext yet. does it work and did it cause any issues?
also will this affect the usb transfer
edit: seem to be getting alot of high CPU usage warnings. gonna try a reboot to see if it will fix, then rerun command

Did a reboot and reran the command. No CPU issues now, however already some files have moved into lost.dir. i have no experience writing/editing scripts. If anybody wants to write a quick script i could set to run on boot that would be appreciated.

Actually someome earlier mentioned to throw that into the loadpreinstall.sh under /system/bin
But there seems to be a caveat. If you plug the phone in through USB when the phone gets unplugged the device will get re-mounted. I'd like to change the properties of the internal mount instead of overwriting it each time. I have done a lot of checking around and found the vold.fstab file but don't really know how it works.
Another point of interest, what kind of MicroSD card are you using? I've got a Lexar 32GB SDHC10 card installed.

Lexar 16GB 4.
Do I just put
Busybox mount -o remount,ro /mnt/sdcard-ext
At the end of the script?
Sent from my rooted xt860

So this may be completely unrelated, but I ran the command Sunday, and my CPU went nuts. Rebooted tried again and all was good. Didn't use my phone much that day. Today(Monday) my phone died in 4 hours! I did notice my CPU seemed busier than normal. Did a bit of twitter websurfing then my phone went in my pocket for use as a music player. I use my phone with headphones everyday for music for 4-5 hours and I still have at least 30-40 battery left. Only got 3 hours of music. Now, is it possible that my music player(poweramp) is trying to write to the card, or someother app/system process is trying to write to the card, and since it can't it keeps trying. Is there a log I can pull on adb to figure this out? Has anyone else tried this and experienced anything similar?
Sorry for the ramble but I wanna get this figured out
Sent from my rooted xt860

Related

Blank SD card/ Unsupported Filesystem

Using Cyan's tutorials on his wiki, I rooted successfully and am now running Cyan's latest, with his 1.4 recovery.
I finished running the apps2SD tutorial and now the print command reads 2 partitions
Number Start End Size File system Name flags
1 17.4kb 7587MB 7587MB fat32 msftres
2 7587MB 8099MB 512MB ext4
But I'm getting a notification as soon as it boots into android that says.
Blank SD card
SD card blank or has unsupported filesystem
All the amounts under SD card & phone storage settings menu reads: Unavailable. And my internal phone storage reads 46.82MB
Download the recovery image in my sig and use that parition manager.
Thanks alot evilkorn. Worked perfectly.
Cyan should implement something like that into his recovery
CaliLove310 said:
Thanks alot evilkorn. Worked perfectly.
Cyan should implement something like that into his recovery
Click to expand...
Click to collapse
Well its based of 1.4 and cyan said hes spending more time on his roms because Amon_RA made such a good recovery lol
CaliLove310 said:
Thanks alot evilkorn. Worked perfectly.
Cyan should implement something like that into his recovery
Click to expand...
Click to collapse
I think I spoke to soon though. Everything works on the phone, but it wont mount on WinXP.
It mounts on my mac, but when i try to transfer anything to it it gives me an erorr.
The Finder can’t complete the operation because some data in “data” can’t be read or written.
(Error code -36)
"data" (in parantheses) Is the name of the folder im trying to copy to the SD
Mount the file system as -rw, you should be able to find the commands on here some place. I use root explorer so I don't need to remember it =p.
Is it easier with root explorer? Mind telling me how to use root explorer to mount it as -rw like you said
It says remount as R/W.
to mount as r/w in terminal or adb shell:
Code:
mount -o rw,remount /dev/block/mtdblock3 /system
to mount as r/o in terminal or adb shell:
Code:
mount -o ro,remount /dev/block/mtdblock3 /system
CaliLove310 said:
Is it easier with root explorer? Mind telling me how to use root explorer to mount it as -rw like you said
Click to expand...
Click to collapse
You can do this in ES FileExplorer too and its free.
having same issue
I didn't do anything fancy really.
I'm running a moto droid with the 2.01 update that I received over the air.
Today I launched twidroid and it completely ftoze the whole phone, non responsive even on the hardware buttons. I did a battery pull and upon restart the notification window says sd car blank or file system unsupported.
Tried browsing sd card with astro and it shows blank.
Any suggestions? I have a ton of photos and application settings I don't want to lose.
Thanks in advanced!
itsluy said:
I didn't do anything fancy really.
I'm running a moto droid with the 2.01 update that I received over the air.
Today I launched twidroid and it completely ftoze the whole phone, non responsive even on the hardware buttons. I did a battery pull and upon restart the notification window says sd car blank or file system unsupported.
Tried browsing sd card with astro and it shows blank.
Any suggestions? I have a ton of photos and application settings I don't want to lose.
Thanks in advanced!
Click to expand...
Click to collapse
I fail to properly understand the relevance with the Dream/G1 here..Your asking for help on a Droid in a Dream forum?..Maybe one of the other brotherns can fill in de blanks for me.. Thats like going into art class trying to get help for your driving test or putting cofee in ice cream ..Anywho try reformatting the sd something seems to be corrupted
having same issue
Except I didn't do anything fancy. My phone froze while using twidroid and upon reboot my sd card is blank or unsupported filesystem. How can I get my data back?
itsluy said:
Except I didn't do anything fancy. My phone froze while using twidroid and upon reboot my sd card is blank or unsupported filesystem. How can I get my data back?
Click to expand...
Click to collapse
I had this happen to me when using snes/twindroid/barcode/couple more and the weather widget to...Just format the sd in recovery and check for errors with your pc using a sd card reader.
this is the only
Ace42 said:
I fail to properly understand the relevance with the Dream/G1 here..Your asking for help on a Droid in a Dream forum?..Maybe one of the other brotherns can fill in de blanks for me.. Thats like going into art class trying to get help for your driving test or putting cofee in ice cream ..Anywho try reformatting the sd something seems to be corrupted
Click to expand...
Click to collapse
This thread came up on a google search for my issue. Although its a different phone the issue is the same so I figured it was worth a shot. I could start a new thread I guess but didn't want to overpost.
this is the only
Ace42 said:
I fail to properly understand the relevance with the Dream/G1 here..Your asking for help on a Droid in a Dream forum?..Maybe one of the other brotherns can fill in de blanks for me.. Thats like going into art class trying to get help for your driving test or putting cofee in ice cream ..Anywho try reformatting the sd something seems to be corrupted
Click to expand...
Click to collapse
This thread came up on a google search for my issue. Although its a different phone the issue is the same so I figured it was worth a shot. I could start a new thread I guess but didn't want to overpost.
Reformatting will pretty much guarantee that I lose my data. Any other suggestions?
this happened on my g1
I know the poster was getting flack for having 2.01 on his droid but I have cyanogen 4.9...... whatever he's at as of 12/25/2009.
This happened to me I was sending an sms it froze I popped the batt like I've had to do in the past except this time I'm getting a blank sd card error on boot. B4 I repartition and format is there a recovery option? Preferably something I can do from console since I'm in transit from the holiday?
I imagine since we used similar procedures to fix our "smart" phones maybe our recover procedures will be similar.
evilkorn said:
Download the recovery image in my sig and use that parition manager.
Click to expand...
Click to collapse
Please can you tell me where can I get Download the recovery image app ?
I am new just came from iPhone recently got HTC EVO and I am facing this Issue "SD Card blank or has unsupported file system" I tried everything please help.
thanks
Faisal
I have the same message on my G1
My phone is not rooted, and i don't know what to do!
I tried to format my sd card, i have tried with another card, and nothing; the same message!
I don't know what to do in this case....maybe if you have any solution to my problem.
Here is some info about my phone :
Model number : T-mobile G1
Firmware version: 1.6
Baseband version : 62.50s.17U_2.22.19.26I
Kernel version : 2.6.29-00479-g3c7df37 [email protected]#19
Build no : DRC92
anyone ? !!!!!!!!
i really need some help!!!!!
any solution to root without sd card ?

[solved] Card "Preparing SD card; Checking for errors"

Hi all,
I have a problem with my G1, running on latest Cyanogen mod. After restarting the card cannot be read and it is seems to be checking the sd card, if it really happens I dunno. What is weird is that I can access the card from recovery mode (shell), and it is not damaged (at least the windows doesn't detect damage while it is in the card reader. So that implies that the problem might be in the Android system.. anybody has a clue how to solve this? Thanks a lot.
Edit: solved it, deleted fsck_msdos from bin and it works flawlessly again
Can always wipe and reflash. Or if you have another sd card laying around and put that in to see if it recognizes it.
I'm having the same problem How did you delete the fsck_msdos from the bin?
theinstagator said:
I'm having the same problem How did you delete the fsck_msdos from the bin?
Click to expand...
Click to collapse
your phone should rooted
then download and install root explorer
in the root explorer go to
system /bin
and delete fsck_msdos
now reboot your phone
I was having this same issue..it would typically take up to 5 minutes or more to "check for errors" after a boot.
To fix this I backed up my sdcard, reformatted, copied everything back, then reflashed. Everything was fine after that.
i have somewhat the same problem but in my case it sometimes say blank sdcard or damged sd card it read fine when plugged into an sd card reader any help
Thanks. It worked by simply deleting fsck-msdos but it keeps giving SwiftKey3 error " unable to load language packs". Keyboard still OK. I have xperia x10 mini rooted running android 2.1 E10i.
hmaxos said:
Thanks. It worked by simply deleting fsck-msdos but it keeps giving SwiftKey3 error " unable to load language packs". Keyboard still OK. I have xperia x10 mini rooted running android 2.1 E10i.
Click to expand...
Click to collapse
Well, after getting other errors such as "no enough space" from Platinum Backup (there was a space on SD Card), I had to go to Format the SD after copying everything. Then I copied back the important folder the SD. I also had to reinstall SwiftKey. Now everything is fine and no data loss.
SD card Checking for errors
sajjji said:
your phone should rooted
then download and install root explorer
in the root explorer go to
system /bin
and delete fsck_msdos
now reboot your phone
Click to expand...
Click to collapse
Well I will try to backup and format it.... If it works then good if not then I will have to root my LG P880 .
My Problem is "preparing external sd card checking for errors" now that error is not showing while following above steps but now when i click my memory card that is not opening and after opened my memory card my internal device memory also not opening .
baka.yarou said:
Hi all,
I have a problem with my G1, running on latest Cyanogen mod. After restarting the card cannot be read and it is seems to be checking the sd card, if it really happens I dunno. What is weird is that I can access the card from recovery mode (shell), and it is not damaged (at least the windows doesn't detect damage while it is in the card reader. So that implies that the problem might be in the Android system.. anybody has a clue how to solve this? Thanks a lot.
Edit: solved it, deleted fsck_msdos from bin and it works flawlessly again
Click to expand...
Click to collapse
Simple fix, Difficult decision. Remove SD Card from slot then Factory reset phone. Once it comes too just go through all steps to setting up device then reinsert the SD Card into the slot. BOOM!
thank you very very much it worked for me
baka.yarou said:
Hi all,
I have a problem with my G1, running on latest Cyanogen mod. After restarting the card cannot be read and it is seems to be checking the sd card, if it really happens I dunno. What is weird is that I can access the card from recovery mode (shell), and it is not damaged (at least the windows doesn't detect damage while it is in the card reader. So that implies that the problem might be in the Android system.. anybody has a clue how to solve this? Thanks a lot.
Edit: solved it, deleted fsck_msdos from bin and it works flawlessly again
Click to expand...
Click to collapse
thank you so much but it is read only please help
yeah...
supremeteam256 said:
Can always wipe and reflash. Or if you have another sd card laying around and put that in to see if it recognizes it.
Click to expand...
Click to collapse
i am having same issue i always changes roms please can you halp me..
still not working mine is lenovo K3 Note And my Phone is rooted. It is showing Preparing SD card checking for errors
Didn't work for me.
Hard reset don't work.
Delete the fsck.msdos but don't work.
The fsck.msdos file comes on every wipe back.
I think this is a cm issue.
On stock no problems with my external sd card on my HTC One M8.
I'm going crazy...
No need to go to bin.. just put ur SD card in other mobile.. it will show fcsk files when u open the SD card.. just delete those files. Then remove the SD card and put it back in Ur mobile.. Then restart it mobile.. problem solved..,,,
Anitha Sivakumar said:
No need to go to bin.. just put ur SD card in other mobile.. it will show fcsk files when u open the SD card.. just delete those files. Then remove the SD card and put it back in Ur mobile.. Then restart it mobile.. problem solved..,,,
Click to expand...
Click to collapse
ive deleted the fcsk file on bin
the notif "preparing sd card" was gone but another problem occured, i cant even open my storage, ext sd card and even internal card ive tried your solution, ive put my sd card on another device, i cant find any fcsk files that you mention i cant even delete any file from my card using another mobile :crying::crying::crying:
It worked.... Thanks bro..
:good:
sajjji said:
your phone should rooted
then download and install root explorer
in the root explorer go to
system /bin
and delete fsck_msdos
now reboot your phone
Click to expand...
Click to collapse
sajjji said:
your phone should rooted
then download and install root explorer
in the root explorer go to
system /bin
and delete fsck_msdos
now reboot your phone
Click to expand...
Click to collapse
Bloody Brilliant. I have no idea why I could not find this solution two years ago. I have spent several hours searching for this solution, several times. In my case, I needed to remove the fsck.exfat file in the /system/bin folder.
My attention span is extremely short. I have been living with a 3 to 4-minute card scan for a 256GB microSD in my Samsung Note 3 for two and a half years. For all of the reboots I have done (which must be near a thousand, if that's not severely underestimated) I have had to deal with waiting to use my phone. I can't tell you how discouraging it has been to have such a powerful, useful device crippled by such a stupid flaw: that of checking the SD card that you rarely remove, for errors, every single time the phone is rebooted, even after graceful reboots called by the "proper" methods.
I can't tell you how many times I have rebooted my phone, only to forget the reason I rebooted it, because my phone took 4 minutes to reboot.
Productivity to the cubed-root.​Pisses me off.
Someone who has more voice than me please get the Android People to change this. As of Nougat, this is still the default behavior. How can an organization be so stupid...? I have no doubt that just this flaw has sent many people to the Apple camps. Who the cuff in their right mind would want to deal with such a hassle?? Are they seriously unaware of the trend for people to actually believe that their devices, machines and technology ought to be doing things faster than previous generations?
(Please just take the following cynicism with a grain of salt. I just learned the above fix, something I really should have figured out a long time ago/kicking myself!!) :crying:
For the anally-inverted who might bring up the obvious argument that your phone will no longer be able to detect or fix corruption, all that needs to be done is the following:
1) move the fsck.exfat (or whatever the formatting) file to a different folder. In my case I moved it to the /data folder
2) use some delay scripting program that will symlink the fsck.exfat file to a tmpfs location say, 30 seconds after boot; or longer if needed. This intermediary step is necessary in order to create a temporary symlink, which will be nonexistent upon reboot.. If we didn't create a temporary symlink, the fsck.exfat command would be immediately available after each reboot (which we don't want) because symlinks are normally permanent. Therefore, this step will need to be run after every reboot (but again, time-delayed).
3) the last command is to create another symlink, linking the tmpfs fsck.exfat symlink created in the last step back to the /system/bin folder (or wherever it originally resided). So this is a symlink of another symlink. This step actually should only need to be done once, since this symlink should remain after reboot, even though it is initially broken upon reboot until the previous command recreates the intermediary symlink. It should become effective again when the previous step is run by the time-delayed scripting program.
Now your phone has the ability to check the card upon you calling the fsck.exfat routine through normal means, one of which can just be a simple unmount -> mount request from the Android system settings . Your card won't be needlessly fsck-checked to death every bloody time you reboot your phone.
(If you found this tutorial helpful and desire to quote or improve upon it, please cite/credit me for the inspiration! It came through much effort and learning!)

Alternate Webtop partition

I was hoping to be able to figure all of this out on my own (so that I could impress everybody with my brilliance, of course! ), but I've hit a brick wall, so I figured I would see whether anybody had any suggestions.
The short version: I'd like to be able to create an alternate and larger /osh partition that we can run Ubuntu off of so that we can install software more freely as well as not worry about any future software updates that might conflict with the partition contents.
My thought was that it should be possible to have an alternate partition to /osh that's used to run from (whether it's mounted on /osh or not is largely irrelevant).
However, the problem I'm hitting up against is a matter of timing. The best entry point I've found to modify behaviour is /system/bin/mountosh when it's called by /init.rc, especially since it's responsible for most of the webtop setup. The catch is that by the time mountosh is called, the only partitions mounted are through p16, meaning that internal storage (p18) isn't available and the SD card (mmcblk1) isn't available either, meaning that there's no way to use either (a loopback file on the former, a partitioned SD card for the latter). I suppose it would theoretically be possible to create a loopback file on p16 (data), but that's only 2 GB and would conflict with other uses.
Does anybody know how to force internal storage and/or the SD card to be mounted earlier? Or is this going to require hacking a kernel (and bootloader and...) that we don't have the source code to yet? If I can get past this piece, then I'll be able to help other users get a webtop that would be in much better shape (especially since this would let us start using apt without having to worry so much about space issues). Thanks!
I am not sure off hand at the moment, but you might have a look at /etc/fstab and see if you can have the sdcard mounted earlier there. While having it mounted earlier may have some unexpected side effects; I presume the driver for the sd card reader is compiled into the kernel, so I don't see a reason it can't be mounted earlier.
But, not having an atrix anymore I can't test this outright.
Fenny said:
I am not sure off hand at the moment, but you might have a look at /etc/fstab and see if you can have the sdcard mounted earlier there. While having it mounted earlier may have some unexpected side effects; I presume the driver for the sd card reader is compiled into the kernel, so I don't see a reason it can't be mounted earlier.
But, not having an atrix anymore I can't test this outright.
Click to expand...
Click to collapse
/etc/fstab is pretty meaningless, unfortunately. Most of the mounting is performed within /init.rc, and I see no entries for the external storage there. As it stands, the entry for the internal storage is more in the format of "on X, do Y" rather than the more traditional procedural format, so I'm not sure how much control I can have over that.
Also, second thoughts tell me that putting a filesystem file in /mnt/sdcard would be stupid, because it would cause all kinds of issues when attempting to USB mount the partitions from a computer.
I think the best way to attack this would be to pivot to another filesystem structure on the external sdcard. I'll take a look at init.rc later today and see what can be done.
agentdr8 said:
I think the best way to attack this would be to pivot to another filesystem structure on the external sdcard. I'll take a look at init.rc later today and see what can be done.
Click to expand...
Click to collapse
So you'd think. And that's what I did. I have a nice 2 GB ext3 partition on my SD card with the contents from the /osh partition (p13) rsync'ed over. But, only the mmcblk0 partitions are available when mountosh runs (up through p16), with no mmcblk1 partitions. Naturally, /dev/block/vold is empty as well.
I might need to poke some contacts to see if it's possible to detect mmcblk1 earlier, but in the meantime, I might just create a filesystem file in /data (p16). Hell, /data is almost 2 GB large, and I'm only using a little over 500 MB in it, so there's plenty of free space there. Why did they make it so large? Do people really download that much crap to their phone?
Grr...
So, even creating a file in /data and mounting that via loopback doesn't work, even if it's mounted on top of the existing /osh partition. I'm guessing that they have some level of verification.... So yeah. Something else is missing here.
I had two sucessful ways of overcoming this. The first way was to move /usr onto /data, and to symlink it back. But, I wanted a way of not modifying /osh, so I ended up creating a init.d script to bind a copy of /osh over /osh. I don't have access to a dock or HDMI monitor at the moment, so I can't confirm if the webtop launches with either of these methods, but full functionality worked in the command line.
shawnbuck said:
I had two sucessful ways of overcoming this. The first way was to move /usr onto /data, and to symlink it back. But, I wanted a way of not modifying /osh, so I ended up creating a init.d script to bind a copy of /osh over /osh. I don't have access to a dock or HDMI monitor at the moment, so I can't confirm if the webtop launches with either of these methods, but full functionality worked in the command line.
Click to expand...
Click to collapse
Yeah, that's the thing. Everything worked on the command line, but X itself refused to start, even after I completely disabled TOMOYO (even when running /etc/init.d/startX.sh by hand).
I might decide to poke at it another time, but I'll at least wait for the SBF situation to sort itself out first.

[Q] No sdcard or sdcard-ext with Minimoto 1.7 ROM

Hello,
With the issues I was having with the CM 10.1 nightlies, much as I would like to stay, I decided to install the Minimoto 1.7 ROM into the second ROM slot (created with Safestrap 3.05). First, let me say "wow!" I never thought I would see this much speed and available RAM on my Droid 3. Thank you very much, thingonaspring.
For the most part, everything is working great *except* access to both the sdcard (internal) and sdcard-ext (external) storage areas. I read many posts in the Minimoto thread and searched around but nobody else appears to have encountered this which I find rather odd.
After the initial install and after reboots, these areas were still not accessible. I finally ran the terminal emulator and found that, for some unknown reason, they were *not* mounted. I *did* find the internal storage (/dev/block/emstorage) mounted at /ss but not at /mnt/sdcard. I became root using "su" and did the following:
# mount /dev/block/emstorage /mnt/sdcard
# mount /dev/block/mmcblk0p1 /mnt/sdcard-ext
Now I can access them along with all of the files I previously had there. The included file manager, when started, presents buttons for "Internal Storage" and "SD", but it still complains that internal storage is not mounted. It will allow me to access the SD card, though.
Under Settings->Storage Settings, everything under "Internal storage" and "SD card" says "unavailable" and both the mount and format buttons are grayed out. Yet, under the "Windows Media Sync" heading, I *can* choose between internal and SD *and* it even shows the correct available/total space values.
Why were these not mounted to begin with? Is mounting them manually an acceptable solution? If it is, where do I put this information so that it occurs at boot like it should (there is no /etc/fstab on Android)? Did I perhaps do something wrong when installing this ROM, maybe because I used ROM slot 2 instead of 1 (which still contains the most current CM 10.1 nightly)?
I really want to get this resolved because, so far, everything else appears to work wonderfully. Even 3g access, which I still haven't gotten working with CM 10.1.
--John Gruenenfelder
I've been running Minimoto for months and both /sdcard and /sdcard-ext are mounted at bootup for me, always, just like stock.
So, I wish I could tell you why, but I cannot.
I guess what I would do is start over. Reboot into Safestrap, remove that second slot and recreate it. Flash the ROM and restart the phone. Do not wipe data/factory reset after flashing the ROM or you will be missing some files (basically, some files required by the customized initial setup application.)
It seems to be fixed! See below for (perhaps) how...
Okay, I gave this a try. Rather than wiping ROM-slot-2, I had enough free space to create slot-3 and I reinstalled Minimoto 1.7 there. Also, this time I downloaded the zip file on my PC and transferred it over rather than downloading it directly onto the phone. Using the UNIX "cmp" tool told me the two files were identical, but I still used the "new" one. It installed fine and I did *not* perform a data wipe.
Unfortunately, same issue. When the device starts I can see the "Preparing XXX storage" messages appear in the notification bar for both internal and SD storage. There are no error messages, but it also did not actually do anything. Then, using the terminal emulator, I gave a long read through the dmesg output. I am more familiar with the kernel messages one sees when booting Linux on a PC, but I still did not see anything unusual.
So, back into Safestrap recovery. This time I tried something different. First, I noticed that the Safestrap file manager *can* see both storage areas and in the locations where they ought to be. This is not new, actually, it has always been the case. Second, I uplugged the USB cable. I have been using it for charging (of course), but at present it was plugged into my laptop and not into the wall charger. Depending on how the mounting occurrs and the exact mount order, I thought this might interfere. Thirrd, and finally, I used the "Fix Permissions" button available in Safestrap on ROM-slot-2 where I had first intalled Minimoto.
After doing these two changes I rebooted the device back into ROM-slot-2. Surprise! I once again saw the "Preparing" messages in the status bar except this time it really worked. The two storage locations are available where they should be and I an access the data just fine. Even the "Storage properties" screen in Settings shows both as mounted with the correct available/total space values given.
Since a plain reboot did not work previously, I have to assume one of the two changes I made fixed the problem, though, since I did both at the same time, I cannot be sure which fixed it.
Now I can get back to enjoying the impressivee speed from Minimoto while I wait to see if (or perhaps when) either the 3g or HW keyboard ALT-key issues are fixed in CM 10.1. Of course, given how much slower CM 10.1 operates (by virtue of using *much* more RAM than Minimoto), I think I might find it very difficult to switch.
--John Gruenenfelder
If you've been trying to hoot while plugged into your laptop I can see it causing issues as when usb mass storage is active, the device can no longer see the sd cards. That is why we have a separate data partition for apps and app data. So if the computer is trying to mount them and denies the phone the ability to mount then I could see issues arising
Sent from my XT860 using xda premium

Sony Xperia ZR – Mount ExternalSD2InternalSD

Hi,
This is my first android device, so am pretty much a newbie for android.
Have created this mod to mount external SD card partition as internal partition.
I took pointers from a lot of threads on xda forums to get this working, so I feel bound to share it.
Note: Have only tested it with Android 4.1.
(I'm not responsible for any Damage to your phone. Use at your own risk.)
Note: This will likely result in data loss. Backup!
Required :
1. Root Access
2. init.d support click here
3. Root Browser click here
4. SManager click here
5. An sd card (duh!) (with class 10 SD cards preferable)
6. Some way to partition your SD Card (like MiniTool Partition Manager)
Install instructions:
1. Create two ‘fat32’ partitions on SD card(EDIT: PS: both partitions should be Primary). Your first partition will be mounted as normal extSd card, and your second partition will be mounted as internal SD Card for your apps. (I partitioned my 64GB(10^9 bytes) sd card with ~16 GB 1st partition and ~42 GB 2nd partition)
2. Copy and paste “mountSd” to etc/init.d folder. (If you don’t have such a folder, means you lack init.d support. click here and follow instructions to enable it) This script creates another mount point called ‘sdcard2’ and mounts current internal sd card there. It also tries to mount second partition to ‘sdcard0’ location, but seems to fail some times (as fat32 is not natively supported linux partition it seems, but could be wrong), so step 3 is required.
3. Copy ‘mountSdFailSafe.txt’ to your phone’s ‘/data’ folder. Now with ‘SManager’, register this file as script with ‘su’ and ‘boot’ selected. (click and hold script -> in context menu click ‘Open As..’ -> ‘Script/Executable’ -> Is Script = true, select ‘su’ and ‘boot’ buttons)
4. Restart.
This should do it. Once restarted, second partition will be shown as internal memory.
Note:
You will lose all app data and other app related customizations. You may be able to restore it by simply copy pasting ‘Android’ folder from ‘/storage/sdcard2’ to ‘/storage/sdcard0’. This has not been tested by me but should work theoretically (as I started with a blank phone, and so did not need to back up my app data). Or you could use Titanium Backup.
Some Issues that occur due to this mod:
I have been using this mod since the past 2 weeks, and the phone is quite stable with this mod.
The only issue I have faced is that when connected to PC (Windows 8) through USB, ‘My Computer’ keeps crashing unless and until you disconnect the phone. Otherwise it seems to be working fine. To circumvent this issue I have been using Samba to share files between PC and my phone.
Please share how it works out for you guys.
Other Notes:
I tried to get this working with ext4 partition, which has a +ves that it will not require step ‘3’ of install instructions and supports file sizes >4GB, but there are loads of permission issues happening, which I could not solve.
(Thought of setting “set GID” bit and then finding and adding all users to root group but failed. Also tried to set owner group ‘sdcard_rw’ without much success. May be someone who knows linux better may know how to solve this, Could not find much help on the forums as it seems others are facing a similar problem see more)
Thanks to:
For basic idea (PS: do not use the given method exactly as you will end up in a boot loop. For some reason, ‘sdcard1’ mount point has to be mounted by system only and can’t be mounted any other way, it seems.)
http://forum.xda-developers.com/showthread.php?t=2180733
Edit:
Simplified installation if you do not care for easy accessibility to your orig internal memory:
Use this video tutorial by ashwin123:
The only exceptions are that, you need to partition your card,
and you have to use the file 'mountSdFailSafe.txt' instead of the file in the package mentioned by him.
Nice
Waiting for someone to test it n confirm it successfully works
Still here
N!geR -> E!ch0
NisJ said:
Hi,
This is my first android device, so am pretty much a newbie for android.
Have created this mod to mount external SD card partition as internal partition.
I took pointers from a lot of threads on xda forums to get this working, so I feel bound to share it.
Note: Have only tested it with Android 4.1.
(I'm not responsible for any Damage to your phone. Use at your own risk.)
Note: This will likely result in data loss. Backup!
Required :
1. Root Access
2. init.d support click here
3. Root Browser click here
4. SManager click here
5. An sd card (duh!) (with class 10 SD cards preferable)
6. Some way to partition your SD Card (like MiniTool Partition Manager)
Install instructions:
1. Create two ‘fat32’ partitions on SD card. Your first partition will be mounted as normal extSd card, and your second partition will be mounted as internal SD Card for your apps. (I partitioned my 64GB(10^9 bytes) sd card with ~16 GB 1st partition and ~42 GB 2nd partition)
2. Copy and paste “mountSd” to etc/init.d folder. (If you don’t have such a folder, means you lack init.d support. click here and follow instructions to enable it) This script creates another mount point called ‘sdcard2’ and mounts current internal sd card there. It also tries to mount second partition to ‘sdcard0’ location, but seems to fail some times (as fat32 is not natively supported linux partition it seems, but could be wrong), so step 3 is required.
3. Copy ‘mountSdFailSafe.txt’ to your phone’s ‘/data’ folder. Now with ‘SManager’, register this file as script with ‘su’ and ‘boot’ selected. (click and hold script -> in context menu click ‘Open As..’ -> ‘Script/Executable’ -> Is Script = true, select ‘su’ and ‘boot’ buttons)
4. Restart.
This should do it. Once restarted, second partition will be shown as internal memory.
Note:
You will lose all app data and other app related customizations. You may be able to restore it by simply copy pasting ‘Android’ folder from ‘/storage/sdcard2’ to ‘/storage/sdcard0’. This has not been tested by me but should work theoretically (as I started with a blank phone, and so did not need to back up my app data). Or you could use Titanium Backup.
Some Issues that occur due to this mod:
I have been using this mod since the past 2 weeks, and the phone is quite stable with this mod.
The only issue I have faced is that when connected to PC (Windows 8) through USB, ‘My Computer’ keeps crashing unless and until you disconnect the phone. Otherwise it seems to be working fine. To circumvent this issue I have been using Samba to share files between PC and my phone.
Please share how it works out for you guys.
Other Notes:
I tried to get this working with ext4 partition, which has a +ves that it will not require step ‘3’ of install instructions and supports file sizes >4GB, but there are loads of permission issues happening, which I could not solve.
(Thought of setting “set GID” bit and then finding and adding all users to root group but failed. Also tried to set owner group ‘sdcard_rw’ without much success. May be someone who knows linux better may know how to solve this, Could not find much help on the forums as it seems others are facing a similar problem see more)
Thanks to:
For basic idea (PS: do not use the given method exactly as you will end up in a boot loop. For some reason, ‘sdcard1’ mount point has to be mounted by system only and can’t be mounted any other way, it seems.)
http://forum.xda-developers.com/showthread.php?t=2180733
Click to expand...
Click to collapse
Am interested to try this but before I do, just wanted to check when you say data is lost, is it due to the lost of the original /data partition? Or just due to the sd card's partition?
What's the outcome when this is done, I mean do we have two data partitions one from the original phone's memory and another with the sdcard? And in the settings menu, will we get to choose to send apps over to sd? Thanks
grim_ripper said:
Am interested to try this but before I do, just wanted to check when you say data is lost, is it due to the lost of the original /data partition? Or just due to the sd card's partition?
What's the outcome when this is done, I mean do we have two data partitions one from the original phone's memory and another with the sdcard? And in the settings menu, will we get to choose to send apps over to sd? Thanks
Click to expand...
Click to collapse
Your application data will be lost in a way, as orig internal sd card will be mounted to 'sdcard2' mount point(newly created). All your app data will be installed to your memory card's second partition, which is now the new internal sdcard. To access your orig data, you will have to go to it through a file manager, and apps or media scanner will not be able to access this memory any more.
The scripts provided will not format your internal memory.
Still apk files, dalvik cache etc, will still take up your original internal memory's space.
Partitioning your sd card will probably format it as well unless you take special precaution (ie. through shrink volume).
Hope it makes sense...?
NisJ said:
Your application data will be lost in a way, as orig internal sd card will be mounted to 'sdcard2' mount point(newly created). All your app data will be installed to your memory card's second partition, which is now the new internal sdcard. To access your orig data, you will have to go to it through a file manager, and apps or media scanner will not be able to access this memory any more.
The scripts provided will not format your internal memory.
Still apk files, dalvik cache etc, will still take up your original internal memory's space.
Partitioning your sd card will probably format it as well unless you take special precaution (ie. through shrink volume).
Hope it makes sense...?
Click to expand...
Click to collapse
It makes sense, just am confused on how the system will still recognize the original storage when the sd card's storage is supposingly replacing it. Could you post a screen shot of your storage from settings?
grim_ripper said:
It makes sense, just am confused on how the system will still recognize the original storage when the sd card's storage is supposingly replacing it. Could you post a screen shot of your storage from settings?
Click to expand...
Click to collapse
Here you go....
PS: third image shows that internal storage is still accessible, just not to apps. Only apk files, and other android files go there go there. sdcard2 in 4th image is newly created mount point for your orig internal storage, but is ignored by most of the apps...
NisJ said:
Here you go....
PS: third image shows that internal storage is still accessible, just not to apps. Only apk files, and other android files go there go there. sdcard2 in 4th image is newly created mount point for your orig internal storage, but is ignored by most of the apps...
Click to expand...
Click to collapse
Can u do a tutorial video how to install this script bro?
Cuz the installation steps r bit complicated
Still here
N!geR -> E!ch0
NisJ said:
Here you go....
PS: third image shows that internal storage is still accessible, just not to apps. Only apk files, and other android files go there go there. sdcard2 in 4th image is newly created mount point for your orig internal storage, but is ignored by most of the apps...
Click to expand...
Click to collapse
Phone keeps rebooting now, couldn't copy it to /etc/init.d
I think it has something to do with having data running in the background, now I don't know what to do with my phone
EDIT: Ok, manage to recover from the reboot state, had to deny root access to my file explorer. I think the reboot was caused when I set permission to write for /system. Anyway, everytime I keep trying to copy to /etc/init.d, I get a permission denied so am not sure what I should do now.
grim_ripper said:
Phone keeps rebooting now, couldn't copy it to /etc/init.d
I think it has something to do with having data running in the background, now I don't know what to do with my phone
EDIT: Ok, manage to recover from the reboot state, had to deny root access to my file explorer. I think the reboot was caused when I set permission to write for /system. Anyway, everytime I keep trying to copy to /etc/init.d, I get a permission denied so am not sure what I should do now.
Click to expand...
Click to collapse
When ever you copy something to init.d it will reboot, or does it go into boot loop?
To check if it worked correctly, see if new mount point storage/sdcard2 was created..
EDIT: If it worked correctly, then you could move to next step.
else you could also skip it, and goto the next step of SManager, but in that case you will lose access to your original internal storage as it wont be mounted to sdcard2.
E!ch0 said:
Can u do a tutorial video how to install this script bro?
Cuz the installation steps r bit complicated
Still here
N!geR -> E!ch0
Click to expand...
Click to collapse
Creating a video will take time at least til sat... prob more.
Will see if I can create a simplified install instructions once i reach home.
NisJ said:
When ever you copy something to init.d it will reboot, or does it go into boot loop?
To check if it worked correctly, see if new mount point storage/sdcard2 was created..
EDIT: If it worked correctly, then you could move to next step.
else you could also skip it, and goto the next step of SManager, but in that case you will lose access to your original internal storage as it wont be mounted to sdcard2.
Click to expand...
Click to collapse
What happens is that everytime I try to mount /system as writable, it reboots and hence I can't copy either files to their designated location
EDIT: Also, now everytime I reboot, there's a popup that says USB connectivity has stopped, and if I go under settings->storage, settings fc. I'm thinking this has something to do with two partitions on the sd card so I hope it all goes away when this works or I revert back to as it was.
EDIT 2: So I managed to get all the files to the appropriate place using terminal and managed to get the script to run at boot. Alas, the phone doesn't detect my sdcard at all now and still throws the USB connectivity error at boot. Once I removed the sdcard, everything works alright. Also, I figured the solution to the reboot (haven't tested it yet as I wanted to resolve my sdcard first):
http://forum.xda-developers.com/showthread.php?t=2317432
EDIT 3: Got the reboot solve, but the sdcard can't be read and I tried plugging it into my other phone, the first partition is only read. I can't get minitool to even find the 2nd partition. I am thinking I need to get a card reader to plug it into my laptop. Anyway, I went through your script and open the log file it used, says that there's an invalid argument for mount. Any idea?
Final Edit: Got it working! I had to re-partition my sdcard and made both partitions primary so maybe you might want to add that in OP as MiniTool by default selected the 2nd partition as logical
grim_ripper said:
What happens is that everytime I try to mount /system as writable, it reboots and hence I can't copy either files to their designated location
EDIT: Also, now everytime I reboot, there's a popup that says USB connectivity has stopped, and if I go under settings->storage, settings fc. I'm thinking this has something to do with two partitions on the sd card so I hope it all goes away when this works or I revert back to as it was.
EDIT 2: So I managed to get all the files to the appropriate place using terminal and managed to get the script to run at boot. Alas, the phone doesn't detect my sdcard at all now and still throws the USB connectivity error at boot. Once I removed the sdcard, everything works alright. Also, I figured the solution to the reboot (haven't tested it yet as I wanted to resolve my sdcard first):
http://forum.xda-developers.com/showthread.php?t=2317432
EDIT 3: Got the reboot solve, but the sdcard can't be read and I tried plugging it into my other phone, the first partition is only read. I can't get minitool to even find the 2nd partition. I am thinking I need to get a card reader to plug it into my laptop. Anyway, I went through your script and open the log file it used, says that there's an invalid argument for mount. Any idea?
Click to expand...
Click to collapse
Why are you trying to mount /system as rw?
for getting init.d support you just have to download the apk from mentioned thread and install it, and then fallow instruction in app.
you can mount root as rw with the foll command if you want, and that is exactly what is done in he scripts as well if you will check:
Code:
mount -o remount,rw /
also to check if partition is created on sd card, type the command:
Code:
blkid
and see if
Code:
/dev/block/vold/179:34
is listed
if not post the output and i'll see what i can do.
grim_ripper said:
Final Edit: Got it working! I had to re-partition my sdcard and made both partitions primary so maybe you might want to add that in OP as MiniTool by default selected the 2nd partition as logical
Click to expand...
Click to collapse
EDIT: Correct, you need both the partitions to be primary. got out of my mind when posting the tutorial.
NisJ said:
Why are you trying to mount /system as rw?
for getting init.d support you just have to download the apk from mentioned thread and install it, and then fallow instruction in app.
you can mount root as rw with the foll command if you want, and that is exactly what is done in he scripts as well if you will check:
Code:
mount -o remount,rw /
also to check if partition is created on sd card, type the command:
Code:
blkid
and see if
Code:
/dev/block/vold/179:34
is listed
if not post the output and i'll see what i can do.
EDIT: Correct, you need both the partitions to be primary. got out of my mind when posting the tutorial.
Click to expand...
Click to collapse
For whatever reason, my /etc folder is actually a link from /system/etc
Could you post a way to revert back? I think my apps are acting all funny now and just want to revert back to before. Thanks!
grim_ripper said:
Could you post a way to revert back? I think my apps are acting all funny now and just want to revert back to before. Thanks!
Click to expand...
Click to collapse
The apps are behaving funny because you have lost their data as I had warned in the original post.
To fix do either of the foll:
1. reinstall app, and start fresh.
or
2. restore from Titanium backup if you had created...
or
3. copy paste 'Android' folder from sdcard2 if it is created to 'sdcard0'
To remove and revert, just delete the files from int.d, and stop scheduling it in SManger.
Note: to un schedule it from smanager, you first have to remove memory card, un schedule and then put in your memory card (this is coz when phone boots up, it is in standard way, with 8gb internal but, after script is executed SManager looses its data too.
How complicated will it be to make this compatible with 4.2.2?
grim_ripper said:
How complicated will it be to make this compatible with 4.2.2?
Click to expand...
Click to collapse
Ideally should be possible, unless something has changed majorly, but I haven't tried it, as am waiting for OTA update. If it is not forth coming in 2-3 weeks, may be tempted to flash nordic rom and try.
NisJ said:
Ideally should be possible, unless something has changed majorly, but I haven't tried it, as am waiting for OTA update. If it is not forth coming in 2-3 weeks, may be tempted to flash nordic rom and try.
Click to expand...
Click to collapse
I did try but nothing happened, am guessing it has permission issues or something on those lines
grim_ripper said:
I did try but nothing happened, am guessing it has permission issues or something on those lines
Click to expand...
Click to collapse
Could you be more specific? Like system restarts etc...
Else in terminal try out what I Gave in post no 12 and give me what the output is for both the commands in the terminal.
Note: execute them with super user credentials.
Thanks
NisJ said:
Could you be more specific? Like system restarts etc...
Else in terminal try out what I Gave in post no 12 and give me what the output is for both the commands in the terminal.
Note: execute them with super user credentials.
Thanks
Click to expand...
Click to collapse
on the 4.2.2 update, it doesnt recognize the second partition even if it is formatted to primary and set to active. there r definitely some updates done in that field and plus i cant get the init.d rights on the phone as the test.log file is absent in the data folder..no matter what i do i just cant get it straight with the present procedure. please try it on 4.2 and there r more frequent updates on the nordiac then the local version. so i decided to flash it rather than waiting for ota update

Categories

Resources