[HOW-TO] Recover Internal Memory lost after XXUFME3 - Galaxy S III General

Hello,
So after I flashed XXUFME3 I noticed that non of my files on my internal memory are showing any more.
When checking the storage, I can see that there was 5 GB worth of files un-accounted for, IE they still exist they just don't show any more.
After further digging up, here is what I have found:
The mount point for internal memory is no longer /sdcard/ it is now /sdcard/0/ and to my knowledge, I couldn't find a way to actually see /sdcard/ since it was not mounted to begin with.
Here is what I did to circumvate this:
1 - I rebooted to CWM recovery
2 - From there, I went to mounts & storage and mounted /data, /sdcard and /external_sd
3 - I opened an adb shell and from there browsing to /sdcard/ showed me all my precious files again.
From here on out, the solution was simple.
You can either:
Move all contents from /sdcard/ to /sdcard/0/ this can be done by running the following:
Code:
mv -r !(0) /sdcard/0/
OR
Copy all of your contents to your external SD by running the following:
Code:
cp -r !(0) /external_sd/
Both the above commands will exclude the directory "0" and all of its contents since you do not need to move them.
Hope this helps anyone who had the same problem.

Or you can go to /storage/emulated/0/0 folder and find all your old files in there.

bcostea said:
Or you can go to /storage/emulated/0/0 folder and find all your old files in there.
Click to expand...
Click to collapse
I looked and they weren't showing there. I had a similar issue when I moved to AOKP and I was able to restore them as you said, however this time they simply weren't there.

The mount point is actually /data/media normally but here it's /data/media/0 so you can just copy everything from /data/media to /data/media/0 with a root explorer (i use es)
/sdcard and /storage/emulated essentially just redirect you to be media folder.
Sent from my GT-I9300 using Tapatalk 2

delsus said:
The mount point is actually /data/media normally but here it's /data/media/0 so you can just copy everything from /data/media to /data/media/0 with a root explorer (i use es)
Sent from my GT-I9300 using Tapatalk 2
Click to expand...
Click to collapse
Yeah that's definitely an easier solution never found it while browsing though ! Thanks

I wrote a thread on this. Link in my signature
Sent from my GT-I9300 using Tapatalk 2

rootSU said:
I wrote a thread on this. Link in my signature
Sent from my GT-I9300 using Tapatalk 2
Click to expand...
Click to collapse
sir how can i restore my nandroid backup 4.1.2 from this 4.2.2? is it possible. it says md5 sum mismatch thanks in advance

The thread title is wrong. The files are not "lost".
Also, anyone who's used 4.2.2 before knows the deal here.

Kryten2k35 said:
The thread title is wrong. The files are not "lost".
Also, anyone who's used 4.2.2 before knows the deal here.
Click to expand...
Click to collapse
So are these duplicate files or just in a different place? I did a full wipe and flashed 4.2.2, then put all my stuff back from the backup on my computer. Does this effect me?

s14sh3r said:
So are these duplicate files or just in a different place? I did a full wipe and flashed 4.2.2, then put all my stuff back from the backup on my computer. Does this effect me?
Click to expand...
Click to collapse
Different location. Full explanation in the thread I wrote in my signature
Sent from my GT-I9300 using Tapatalk 2

Turns out it is because of multi user support... If you create another user profile, all the files from that user will get saved to /sdcard/1. Only way out is to move all files from /sdcard to /sdcard/0.
Sent from my GT-I9300 using xda app-developers app

Related

internal memory

