dbzfanatic · Mar 23, 2011 at 03:00 am

How-To: Mount the /Cache Partition as a Fake SD Card

This won’t be useful to most users but to those of us who have a SD card that is either no longer recognized by the phone for some reason or just plain doesn’t work anymore, this will help.

I’m going to show you how to mount your phone’s /cache partition as your /sdcard partition, allowing the use of apps and widgets that require an SD card to work properly. A basic knowledge of ADB and Linux commands will be helpful but not entirely necessary, you should be able to just copy and paste the commands. This could be adapted to mount any writable partition as the SD card partition, such as using /data instead of /cache, which should allow a bit more information because of partition restrictions.

Things you will need:

* ADB;
* (optional) Terminal Emulator installed on your device.

I’ll try to explain the steps as best as I can while keeping the commands readable.

1: Boot into the main Android OS /*this is fairly obvious;
2: Plug your phone into your computer /*again obvious;
3: Open a command prompt/bash/terminal window /*we will by typing the commands here;

4: Type “adb devices” without quotes /*start the adb server if it isn’t and list attached devices;
4A: Linux only: type “sudo adb devices” instead and enter your root password /*start adb as root and list devices;

5: If your device is listed type “adb remount” without quotes, if it isn’t make sure you have usb debugging enabled and try again /*mount the main system as read/write;

6: (optional) type “adb shell” without quotes. if you prefer type all following commands in Terminal Emulator /*start the shell session for linux commands;

7: type “su” without quotes. You should get a #. If this is your first time using TE you will get a dialog asking you to allow su permissions for TE. Click “always allow” or “remember” and “yes” /*get su permissions for shell;

8: type “umount /sdcard” without quotes /*unmount the sdcard, just for good measure;

9: type “mount -o rw,remount /” without quotes /*mount the root filesystem system as read/write;

10: type “umount /sdcard” without quotes /*again,for good measure;

11: type “ln -s cache /sdcard” without quotes /*create a symlink to the /cache partition. now when apps look for /sdcard their data is saved in /cache;
12: Run the app or widget that requires SD card access. It should now work.

This will be undone with a reboot but it should allow you to at least get things working properly. Since this uses the /cache partition it uses the phone’s internal memory, which is very limited so be careful with what you download. This is a temporary fix until a replacement SD card can be obtained. You will still get that annoying notification that you don’t have an SD card inserted but apps and widgets should work just fine with it.

I have noticed that ROM Manager will not work with this method, nor will the camera, but an app called “Weather and Toggle Widgets” will allow you to do an initial setup and continue working even after a reboot. I have obviously not tested each and every app for compatibility but with minor tweaking this could come in handy for much more.


_________
Want something on the XDA Portal? Send us a tip!
TAGS:

dbzfanatic

dbzfanatic is an editor on XDA-Developers, the largest community for Android users.
Mathew Brack · Mar 26, 2015 at 06:07 pm · 2 comments

HTC M9 Roundup: Availability and Prices

The HTC One M9, Available in both 'Gold on Silver' and 'Metal Gray' colors will be available for sale in stores across the US on April 10th, however most carriers are starting preorders tomorrow on March 27th. No matter which network you order yours from you will be covered by HTC's new Uh-Oh service. Throughout the day today we have seen just as many announcements from carriers regarding pre-order information and prices for Samsung's new flagships the Galaxy S6 and S6 Edge. If...

XDA NEWS
Mario Tomás Serrafero · Mar 26, 2015 at 05:15 pm · 1 comment

OnePlus Late March AMAA Roundup

OnePlus is one of those companies that appear one day and next thing you know, they are all over the internet. Their original OnePlus One phone was a major success in the mobile space due to its low price yet remarkable specifications - the ultimate goal of the company and their “Never Settle” slogan. We love talking about “the little OEM that could”, not necessarily because they are good or bad, but because their business and marketing strategies are very...

XDA NEWS
Chris Gilliam · Mar 26, 2015 at 04:12 pm · 1 comment

Galaxy S6 Pricing & Availability Roundup

The Samsung Galaxy S6 and S6 Edge will be available for sale across the big four US carriers on April 10th, but most pre-orders start tomorrow, March 27th. Which network is the right choice for your new phone? That's a question whose answer received a new wrinkle today as announcements about pricing and bundled perks landed from all angles. Here's the rundown of Samsung offerings as we know them, but it's worth mentioning that HTC's newsroom was just as busy rattling off...

XDA NEWS
Share This