SDCard and SDCard-ext wrong location - General Questions and Answers

I just installed a new ROM and the SDCARD and SDCard-ext are in the wrong location. They are listed under the root director ( / ) and /storage instead of under /mnt/sdcard

Does it work? You could create a symlink. If that fixed it, put it in a script on bootup.

post-mortem said:
Does it work? You could create a symlink. If that fixed it, put it in a script on bootup.
Click to expand...
Click to collapse
Does it work is a relative question. (wasn't meant to sound wise-a$$). I can access them, but apps do not see them at all. They are looking for the cards in /mnt therefor not finding them.
I changed them in /system/etc/vold.fstab but now it won't boot. The not booting is not an issue, I can fix that, but I don't know how to fix these incorrect paths/

No one else who's using this ROM is having these problems? I say either reflash, create symlinks, or choose another ROM.

post-mortem said:
No one else who's using this ROM is having these problems? I say either reflash, create symlinks, or choose another ROM.
Click to expand...
Click to collapse
Not sure if anyone else is running it. Haven't been able to find a thread on here for it. How do you do symlinks?

mikemikemikexxx said:
Not sure if anyone else is running it. Haven't been able to find a thread on here for it. How do you do symlinks?
Click to expand...
Click to collapse
ln -s target shortcut
See a bit more here.
Make a script in your /system/etc/init.d directory, so these links will be created on every boot.

post-mortem said:
ln -s target shortcut
See a bit more here.
Make a script in your /system/etc/init.d directory, so these links will be created on every boot.
Click to expand...
Click to collapse
From what I have read you cannot use them on FAT.
Why does editing this file not work? I fail to see how Android could do anything other than read the file, provided permissions are the same.

mikemikemikexxx said:
From what I have read you cannot use them on FAT.
Why does editing this file not work? I fail to see how Android could do anything other than read the file, provided permissions are the same.
Click to expand...
Click to collapse
The internal memory is not FAT; typically, only the 1st partition on the SD card is FAT, everything else should be EXT. So, executing ln -s /storage /sd-ext should work (or wherever it's currently being mounted).

post-mortem said:
The internal memory is not FAT; typically, only the 1st partition on the SD card is FAT, everything else should be EXT. So, executing ln -s /storage /sd-ext should work (or wherever it's currently being mounted).
Click to expand...
Click to collapse
I meant the card but ln is not working.
One more thing I am going to try is an ADB pull and push. If that doesn't work I really need some community support.

bump to the front.

Are my questions that complex or that dumb that I get so few replays? /bump
Sent from my XT875 using xda app-developers app

Is there a good reason that you don't want to use another ROM?

Mainly speed and compatibility. I need the offline commands only available in JB. Stock ROM is dead slow and is only ICS. Other custom ROMs were also on the slow side and/or battery hogs.
Sent from my XT875 using xda app-developers app

So, is this right?
FAT partition is currently being mounted as /storage
EXT partition is currently being mounted as /mnt/sdcard

post-mortem said:
So, is this right?
FAT partition is currently being mounted as /storage
EXT partition is currently being mounted as /mnt/sdcard
Click to expand...
Click to collapse
Well the way my phone is laid out is
System (I assume too large so they split it in two which resulted in the below SD-Card)
SD-Card
SD-Card EXT (The actual SD Card) - FAT32
I assume the System and SD-Card are standard Android partition format.

Do you use a file manager on the phone, such as ES File Explorer? Are you familiar with using adb?
Edit: Basically, I'm trying to figure out the exact path of the mounted partitions, and where they're supposed to be mounted.

post-mortem said:
Do you use a file manager on the phone, such as ES File Explorer? Are you familiar with using adb?
Edit: Basically, I'm trying to figure out the exact path of the mounted partitions, and where they're supposed to be mounted.
Click to expand...
Click to collapse
They are 100% supposed to be mounted under: /mnt/sdcard and /mnt/sdcard-ext
Right now they are mounting to: /storage/sdcard and /storage/sdcard-ext
There is also an entry in under root ( /sdcard and /sdcard-ext --- For these two I am booting into stock ROM to see if they are suppose to be directly in root as well, will post up when I know)

Check the scripts in your init.d to see if one of them is mounting the sd partitions under /storage.
I suppose you could also try booting without the sd card in place, and see if those /storage directories still exist. Not sure how much that will tell you, though.

post-mortem said:
Check the scripts in your init.d to see if one of them is mounting the sd partitions under /storage.
I suppose you could also try booting without the sd card in place, and see if those /storage directories still exist. Not sure how much that will tell you, though.
Click to expand...
Click to collapse
The init.d for sure says to load sdcards to /storage . (on this particular ROM only)
I will try without the sdcard as you suggested and let you know. Battery died on me, phone won't boot even when plugged in until at least 10%.

Which script is mounting the sd card to /storage? Is it part of the ROM, or is it something which the dev included in this ROM? I ask in case the ROM expects the sd card to be mounted there.
Regardless, try changing the script to link to /sdcard.

Related

New and improved Apps to SD(more stable, more powerful, etc) Tutorial

Well, some of you may have heard my ramblings around here that I've been working with some of the devs here(JF and MartinFick deserve major praise, probably more than me) on getting a better way to do the whole apps to sd thing.
After 3 days of talking/discussing/working on it, I've finally reached the fruits of that investigation and thought I'd share. This new method uses the filesystem unionfs to essentially meld the /data directory with the /system/sd directory, so that they appear to be one. This has the potential to allow users to move specific apps to or from the sd card, is far more stable than the normal symlink method(will still boot, etc even if there's no SD card) and should be easier to set up. Now, onto the tutorial of setting this up.
BIG DISCLAIMER NOTE: This is a major hack of the phone and it is fully possible that it will break your phone(I've seen no permanently bricked phones but that doesn't make it impossible). Use this method, and my app along with it at your own risk.
REQUIREMENTS:
1: This only works on JF(possibly only on 1.5, not sure about the others) and The Dude's v.1.0 or greater. The Dude's 1.0 or greater actually does the steps in this tutorial for you so you can just run appstosd2 and set it all up from there if you're using his ROM.
2: This still requires you to have 2 partitions set up, first FAT32 and second ext2. Although you can use the appstosd2 app attached to this post and available in the market for $0.99 which will partition the card for you.
3: If you want your apps to go to the sd card, you must have a directory "/system/sd/app" If you didn't have apps to sd before on the ext2 partition do the following in terminal emulator or run my appstosd2 app after finishing the tutorial:
Code:
su
mkdir /system/sd/app
If you want the private-apps, or dalvik-cache moved you can replace "app" in that code with ""app-private", or "dalvik-cache" respectively. Do not copy "data" to the sd card. My script will delete it on the next reboot.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
Alright, first there's some files you need.
1: init.rc in .zip attached to this thread
2: a2sd.sh in .zip attached to this thread
All the above listed files should be put on your sd card(my tutorial will assume they are in the root directory of the sdcard(the topmost folder)
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
If you need to undo the normal apps to SD first do the following in the recovery terminal(it's not strictly necessary but I'd recommend it):
Code:
mount data
rm /data/app
mkdir /data/app
if you moved the dalvik cache, repeat steps 2-3 with "dalvik-cache" instead of app. Ditto with "data" for the data cache.
-----------------------------------------------------------------------------------------------------------------------------------------------------------------
Then go to terminal emulator and type the following:
Code:
su
cp /sdcard/init.rc /data/
cp /sdcard/a2sd.sh /data/
Then reboot and you're set. By default all future apps are installed to the sd card. In order to move an app to the internal memory do the following in terminal emulator:
Code:
su
cp /system/sd/app/[the app you want to move] /system/intmem/app/
rm /system/sd/app/[the app you want to move]
I will be incorporating this into my appstosd app soon(probably as a JF and TheDude-only version until the rest of the devs get on board).
I have included a copy of appstosd 2, which will copy all apps from internal memory to the sd card with an option to remove them from the internal memory. This will only work if you have followed this tutorial.
If you don't have partitions set up, appstosd2 will now do that for you with user-set partition sizes.
NOTE: If you're using The Dude's ROM and find yourself with an outdated version of this since he doesn't always update his ROMs at the same time I update this, do the following in terminal emulator to update(after putting a2sd.sh from the attached a2sd.zip on your sdcard):
Code:
su
mount -o remount,rw -t yaffs2 /dev/block/mtdblock3 /system
rm /system/bin/a2sd.sh
cp /sdcard/a2sd.sh /system/bin/
reboot
For JF1.5, do the following to update:
Code:
su
rm /system/intmem/a2sd.sh
rm /system/intmem/init.rc
cp /sdcard/a2sd.sh /system/intmem/
cp /sdcard/init.rc /system/intmem/
reboot
NOTE FOR UPDATERS: If you had your data on the sdcard(/system/sd/data), it WILL GET DELETED with the new version. This is a necessity in order to get both wallpaper and protected apps working. I recommend moving it back to the phone.
EDIT: And here's another tutorial from ThatsBS(might be easier for the less tech savvy to follow?):
I am still learning a lot everyday from this forum. So for people new to this process let me noobify it, if I can, as I am one too.
Start by reading the first page!! Get all the stuff you need from page 1. (apps2sd2.zip and a2sd.zip )
I started from a fresh wipe and flash of jf1.51 adp.
A newly formatted fat32, non partitioned sd.
Put the init.rc and app2sd.sh on the sd (the files NOT the zip)
Then go to the terminal emulator and typed:
su
cp /sdcard/init.rc /data/
cp /sdcard/a2sd.sh /data/
Then reboot
Next I ran the apps2sd 2 app. It will ask you how much to you want to partition. I did 3000mb the first successful time and the dreaded low mem notice would not leave the status bar. I have read not to make it more then 1500mb. Have a good connection, dont force close it. It will reboot.
Next, after the reboot, I ran the apps2sd 2 app again and pressed "copy apps to sd" (let it do its thing)
Reboot.
Next I went back to the emulator and typed:
su
mkdir /system/sd/app-private
mkdir /system/sd/dalvik-cache
Reboot.
Go back to the apps2sd 2 app and hit move dalvik-cache.
Reboot for good measure and your done.
I did this in about 10 mins. Worked flawlessly.
I have a ?, if i have been using your app what dod i do diferent or what should i change?
Thanks
Good job, thanks!
[email protected] said:
will still boot, etc even if there's no sim card
Click to expand...
Click to collapse
You mean SD card?
[email protected] said:
Alright, first there's some files you need.
1: unionfs.ko from here:
Click to expand...
Click to collapse
JF1.5 build has already unionfs.ko in it, doesn't it? Is there any difference between this unionfs.ko and the one included?
1. I hear unionfs is not really stable at this point, is it true?
2. Why do you want to move the whole /data folder to sd, instead of just /data/app, /data/app-private?
3. You might want to add a command to remove previous app2sd changes (i.e. delete symlinks, create folders.)
4. How do you put selected apps to internal memory after this? Copying to /data will copy to sd card again.
The whole idea is really interesting! Thank you for your work!
ArmandHammer said:
I have a ?, if i have been using your app what dod i do diferent or what should i change?
Thanks
Click to expand...
Click to collapse
You don't have to do anything different. It will find all the apps you put on the sd card. If you want to set the phone back to normal(so the phone memory apps can still be there), you can do the following in the recovery terminal:
Code:
mount data
rm /data/app
rm /data/dalvik-cache (only if you moved the dalvik-cache)
mkdir /data/app
mkdir /data/dalvik-cache
@Dimath: yes, I did mean SD card, good catch
1:JF didn't mention it and from a little bit of using it, it seems stable to me. Plus, no matter how much I've screwed up, I haven't managed to boot loop my phone yet.
2: You could just mount those independently. I might end up doing that eventually but for now the way it is works for reasons I'll get to.
3: True, although it's not strictly necessary. If apps2sd already works, this won't break it. I'll put in a guide on undoing the symlink method
4: Actually, no. My script sets the internal memory as the main file system in the union, so apps automatically go there. Moving apps to the sd card just involves copying them to /system/sd.
Ok, just a little confusing.
I didn't use the apps2sd to move apps over to my SD card. What I did was set it with the busybox ls command. I guess that's the symlink.
My question is, if I didn't use apps2sd, can I still use your method? I also moved the dalvik cache also, everything works fine for me now, my apps go directly to the SD card when installing since my memory stays at around 65 MB no matter what I do.
Just need some laymen terms to help me understand that if I'm NOT using apps2sd, and I just linked them with the recovery method, what's my pitfalls / advantages?
Thanks.
larrygates said:
Ok, just a little confusing.
I didn't use the apps2sd to move apps over to my SD card. What I did was set it with the busybox ls command. I guess that's the symlink.
My question is, if I didn't use apps2sd, can I still use your method? I also moved the dalvik cache also, everything works fine for me now, my apps go directly to the SD card when installing since my memory stays at around 65 MB no matter what I do.
Just need some laymen terms to help me understand that if I'm NOT using apps2sd, and I just linked them with the recovery method, what's my pitfalls / advantages?
Thanks.
Click to expand...
Click to collapse
Yes, any other method of apps to sd currently uses the same symlink method, so following the directions as if you installed my app will work. A note though is that all future apps will install to the internal memory by default. I did that because it's MUCH easier to move apps from the memory to the sd card than vice versa. You can use the code I posted if you want it the other way around.
would this also work for /data/data and app-private?
or is this particular setup only for dalvik-cache and app?
oh and before I do this, just wondering, so in theory, since I have a 1.5GB ext2 partition, my free memory will be 1.573GB (1.5GB + 73Mb internal)? The internal memory will just run down and switch over to the sdcard when needed (but be seen as one filesystem)?
andonnguyen said:
would this also work for /data/data and app-private?
or is this particular setup only for dalvik-cache and app?
Click to expand...
Click to collapse
This works for the whole /data folder and everything under it. Everything is automatically installed to the phone memory right now so you can just move over anything you don't want on it(will be making an app to do this automatically)
EDIT: oh and anything you already moved over to the sd card will still show up.
Code:
su
mount -o remount,rw /dev/block/mtdblock3 /system
cp /sdcard/unionfs.ko /system/
cp /sdcard/init.rc /data/
cp /runme.sh /data/
cp /sdcard/a2sd.sh /data/
I see, when I run these lines of code (I can do this from adb also right using adb remount) this IS the new symlink method. It's just all at one time without me having to manually link anything.
Right?
larrygates said:
Code:
su
mount -o remount,rw /dev/block/mtdblock3 /system
cp /sdcard/unionfs.ko /system/
cp /sdcard/init.rc /data/
cp /runme.sh /data/
cp /sdcard/a2sd.sh /data/
I see, when I run these lines of code (I can do this from adb also right using adb remount) this IS the new symlink method. It's just all at one time without me having to manually link anything.
Right?
Click to expand...
Click to collapse
Wrong, no symlinks here. Pure unionfs goodness. Basically it convinces the operating system that /data and /system/sd are the same thing. So anything that's on /system/sd shows up under /data but everything that's normally under /data is still there. Think of it like what happens in windows when you merge folders with the same name, but in this case in actuality everything stays exactly where it was.
New news: If you haven't seen it, I updated this tutorial(and the scripts with it) quite a bit and would now consider it to be completely fully functional.
Also The Dude will be sending me an advance copy of his next ROM tomorrow to verify it works. In his build the apps to sd will be automatic, with no user setup(although if you want apps on the sd card you'll have to make an app directory under /system/sd(mkdir /system/sd/app), ditto for dalvik-cache and data).
Finally, I will attempt to add this into my apps to sd app tonight, thus rounding out everything I can do.
After all this, the only thing left is for Haykuro to build it into his ROM and me to make an app to move specific apps to/from the sd card automatically.
This will no doubt be the method of choice in no time. Great work. Sticky?
If anyone dl'd the latest version(that fixed the race condition, etc), please download the one I just put up. I made that one in windows and I believe the funky carraige return(that indicates a new line) that windows uses screwed it up
So I got some kind of error, and I don't know what is going on.
I put in all the lines in the terminal emulator app..
but after line cp /runme.sh /data/ it gives me an error
it says "cp: cannot stat '/runme.sh': No such file or directory
Any help? I rooted my phone just so I could run my apps off of my SD card.. and now I can't figure out how to get it to work. Somebody help me please.
GTASouthPark said:
So I got some kind of error, and I don't know what is going on.
I put in all the lines in the terminal emulator app..
but after line cp /runme.sh /data/ it gives me an error
it says "cp: cannot stat '/runme.sh': No such file or directory
Any help? I rooted my phone just so I could run my apps off of my SD card.. and now I can't figure out how to get it to work. Somebody help me please.
Click to expand...
Click to collapse
Which ROM is this? JF1.5 should have runme.sh there...
[email protected] said:
Which ROM is this? JF1.5 should have runme.sh there...
Click to expand...
Click to collapse
Ok, I am going to re-partition my memory card.. and then re flash to JF1.5 and try it again.
Just tried it, one issue I'm seeing is android seems to install [email protected]@[email protected] into /system/intmem/dalvik-cache at boot. Is there anyway to have that only in my dalvik-cache on the sdcard?
Its a fairly large file at 3megs so I want it to reside solely on the sdcard and even if I delete it from intmem, whenever I reboot it gets added again.
Now when I display the internal phone storage from the settings menu, it shows up at 835 megs.
I wonder if this is possible to use unionfs and make an ext2 fs object as a file on the FAT fs. That way no 2nd partition is necessary. Plus, if you remove the sdcard, everything will still work.
Maybe we could combine unionfs and this method that uses an ext2 image on the fat32 for apps to sd.
http://forum.xda-developers.com/showpost.php?p=3402947&postcount=687
mkefs can be downloaded here:
http://sites.google.com/site/juanjosec/android
dwang said:
I wonder if this is possible to use unionfs and make an ext2 fs object as a file on the FAT fs. That way no 2nd partition is necessary. Plus, if you remove the sdcard, everything will still work.
Maybe we could combine unionfs and this method that uses an ext2 image on the fat32 for apps to sd.
http://forum.xda-developers.com/showpost.php?p=3402947&postcount=687
mkefs can be downloaded here:
http://sites.google.com/site/juanjosec/android
Click to expand...
Click to collapse
I've been looking at that possibility with JF and MartinFick as well, seems like it could be a good plan but I wanted to get this bit done first. It's a good point about the dalvik-cache, but in order to fix it JF(in this case) would have to change /init.rc to make sure to do this bit before building the dalvik-cache.
Can't download apps from market
hmm so I didn't hit any errors when doing this, but afterwards I am unable to download any apps from the market. It just continually says "Starting Download..." Everything else seems to work well.
I had this same issue when I tried to manually setup apps to sd using the symbolic links. I narrowed the issue down and figured out this only occurred after I moved the dalvik-cache over to the sd card. I'm assuming I'm doing something wrong, but can't seem to figure it out. Any pointers in a general direction would be most helpful
I'm using JFv1.50 ADP1.5, not the modded version by LucidREM. For some reason the bootloader couldn't pickup his version on my phone and --edit-- I'm pretty sure I have the SD card partitioned correctly... everything else seemed to work ok. The ext2 partition shows up as the correct size
*EDIT* So apparently my issue was the SD card as well. Just did a format of the sd card and it fixed it. I also formatted data and cache (alt+w in recovery mode). Thanks MarcusMaximus!
[email protected] said:
New news: If you haven't seen it, I updated this tutorial(and the scripts with it) quite a bit and would now consider it to be completely fully functional.
Also The Dude will be sending me an advance copy of his next ROM tomorrow to verify it works. In his build the apps to sd will be automatic, with no user setup(although if you want apps on the sd card you'll have to make an app directory under /system/sd(mkdir /system/sd/app), ditto for dalvik-cache and data).
Finally, I will attempt to add this into my apps to sd app tonight, thus rounding out everything I can do.
After all this, the only thing left is for Haykuro to build it into his ROM and me to make an app to move specific apps to/from the sd card automatically.
Click to expand...
Click to collapse
If I have apps2SD and the dalvik-cache both moved on the dudes builds already, do I still have to create those directories or will my existing setup still work fine? I would like to know what kind of issues I may run into when the dude releases .95 with this (hopefully, not getting my hopes up just in case).

Change mount point for SDCARD

I have seen this mentioned but no solution. (It's been causing mild headaches for lots of things from storing camera pics to flashing ROMs)
Is there a way to get the Transformer to use the SDCARD as the actual default storage point?
It's a severe pain that everything defaults to the internal storage that it thinks is external then I have to move everything to the external SDCARD after that.
It would be a moot point but I have a 32GB SDCARD that sits empty while my internal storage fills up. I store a lot of music and movie files for editorial, etc and the Transformer is great for that. . .except for the dumb mount points of the sdcard.
You could make a soft link in /sdcard/ that points to /Removable/MicroSD/ but your sdcard has to be formatted NTFS to support it. I would assume the mount points for removable media are located in /etc/fstab
This drives me a tad crazy as well. That and the naming convention. Should be under /media/ or /mnt/ but "/Removable/MicroSD/" is a ginormous pain when you're using to unix/linux media mounting conventions or navigating under the shells
Oh well.
Sent from my Transformer TF101 using XDA Premium App
This was done for other devices such as the Notion Ink Adam so I know it's possible.
sent from a device using an app
uncorq said:
This drives me a tad crazy as well. That and the naming convention. Should be under /media/ or /mnt/ but "/Removable/MicroSD/" is a ginormous pain when you're using to unix/linux media mounting conventions or navigating under the shells
Oh well.
Sent from my Transformer TF101 using XDA Premium App
Click to expand...
Click to collapse
I'll agree with that, but its something I can over look. I'm assuming you would has to change this line in /etc/vold.fstab
Code:
dev_mount microsd /Removable/MicroSD auto /devices/platform/sdhci-tegra.2/mmc_host/mmc1
just have to get the docks sdcard to mount into the devices internal memory "sdcard" in the same manner the microsd does, should be fairly easy to do, just have to poke around a bit to see how microsd is being mounted
I try link 2 sd and data root 2 sd on the market, but the apps would not recognize the microsd. So there no way of linking to the sd by apps.
Sent from my Transformer TF101 using Tapatalk
I try link 2 sd and data root 2 sd on the market, but the apps would not recognize the microsd. So there no way of linking to the sd by apps.
Click to expand...
Click to collapse
Exactly. I would consider this a fairly obvious flaw to Asus that they change the accepted behavior being used everywhere else. Overall happy with the device but this is causing a headache since it's the only android device I have that operates this way it's not something I can just "get used to" as the odd man out. Why include external storage (a major reason for this over the Galaxy Tab 10.1 for me) and then make it a pain to use?
I'm assuming you would has to change this line in /etc/vold.fstab
Click to expand...
Click to collapse
Will see if that helps but wondering if this would cause a conflict elsewhere.
I'm making this too complicated in my head.
Simply: The internal and external mount points should be swapped.
Anything I want on the internal storage I can move, but that's fewer and further between than the sdcard. Maybe some music or whatnot.
This would solve other problems like ROM managements, etc.
one more thing... if it's just photos you are wanting to move, you could
"ln -s /sdcard/DCIM /Removable/SD/DCIM"
all new photos taken will end up on SD I might have that backwards? type ln in terminal with no arguments, and it will tell you what you need
do this for any folders you want on SD, then androids core stuff that apps need, and you don't need elsewhere still stays internal
I get "operation not permitted" for some reason. I have root permissions. Sudo, etc.
bitter1 said:
I get "operation not permitted" for some reason. I have root permissions. Sudo, etc.
Click to expand...
Click to collapse
FAT32 doesn't support symlinks.
Try this instead.
Regards,
Dave
Oh yeah, duh. Will give the other a shot.
I have to stick to FAT32 because I occasionally have to use OSX to shuffle things around.
dan-htc-touch said:
one more thing... if it's just photos you are wanting to move, you could "ln -s /sdcard/DCIM /Removable/SD/DCIM"
Click to expand...
Click to collapse
You also need to be root or prefix that with sudo
foxmeister said:
FAT32 doesn't support symlinks.
Try this instead.
Regards,
Dave
Click to expand...
Click to collapse
cd /mnt/sdcard
mkdir fssd
mount -o bind /Removable/SD /mnt/sdcard/fssd
yeap that works.. Thanks..
If your running Prime (Or something that supports init.d scripts), you could add that command to one of the files in /system/etc/init.d/ to make it automatically run at boot
Tortel1210 said:
If your running Prime (Or something that supports init.d scripts), you could add that command to one of the files in /system/etc/init.d/ to make it automatically run at boot
Click to expand...
Click to collapse
I just did that to 07 and no joy
After reboot no effect. I'll play some more later.
which command did you add? you only need to add the last one.
brando56894 said:
which command did you add? you only need to add the last one.
Click to expand...
Click to collapse
sure. only that one.
maybe the MicroSD (yeah changed it) is not mounted yet when the script runs?! or does the script run at all?!
off to bed now. tomorrow is another hot day.
I think you need to prefix it with /system/xbin. Heres the command I used in my init scripts:
Code:
/system/xbin/mount -o bind /Removable/MicroSD/DCIM/ /sdcard/DCIM/
That code will make pictures save on the micro sd card instead of internal memory.
Also, make sure the folder in the internal memory where you want it to bind to the external storage is empty.

[Q] 3.2 and the MicroSD Card Read-Only

So apparently I have to use my computer or root explorer to write to my SD card since the 3.2 update. Does anyone know how this might be fixed to allow general file managers or applications to take advantage of?
same here....
f'ing moto fail here....this is NOT sd support to me
i have been using file manager HD and it will copy files to & from the sd card and delete from the sd card. it just wont "move" to the sd card.
EDIT- was using root explorer...not the other one.
Did you do anything special since upgrading to #Version three point two? I use the same program and it won't move, copy, or delete.
jase33 said:
i have been using file manager HD and it will copy files to & from the sd card and delete from the sd card. it just wont "move" to the sd card.
Click to expand...
Click to collapse
I can copy from the SD card but not paste to using the same software...this mean its read only
To be clear, I updated using update.zip and now running tiamat kernel, but I'm sure it was read only before I flashed the new kernel
I updated to 3.2 with ota and manually rooted. using stock kernel. write to sd works fine. maybe the method you updated from or the kernel you use is causing an issue.
sdcard
heh i find it amusing:
Real SDCard = /mnt/external1
Same ole crap SDCard = /mnt/sdcard, /sdcard, /data/media, and i bet more if i care to look harder.
jase33 said:
I updated to 3.2 with ota and manually rooted. using stock kernel. write to sd works fine. maybe the method you updated from or the kernel you use is causing an issue.
Click to expand...
Click to collapse
Are u talking about the Sdcard folder or the external1 folder?
I updated via update.zip method
Edit: Attached screenshot of my external1 permission
jase33 said:
i have been using file manager HD and it will copy files to & from the sd card and delete from the sd card. it just wont "move" to the sd card.
Click to expand...
Click to collapse
Moving from one source to another isn't possible. It's a linux/android thing. So that's nothing to worry about.
Remount /mnt/external1 as read/write
Here's what I've done to make /mnt/external1 read/write accessible:
adb shell or any other terminal emulator to get to a shell on the xoom
su to get to the # prompt
umount /mnt/external1
mount -t vfat -o fmask=0000,dmask=0000,rw /dev/block/platform/sdhci-tegra.2/mmcblk0p1 /mnt/external1
That remounts the sdcard without using vold, which is enforcing a mask on the perms.
Now to get this to happen at boot...
Stealyourface said:
Moving from one source to another isn't possible. It's a linux/android thing. So that's nothing to worry about.
Click to expand...
Click to collapse
Yeah I know.....I was just responding simply
Sent from my HD2
Stealyourface said:
Moving from one source to another isn't possible. It's a linux/android thing. So that's nothing to worry about.
Click to expand...
Click to collapse
I move files all the time in Linux, via both command line and file manager. I don't know where you are getting this "Linux/Android can't move files" from.
Given up and revert back to Tiamat 1.1
I reflashed stock and upgraded to 3.1 then 3.2 only to learn that the SD card was not writable within the xoom. I have full confidence that one of the devs will release a mod for 3.2 to get us all the features that we are accustomed to. Until then I've flashed back to Tiamat 1.1.
ekarelis said:
Here's what I've done to make /mnt/external1 read/write accessible:
adb shell or any other terminal emulator to get to a shell on the xoom
su to get to the # prompt
umount /mnt/external1
mount -t vfat -o fmask=0000,dmask=0000,rw /dev/block/platform/sdhci-tegra.2/mmcblk0p1 /mnt/external1
That remounts the sdcard without using vold, which is enforcing a mask on the perms.
Now to get this to happen at boot...
Click to expand...
Click to collapse
This is exactly right. It appears vold is now placing special perms above standard media_rw perms. So, apps without this level of permission can not write to external storage. We will address this in the upcoming Tiamat Rom release.
looking forward to 3.2 cusrom rom
Thanks brd. Very much looking forward to the tiamat 3.2 based rom.
mambomta said:
I move files all the time in Linux, via both command line and file manager. I don't know where you are getting this "Linux/Android can't move files" from.
Click to expand...
Click to collapse
Move a file from your xoom (if you even have one) from internal storage to external. It either won't let you, or it'll get corrupted in the process.
Stealyourface said:
Move a file from your xoom (if you even have one) from internal storage to external. It either won't let you, or it'll get corrupted in the process.
Click to expand...
Click to collapse
My Xoom should arrive tomorrow. If the Xoom is not allowing a move, it is a bug, not a limitation in Linux.

Make MicroSD part of internal storage

Is there a way I can make the MicroSD just an extension of the internal storage? It would be nice to store apps on it as well. Is this possible?
Apps2SD lets you put apps on, and ICS lets you use it pretty much the same way as the internal. So no need really.
If you really wanted to it would involve symlinking partitions, but I'm not entirely sure as to the process
Oh that's great because I remember honeycomb didn't allow that. When an app is on sd will its files reside on sd? For example DoggCatcher stores its files on internal and I would really like to have those files on my MicroSD. Would a symbolic link work to do this?
Edit: tried app2sd but it couldn't find SD card because of how TF names internal as SD.
Trying out Link2SD because it seems promising. I think it creates symbolic links.
Not symbolic links
Symlinking, the ls command, think of it as a linux-shortcut command perse.
I find that Titanium backup works very well, but it needs root.
How do you do it in Titanium? I can't figure out how. Thanks for the help so far
Edit: Also if for example Doggcatcher's files are on internal and it won't let me specify where I want to store them how would I move them to MicroSD?
Really sorry, I was getting TI backup mixed with something else.. X.x
https://play.google.com/store/apps/...wOSwiY29tLndvbmd4bWluZy5hbmRyb2lkLmFwcDJzZCJd
Try this--
and this with root-- https://play.google.com/store/apps/details?id=com.leinardi.setinstalllocation&feature=also_installed (works well, my ROM has built in support for this though, most big apps (games) can be moved with the native ics feature. hunt through settings.
Thanks for the help! Is the TF internal filesystem Fat32 by default?
Thing O Doom said:
Not symbolic links
Symlinking, the ls command, think of it as a linux-shortcut command perse.
I find that Titanium backup works very well, but it needs root.
Click to expand...
Click to collapse
No offense intended, but I'm not sure I understand what you are saying. Symlink is just a short name for a symbolic link, as far as I could find (from Wikipedia):
In computing, a symbolic link (also symlink or soft link) is a special type of file that contains a reference to another file or directory in the form of an absolute or relative path and that affects pathname resolution.
Click to expand...
Click to collapse
And the "ls" command (without any other parameters) just lists the files in the current directory in Linux and Unix type OSs.
---------- Post added at 12:52 AM ---------- Previous post was at 12:50 AM ----------
taC nayN said:
Thanks for the help! Is the TF internal filesystem Fat32 by default?
Click to expand...
Click to collapse
The internal is ext4, I believe, a Linux filesystem type.
I'm trying this to create soft link so I can have DoggCatcher files on MicroSD instead of Internal but when I tried
ln -sf /removable/MicroSD/DoggCatcher /sdcard/Doggcatcher
it says No such file or directory. What am I doing wrong? My MicroSD is exFAT.
Sorry, I'm getting so mixed up today. *blarg* Thank you for pointing that out. Id even know what I was thinking. -sleep time-
myandroiid.blogspot.com/p/how-to-use-your-sdcard-as-internal.html
HERE IS COMPLETE GUIDE ITS AWESOME
Sent from my HTC Salsa C510e using xda premium
taC nayN said:
I'm trying this to create soft link so I can have DoggCatcher files on MicroSD instead of Internal but when I tried
ln -sf /removable/MicroSD/DoggCatcher /sdcard/Doggcatcher
it says No such file or directory. What am I doing wrong? My MicroSD is exFAT.
Click to expand...
Click to collapse
If it is the same as mine, then it should be "ln -sf /Removable/MicroSD/DoggCatcher /sdcard/DoggCatcher". Note the capital R in removable. Now, if DoggCatcher is a directory name then you may need to add a "/" at the end of one or both of your target and source. Not sure if the 'f' option works with busybox, you may need just 'ln -s'. Also, the normal command structure is " ln -s(f) source-file link-name ". Make sure you have the parts in the intended order.
Allright I got everything *mostly* figured out now. I don't necessarily want to make MicroSD primary because they are the same size so I just want to extend it. I figured out how to move DoggCatcher via the app (I'm an idiot)
I still would like to know how to create soft links between SD and internal though because it keeps failing.
sidneyk said:
If it is the same as mine, then it should be "ln -sf /Removable/MicroSD/DoggCatcher /sdcard/DoggCatcher". Note the capital R in removable. Now, if DoggCatcher is a directory name then you may need to add a "/" at the end of one or both of your target and source. Not sure if the 'f' option works with busybox, you may need just 'ln -s'. Also, the normal command structure is " ln -s(f) source-file link-name ". Make sure you have the parts in the intended order.
Click to expand...
Click to collapse
Thank you so much! That was the problem. Greatly appreciated.

[Q] Has anyone found an App to SD solution?

I've looked through the big development thread and haven't found a clear answer but has anyone found an app to sd solution that works?
This stupid SdCard / ExtSdCard arrangement is making me pull my hair out. I just realized my titanium backups weren't really backups since they were being stored on my internal memory.
I managed to change my backup folder and free up some space by moving all my backups to the SD card, but for some reason I cannot move apps to SD through Titanium or any other app I've tried.
Does anyone know how to do this? Is there a setting in titanium I need to change or is this just something we have to deal with forever short of flashing a custom rom?
SDCARD binary
Galahad_Knight said:
I've looked through the big development thread and haven't found a clear answer but has anyone found an app to sd solution that works?
This stupid SdCard / ExtSdCard arrangement is making me pull my hair out. I just realized my titanium backups weren't really backups since they were being stored on my internal memory.
I managed to change my backup folder and free up some space by moving all my backups to the SD card, but for some reason I cannot move apps to SD through Titanium or any other app I've tried.
Does anyone know how to do this? Is there a setting in titanium I need to change or is this just something we have to deal with forever short of flashing a custom rom?
Click to expand...
Click to collapse
I've found the real problem, but not the solution.
My Relay runs ICS. It is rooted, and you have to root to even touch any of this. The phone has a binary, /system/bin/sdcard that controls the internal memory and your SDcard. now, I have found that if you are rooted, you can chmod this binary (or use rooted ES File explorer to remove all executable properties) so that it can no longer run, then reboot. then you can run, as superuser "mount -o rw,bind /mnt/extSdCard /mnt/sdcard"
Seems great... Except vfat doesn't like to be bound in such a fashion, and you quickly lose write access and it starts mangling your files.
vfat just doesn't seem to work for us in this case. I've changed mine back, and reformatted my SDcard to be NTFS and mounted with paragon NTFS/HFS, which has completely stabilized my filesystem. only problem is, I can't get this to mount -o bind worth a damn.
I'm toying with the idea of reformatting my SDCard part vfat and either part NTFS or EXT4. maybe I get get the phone to natively recognize ext4 for the sdcard (even if I have to create a script myself)
keypoints I've found in this process:
1. the sdcard binary only allows access to 1023 files at once on either the SDcard, or the memory block it is using as the SDcard. too many pictures in your gallery? so sorry... can't load them all.
2. the physical device for your sdcard is /dev/block/mmcblk1. the partitions are mmcblk1p* (starting with 1)
3. the phone will not allow the sdcard binary to be killed manually. removing the executable permission and then rebooting the phone seems to be the only way to get it to stop.
4. vfat is prone to errors, and android seems to love screwing with the card. getting off vfat seems to be crucial to this process.
As you've gotten no other replies, and this is a gigantic concern for me as well, I'm going to keep working on this myself, in the hopes that I can get the phone to actually use the SDcard the way we hope it can be used.

Categories

Resources