So has anyone been able to figure out how to use the internal memory for movies/music/pictures
I've been able to add items to the internal memory via an update.zip installed through Clockwork.
-----
Sent from my Droid X. Powered by Big Red, customized by NATF.
NotATreoFan said:
I've been able to add items to the internal memory via an update.zip installed through Clockwork.
-----
Sent from my Droid X. Powered by Big Red, customized by NATF.
Click to expand...
Click to collapse
I don't think you understood my question. but how would I install my music/movies/pics through an update file, and be able to see it in music player and gallery.
titos1997 said:
I don't think you understood my question. but how would I install my music/movies/pics through an update file, and be able to see it in music player and gallery.
Click to expand...
Click to collapse
I understood your question. I create an update.zip containing the folder structure that Android recognizes, and then I script them to install to internal memory. After rebooting, my ROM is untouched and I have the files in the internal memory.
Can you not just use root explorer to move the media files to a place on internal memory.?
Sent from my DROIDX using XDA App
monkespit said:
Can you not just use root explorer to move the media files to a place on internal memory.?
Sent from my DROIDX using XDA App
Click to expand...
Click to collapse
You can put them there with root explorer, but the only place I know of that you can put files on the internal memory is /data. If you place them anywhere else they will disappear after a reboot. I have movies on mine (with root explorer)but in order for the app (rockplayer) to see them I have to remount and chmod the /data directory. I have a very simple script in gscript to do this with as the permissions reset themselves after reboot. Here is the command:
mount -o rw,remount -t yaffs2/dev/block/mtdblock3 /data chmod 777 /data
The whole thing is a pain and the stock apps don't see the internal memory so you have to use rockplayer or vplayer to use the files. The update.zip is probably a better solution, but I would have no idea how to go about that.

p-3113 Swap ExternalSDCard 2 Internal

Here's a script I modified originally its a script written by mattiadj so I gotta give him props
Here's his thread its for the Galaxy S III I think - http://forum.xda-developers.com/showthread.php?t=1772234
This will make your external SDcard as Internal and your Internal SDCard external
It mounts data/media to your extSdcard
Please make a backup before you do this, just in case.
Let me know if you have any problems
1. Anyway.. you will need to place this script in your /data folder (Yes you need to be rooted)
2. Next use ES file manager and give it 777 permission (For the non-linux users, that's full permission on it, Read, write, execute for just user)
-----------------to do this with ES file manager just press and hold down on the file and look at its properties. At the bottom you can see Permissions, hit the Change button and check-mark everything for user
3. Use Smamager (Download it if you dont have it, ... .its free) and goto the script file and open as script/execute, then when it opens choose "Is executable" and then click "Su" & "Boot". Click "Save".
4. Reboot and enjoy.
To go back to the normal setup just delete the script or open it back up in smanager and clear the SU & Boot options.
In order for some apps to function properly you will have to copy some folders from your old internal sdcard to your "New" one.
For example.. aptoide wouldnt work until the aptoide repos folder was copied over. If you want you can just copy over everything to be safe. I on the other hand just picked and chose what I needed
xalien8dx said:
2. Next use ES file manager and give it 777 permission (For the non-linux users, that's full permission on it, Read, write, execute for everyone)
-----------------to do this with ES file manager just press and hold down on the file and look at its properties. At the bottom you can see Permissions, hit the Change button and check-mark everything
Click to expand...
Click to collapse
IMO, this is terrible advice. The script is probably getting run as root, and you're opening it up to be written by anyone. Imagine if malware edited the script? Think of what malware could do if it had root access...
Sent from my Galaxy Tab 2
imnuts said:
IMO, this is terrible advice. The script is probably getting run as root, and you're opening it up to be written by anyone. Imagine if malware edited the script? Think of what malware could do if it had root access...
Sent from my Galaxy Tab 2
Click to expand...
Click to collapse
Changed it to just user read, write, execute..
thanks
So, after this what happens to the internal SdCard. Does it, or is it still being used, and if so for what...?
^ same ? and has anyone tested this and is it safe?
All this is is a modded script from mattiadj. It was written for the GS3, so I changed it to work on the 3113 tablet
Here is what it does quoted from mattiadj
My aim was to use the external sd as internal sd and the original internal sd ONLY for apps installation.
So now my 64gb external sd is used for all tasks which the internal sd was used and the original internal sd is only used for apps storage!! All extra files (resources, caches, etc etc) are stored in my external SD, which is now mounted as internal
Click to expand...
Click to collapse
The original internal sdcard is mounted by default from the system as /data/media as well as /sdcard and mnt/sdcard
so with this script it puts data/media as extSDCard and /sdcard and /mnt/sdcard are mounted to the original external SDcard
you can still access the internal SDcard from data/media or /extSDCard or mnt/extSDcard
my code
Code:
sleep 5
mount -o remount,rw /
mount -t vfat -o umask=0000 /dev/block/vold/179:25 /mnt/sdcard
sleep 5
mount -o bind /data/media /mnt/extSdCard
this can be easily modified to work on other systems.
Hope this helps,
N8
Tried this out last night. For me it works only if run manually... After reboot, I get long "checking SD for errors" and when it actually mounts SD it gets mounted twice- as both internal sdcard and extSdCard.
Sent from my GT-P3100 using Tapatalk 2
I ran this with SCript Manager (Play Store) and it works great on my p3113. My External SD card was mounted as internal and my Internal Memory was mounted as ExternalSDcard. I am going to love having this script!
If your having problems with it mounting as your internal and external try unmounting/remounting your external card in settings under storage. Or if your skilled enough try changing the second sleep value in the script to a higher number like 10 that should fix it
Works famously. For the apps that have issues just clear data under settings and it seems to be golden.
Sent from my GT-P3113 using xda app-developers app
I haven't done anything quite like this before but I have a use in mind. My GPS program, Sygic, puts the mapset on the internal sd card. Just the Western USA states are 500 mb If I get this running, and have Sygic do it's normal install, will the mapset to to the 32 GB MicroSD card that I have?
king200 said:
I haven't done anything quite like this before but I have a use in mind. My GPS program, Sygic, puts the mapset on the internal sd card. Just the Western USA states are 500 mb If I get this running, and have Sygic do it's normal install, will the mapset to to the 32 GB MicroSD card that I have?
Click to expand...
Click to collapse
It should. For example, I use Amazon MP3 and when I downloaded a song before they went to the internal card. Now they are stored on the external. The device reads your external as though it is the internal.
Sent from my GT-P3113 using xda app-developers app
so is there Anyway on how to force this to start on boot?
Sent from my GT-P3113 using xda app-developers app
kdog48 said:
so is there Anyway on how to force this to start on boot?
Sent from my GT-P3113 using xda app-developers app
Click to expand...
Click to collapse
Yes
in script manager choose su and boot. If you follow the first post it will execute on boot. Or if you have a rom with init.d support place this script in your /etc/init.d folder, I dont have a rom with init.d support so I dont know if that would work but it should. If someone could test this and let me know I would appreciate it. Im not sure if you still have to set permissions to execute on it.
Well I've had problems downloading certain apps to SD it says insufficient memory delete 0mb of data so I actually will just manually use it haha
Sent from my GT-P3113 using xda app-developers app
Working 100% using a 32GB memory card! thanks for this!
hi guys
is applicable to 2 10.1 GalaxyTab P5100?
requires Android 4.1.1 or 4.0.4. ?
Thank you.
If this works, I will name my next born child after you!
Anyway, I would like to know if this will work on Cyangenmod 9.0.0? Or will it only work on the stock rom. I have my old stock rom of 4.0.4 saved if I need to go back... because I will if this works.
does root explorer have the 'su boot' option? never used it to run scripts...:silly:
I already used the thank link... but stilll thank you so, so much! I just recently got my 8gb 3113... needless to say, I REALLY needed some space. If any, it was a good lesson for me to definitely choose the 16GB Nexus 4.
MadDogE134 said:
does root explorer have the 'su boot' option? never used it to run scripts...:silly:
Click to expand...
Click to collapse
It's from SManager.

Storage

Using SD maid if found where the heck all my storage was going. Under /storage/emulated the folders /legacy and /0 are exactly the same with all the same stuff in it. Is there 2 of everything in my internal SD? Can I delete one of these folders? I attached a screenshot
Sent from my Nexus 4 using xda app-developers app
For giggles I deleted one. The folder was still there but empty and the other folder is also empty. I'm thinking they are the same just shown twice with different names. Not actually duplicate.
Sent from my Nexus 4 using xda premium
Hmm okay damn. Trying to figure out where this space is going because all I really have is a couple things in the downloads folder and thats it. Another screenshot of my storage in settings kinda further backs my idea
Sent from my Nexus 4 using xda app-developers app
Have you done any nandroid backups?
Sent from my Nexus 4 using xda premium
jpeterson066 said:
Using SD maid if found where the heck all my storage was going. Under /storage/emulated the folders /legacy and /0 are exactly the same with all the same stuff in it. Is there 2 of everything in my internal SD? Can I delete one of these folders? I attached a screenshot
Sent from my Nexus 4 using xda app-developers app
Click to expand...
Click to collapse
They are not duplicate files... The files are only stored in one location, but each folder has a "link" to them...
Sorta like your computer and creating "shortcuts"
That's all well and good, but...
UberSlackr said:
They are not duplicate files... The files are only stored in one location, but each folder has a "link" to them...
Click to expand...
Click to collapse
...even Android's storage manager can't get it right:
Phone:
mako 16GB
rev_11
MAKOZ10o
M9615A-CEFWMAZM-2.0.1700.48
Secure Boot - enabled
Lock State - unlocked
Rooted with (an otherwise) stock ROM (4.2.2 OTA) and Clockwork Mod Touch 6.0.2.3.
I have found four places seeming to be my SD storage:
/sdcard
/storage/sdcard0
/storage/emulated/0
/storage/emulated/legacy
I've attached other screenshots showing how File Expert HD and DiskView treat my storage. CWM 6.0.2.3 also "misinterprets" my storage situation so I can't make more than 2 backups, and if I have 2 then I struggle for space for downloads and apps. I really wouldn't care about this if apps understood it - it makes you wonder how it managed to get released when not only do no apps support it, but Android's own system gets confused!
I've seen posts talk about merging all SD data with /data/media/0 but on my phone (using both File Expert and the new File Expert HD) that's showing up as a file not a folder. Seriously, how do I sort this out? Which is the real folder, why are the other three there, how do I disable this silly "shortcut" thing that's destroying my phone's storage?
Did you guys make any nandroid backup on the SD cards?
andyli1985 said:
Did you guys make any nandroid backup on the SD cards?
Click to expand...
Click to collapse
Yeah, what originally alerted me to the space issue was when I went to make my second nandroid since installing the 4.2.2 OTA. I made one before and one after the update, then went to make a third in order to have a recent backup before trying to flash the Ubuntu Touch Dev preview but the nandroid failed due to insufficient storage space.
Ultrabenosaurus said:
Yeah, what originally alerted me to the space issue was when I went to make my second nandroid since installing the 4.2.2 OTA. I made one before and one after the update, then went to make a third in order to have a recent backup before trying to flash the Ubuntu Touch Dev preview but the nandroid failed due to insufficient storage space.
Click to expand...
Click to collapse
This should explain the "missing" storage. Since you made two nandroid backups and you have quite a lot of apps installed (2.89GB), this will take at least 6 GB of space.
Edit: Nandroid backups don't show on the android storage view.
andyli1985 said:
This should explain the "missing" storage. Since you made two nandroid backups and you have quite a lot of apps installed (2.89GB), this will take at least 6 GB of space.
Click to expand...
Click to collapse
At the time of taking the screenshots in my first post, I only have one nandroid in order to keep a decent amount of free space. The fact that CWM is also misinterpreting the storage makes me think it's backing up all 4 locations, which means that my nandroid is stupidly big. That coupled with all apps mistaking the 3 mirror locations as actual files results in a huge loss of potential storage space as apps think the device is full when it really isn't.
I should probably also mention that Windows reports the same free/used space numbers as File Expert HD.
All your internal data lies within /data/media/
The contents within that is usually what is visible to the user on a TW ROM. Once you switch to an AOSP ROM a second partition is created in /storage/emulated/0. This is your actual internal memory. Any previous downloads or backups made before installing an AOSP ROM will be located in /data/media/ since that was it's original directory. You can still view the "0" folder in /data/media/ but all your downloads, backups, etc, will be directed to /storage/emulated/0/ by default.
Sent from my Nexus 4 using xda premium
LuigiBull23 said:
All your internal data lies within /data/media/
The contents within that is usually what is visible to the user on a TW ROM. Once you switch to an AOSP ROM a second partition is created in /storage/emulated/0. This is your actual internal memory. Any previous downloads or backups made before installing an AOSP ROM will be located in /data/media/ since that was it's original directory. You can still view the "0" folder in /data/media/ but all your downloads, backups, etc, will be directed to /storage/emulated/0/ by default.
Sent from my Nexus 4 using xda premium
Click to expand...
Click to collapse
I don't understand what you mean by a "TW ROM" but I haven't changed ROM. I unlocked the bootloader and rooted, but other than a few quick plays with Ubuntu Touch I'm still using the stock ROM (which I return to from Ubuntu via restoring a CWM nandroid). I haven't flashed any Android ROMs at all.
I didn't have the phone long before I got the 4.2.2 OTA update and I didn't check the folder structure before then, but I didn't notice any suspiciously fast drops in free space until after said update.
Ultrabenosaurus said:
At the time of taking the screenshots in my first post, I only have one nandroid in order to keep a decent amount of free space. The fact that CWM is also misinterpreting the storage makes me think it's backing up all 4 locations, which means that my nandroid is stupidly big. That coupled with all apps mistaking the 3 mirror locations as actual files results in a huge loss of potential storage space as apps think the device is full when it really isn't.
I should probably also mention that Windows reports the same free/used space numbers as File Expert HD.
Click to expand...
Click to collapse
Can you use a file explorer with root access and check how big is this folder? /data/media/clockworkmod/backup
File Expert and File Expert HD both see it as a file... What app should I use?
Sent from my Nexus 4 using xda app-developers app
Install ES File Explorer, then follow the instructions on this post
Going to have to count up the folder size manually, will do it later and report back because I need to get ready for work now.
Sent from my Nexus 4
you know that the "Real" folders are in "mnt/shell/emulated"?^^
There you also see the clockworkmod folder and check it's size.

Swap Internal SD with External SD?

If anyone wants to take a crack at it, here's the script that worked on the Galaxy S3 mini. I've tried switching around the addresses in /dev/block/vold with no success.
Might not be hard. I don't have a GS4 though.
Go to /system/etc in your favorite file explorer and open vold.fstab as text and post the contents in Pastebin and link here.
ChronoReverse said:
Might not be hard. I don't have a GS4 though.
Go to /system/etc in your favorite file explorer and open vold.fstab as text and post the contents in Pastebin and link here.
Click to expand...
Click to collapse
I'll do better than that. Here's my vold.fstab file.
OP,
what path to put in directory bind? cant wait to try games I used to play on NOTE 2 using data INT2EXT script.
blackknightavalon said:
I'll do better than that. Here's my vold.fstab file.
Click to expand...
Click to collapse
Hmm, it's different from previous devices like the Note 2 and GS3. No wonder the script doesn't work.
Could you look in /storage and see what folders are in there? And then do the same for /storage/extSdCard
If you're feeling brave, have root and have a custom recovery with working nandroid, you could try replacing this line (I TAKE NO RESPONSIBILITY FOR THIS):
Code:
dev_mount sdcard /storage/extSdCard auto /devices/platform/msm_sdcc.4/mmc_host/mmc2/ /devices/platform/msm_sdcc.2/mmc_host/mmc2/
with this:
Code:
dev_mount sdcard /storage/extSdCard auto /devices/platform/msm_sdcc.2/mmc_host/mmc2/ /devices/platform/msm_sdcc.4/mmc_host/mmc2/
after you backup your ROM first.
ChronoReverse said:
Hmm, it's different from previous devices like the Note 2 and GS3. No wonder the script doesn't work.
Could you look in /storage and see what folders are in there? And then do the same for /storage/extSdCard
If you're feeling brave, have root and have a custom recovery with working nandroid, you could try replacing this line (I TAKE NO RESPONSIBILITY FOR THIS):
Code:
dev_mount sdcard /storage/extSdCard auto /devices/platform/msm_sdcc.4/mmc_host/mmc2/ /devices/platform/msm_sdcc.2/mmc_host/mmc2/
with this:
Code:
dev_mount sdcard /storage/extSdCard auto /devices/platform/msm_sdcc.2/mmc_host/mmc2/ /devices/platform/msm_sdcc.4/mmc_host/mmc2/
after you backup your ROM first.
Click to expand...
Click to collapse
Under /storage, I have the following:
container
emulated
extSdCard
sdcard0
UsbDrive (lettered A through F)
Click to expand...
Click to collapse
extSdCard is just my SDcard, and the T-Mobile version doesn't have custom recovery yet.
Hello! Any updates??
BUMP!!! Any updates??
No, but I'm going to try to tweak the script again in a day or two.
Okay, this is the error I'm getting with a modified script. Anyone want to take a crack at it?
The script itself, functional or otherwise, needs to be dropped in /data and you'll need to chmod it to 777.
Working on It also
I've been working on it as well. Samsung has heavily modified the vold.fstab file. They no longer use vold.fstab to mount the internal sdcard storage. We need to find where the file that contains their mounting of the internal sdcard is. We won't be able to swap until we find that file. I am looking.... I strongly recommend not using the script for the Galaxy S3. I compared the S3 vold.fstab and S4 vold.fstab and they are significantly different!
I would be VERY interested to know if or when a swap script is out..
I have had my SGS4 i9505 for 2 days.. And it is almost out of internal card space
Any updates on this one yet ?
@OP.: buddy, what i thought is you must do changes in Vold.fstab file first. I know after changing your mobile be lilbit unstable due to system setting & storage crashing. But then you can provide the logcat. Then we can check the same.
BTW, I have successfully swapped the memories of Galaxy R CM version. But if you could do the changes then I can help you out..
Reply me then I can send you codes via PM.
The latest firmwares do allow you to place games on your sd card.
No need anymore for that script
Sent from my GT-I9505 using xda premium
Sammath said:
The latest firmwares do allow you to place games on your sd card.
No need anymore for that script
Sent from my GT-I9505 using xda premium
Click to expand...
Click to collapse
It can allow you to shift the application not the whole data.
* *
http://forum.xda-developers.com/showthread.php?t=1772234
Sent from my GT-I9500 using xda app-developers app

[Q] Access denied on /sdcard on Lollipop

Hi guys,
I need some hints on what has changed from Android < 5 to Lollipop when it comes to internal storage.
I have booted my Nexus 4 running Lollipop into ClockworkMod recovery and mounted the internal storage.
Then I did an "adb push" of files that I have backed up before to restore those onto the internal storage.
Once that was done I have opened a shell and changed ownership back to media_rw:media_rw and also
checked POSIX permissions to be correct.
Basically this is what I have done so many different times on different Android devices.
Once I have booted back into the system ... I could not access any of those files and directories.
I assume that there was something added on top of plain POSIX access control. A SELinux thing or something
like ACL or stuff, or maybe a database referring to files stored on /sdcard.
Anyway what can I do in recovery mode to make manually copied files and directories available in the system?
Any help would be appreciated!
Thanks in advance!
/Al
I had this problem too but all I could do to correct it was to reflash my ROM.
Sent from my Nexus 4 using Tapatalk
GorfDroid said:
I had this problem too but all I could do to correct it was to reflash my ROM.
Sent from my Nexus 4 using Tapatalk
Click to expand...
Click to collapse
Well finally I went back to 4.4.4 and copied the files back to SD card via adb. I hope the OTA will do everything for me.
But still I would like to understand how it work. This is what I am looking for.
If you are running Lollipop and create a file on SD card it looks exactly the same in Recovery mode. Same user, same group and same POSIX permission ... but still different in some way. How?

Categories

Resources