Directory Bind Like App - Galaxy Note 4 Q&A, Help & Troubleshooting

Is there a directory bind like application that supports lollipop?
Anyone that can point me to the right direction?
TIA

Related

The Way to make programs see the ext sd card

Hey All,
I was trying to find a way to make a symbolic link to the SD card so all the movie programs could see it. On a FAT32 it looks like it isn't doable. You can, however, bind mount to a folder.
Here is the info. Credit goes to korora over at modaco.
You have to be rooted for this to work(or so it seems)
Pop open the terminal and enter the following code:
Code:
cd /mnt/sdcard
mkdir fssd
mount -o bind /Removable/MicroSD /mnt/sdcard/fssd
fssd is generic and can be named whatever you prefer.
Now to find your sd card in a program that can't access /Removable/MicroSD just navigate to /mnt/sdcard/fssd
hope this helps.
Wow, this is sexy! Thanks for this, I have only just done it and a quick poke around with ES File Explorer, but it also is nice because I can just open ES, it defaults to sdcard, so I scroll down to MicroSD (the directory I made) and there it is! I know it only saves me 2 taps of the screen, but still, it's nice. So I say, thanks for bringing it to my attention, as I don't follow those boards.
Thanks,
this is great and works perfectly!
Sent from my Transformer TF101 using Tapatalk
No problem. Glad i could help
amazing how quickly threads get buried here.
Now to add it to the autos execute shell script so it binds every start up.
Neat! Makes me wanna root now Wonder if you could do the same with say a 500GB external USB drive
This is great but we need app developers to now start allowing us to select where we want app data.
Sent from my Transformer TF101 using XDA Premium App
frosty5689 said:
Now to add it to the autos execute shell script so it binds every start up.
Click to expand...
Click to collapse
so it kills it on reboot? is there an easy way to make it automatically execute each startup?
ratindahat said:
so it kills it on reboot? is there an easy way to make it automatically execute each startup?
Click to expand...
Click to collapse
Look for Script Manager in the market.
But I have another question: how can I have programs to save their own settings in this new links/directories?
I do not want to copy it by hand.....and I want to let software recognize their saved settings after a reinstall/restore....
Nice job,this works great,thanks.
sorry for the noob question...
where exactly to put in this code?
i tried making new script with the Script Manager and run it but it says:
CD: not found
mkdir failed for fssd, Read-only file system
mount: no such file or directory
but if it worked this workaround would've been great though
This is what mine says when I open up the script:
#!/system/bin/sh
mount -o bind /Removable/MicroSD /mnt/sdcard/MicroSD
This is with my directory named MicroSD of course. The first line was there when I made a new script so I left it. Not sure if that helps. I already made the directory so I didn't need that command.
Sent from my Transformer TF101 using XDA Premium App
i was trying to figure out where to put the mount line. Thanks, it worked great with script manager.

[Q] Android 4.2: "Public" folder for every user?

Hi folks!
I searched the forum, but couldn't find a proper solution yet.
Is it possible to create a shared ("public") folder, which is accessible for every user on the N7?
As the user accounts seem to be managed under /data/media/ID I already tried:
adb shell
su
mkdir /data/media/pub
chmod 777 /data/media/pub
chown media_rw.media_rw /data/media/pub
ln -s /data/media/pub /data/media/0/pub
So logically the symlink is correct, unfortunately the user doesn't have access to /data/media (which I suspected), so the symlink to /data/media/pub is inaccessible for user 0.
Also other locations doesn't seem to work. On / and /mnt I cannot create a folder, as this is read-only mounted by default, and I don't want to fiddle around with various "mount -o rw/ro" scripts on bootup etc.
Does anybody managed to create a shared folder for every user?
Thanks in advance!
ryazor said:
Hi folks!
I searched the forum, but couldn't find a proper solution yet.
Is it possible to create a shared ("public") folder, which is accessible for every user on the N7?
As the user accounts seem to be managed under /data/media/ID I already tried:
adb shell
su
mkdir /data/media/pub
chmod 777 /data/media/pub
chown media_rw.media_rw /data/media/pub
ln -s /data/media/pub /data/media/0/pub
So logically the symlink is correct, unfortunately the user doesn't have access to /data/media (which I suspected), so the symlink to /data/media/pub is inaccessible for user 0.
Also other locations doesn't seem to work. On / and /mnt I cannot create a folder, as this is read-only mounted by default, and I don't want to fiddle around with various "mount -o rw/ro" scripts on bootup etc.
Does anybody managed to create a shared folder for every user?
Thanks in advance!
Click to expand...
Click to collapse
I'm having the same problem. I have a owner account in which I put some files (4 Gb) that should be available to every user. But user 10 and 11 can't access these files. Where Can I put those files, so that every account can easily access them?
I figured out that each user has a directory under /mnt/shell/emulated (0, 10, 11, etc.). So I created a directory "public" via root under /mnt/shell/emulated/public and made it worldwide writable via chmod -R 777 /mnt/shell/emulated/public. Afterwards I created public folders in each user directories.
It works like a charm when mounting via:
Code:
mount -o bind,allow_other /mnt/shell/emulated/public/ /mnt/shell/emulated/0/public/
I tried to build a simple script and it works when executing it in root shell via ADB. Unfortunately I didn't manage to automate this on boot. I couldn't find any "init.d" directory and also via "Script Manager - SManager" it wasn't working.
Code:
#!/system/bin/sh
PUBLIC_DIR=public
if [ -d /mnt/shell/emulated/$PUBLIC_DIR ]; then
for USER_PATH in /mnt/shell/emulated/*; do
if [ -d $USER_PATH/$PUBLIC_DIR ]; then
busybox mount -o bind,allow_other /mnt/shell/emulated/$PUBLIC_DIR $USER_PATH/$PUBLIC_DIR
fi
done
fi
Any ideas?
It's a start. It would be nice to incorporate it in an app.
It would be even better if it is a standard option in Android 4.2
Sent from my HTC Wildfire S A510e using xda app-developers app
adonet said:
It's a start. It would be nice to incorporate it in an app.
It would be even better if it is a standard option in Android 4.2
Click to expand...
Click to collapse
I agree. At the moment, it seems to be possible only with a lot of fiddle and root including busybox. I don't know, if Google ever will implement such a feature, since it kind of breaks the separation idea of multi user spaces.
I hope, I'm able to figure out, how to get the script working. Everything works except the mount line which requires root privileges. Furthermore the script works correctly when executed from root shell via ADB.
Regards!
Did the updated super SU change anything?
Sent from my HTC Wildfire S A510e using xda app-developers app
I found an easy to implement solution to make a shared directory on the Nexus 7
I used ES file-explorer and set the setting so that it had all the read and write permissions and can go upwards to /
Then I make a new directory in /storage/emulated and give it some name. E.g. /storage/emulated/allusers
Then select the properties of this directory and change it so that everyone has all available permissions.
Now copy the files you want to share in this directory and change the permissions of these files as well.
Now you van change to another account and still read and write these files.
It's a bit of a hassle but it works
★******************
Well I Was too quick. The directory I created suddenly disappeared. I can't find the contents anymore. Where o where would these files go?
Jeroen
Sent from my Nexus 7 using xda app-developers app
Has anyone tried “mkdir /data/media/legacy/pub" instead of “mkdir /data/media/pub"?
I noticed that every user has full access to this legacy folder... In fact, I kinda use this folder to move files between different users!
Well, yes it works. Need to be root though. But it works. Thanks a lot.
I found a solution.
Use the android/obb folder since it is shared space. I added a Movies folder there can can access it from multiple accounts. For MX player to see the movie files I had to uncheck the recognize no media option under settings but it works.
Thank you, I'll try this option too, Better than the solution mentioned above that needs root.
BigJArm said:
I found a solution.
Use the android/obb folder since it is shared space. I added a Movies folder there can can access it from multiple accounts. For MX player to see the movie files I had to uncheck the recognize no media option under settings but it works.
Click to expand...
Click to collapse
I too created a folder in obb but i am not able to access it any reasons??
BigJArm said:
I found a solution.
Use the android/obb folder since it is shared space. I added a Movies folder there can can access it from multiple accounts. For MX player to see the movie files I had to uncheck the recognize no media option under settings but it works.
Click to expand...
Click to collapse
How about using a folder /data/local/tmp for a similar purposes?

Directory blind not working for most apps

I'm on 4.2.1. I tried dead trigger, NFS, and temple run.
Only temple run worked. The other two want me to download the files again.
Sent from my Nexus 7 using Tapatalk 2
That's why I went back to 4.1.2.. 4.2's emulated directory structure doesn't behave well with file explorers or directory bind. The way to bind them is to make your former /sdcard source /storage/shell/emulated/0. My source was /sdcard/usbStorage/sda1/iBird_Pro, and it will bind if I make the source /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro. Notice it didn't bind using sda1. I had to unmount and remount the USB flash drive as sdb1. Also note, my apps wouldn't find the data at the target location, and Directory Bind won't let me make the target its true location at /storage/shell/emulated/0/iBird_Pro
I tried all the fuse, emulated, legacy, and symlinked alternatives. The only successful binding uses the /storage/shell/emulated/0 path.
/data/media/
/storage/sdcard0/
/sdcard/
etc. don't work
What works in 4.1.2
Formerly:
S: /sdcard/usbStorage/sda1/iBird_Pro
T: /sdcard/iBird_Pro
Has to be in 4.2
Now:
S: /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro
T: /sdcard/iBird_Pro
Should be:
S: /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro
T: /storage/shell/emulated/0/iBird_Pro
exglynco said:
That's why I went back to 4.1.2.. 4.2's emulated directory structure doesn't behave well with file explorers or directory bind. The way to bind them is to make your former /sdcard source /storage/shell/emulated/0. My source was /sdcard/usbStorage/sda1/iBird_Pro, and it will bind if I make the source /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro. Notice it didn't bind using sda1. I had to unmount and remount the USB flash drive as sdb1. Also note, my apps wouldn't find the data at the target location, and Directory Bind won't let me make the target its true location at /storage/shell/emulated/0/iBird_Pro
I tried all the fuse, emulated, legacy, and symlinked alternatives. The only successful binding uses the /storage/shell/emulated/0 path.
/data/media/
/storage/sdcard0/
/sdcard/
etc. don't work
What works in 4.1.2
Formerly:
S: /sdcard/usbStorage/sda1/iBird_Pro
T: /sdcard/iBird_Pro
Has to be in 4.2
Now:
S: /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro
T: /sdcard/iBird_Pro
Should be:
S: /storage/shell/emulated/0/usbStorage/sdb1/iBird_Pro
T: /storage/shell/emulated/0/iBird_Pro
Click to expand...
Click to collapse
i was using your way... but not work in 4.2.1

[Q] mount -o bind on Android 4.2

Hi,
I was using Gscript with a mount script to bind my Gameloft game data folders on external USB disk to the original place on the internal SD card.
a sample script is like:
Code:
mount -o bind /storage/usbdisk/N7/Android/Data/com.gameloft.android.ANMP.GloftN3HM /sdcard/Android/data/com.gameloft.android.ANMP.GloftN3HM
However, after updating to Android 4.2, I lost this capability. The mounts are only available within the context of the app that I mount.
When I leave the app (Gscript), and open a terminal emulator, I see the mount (binding) is gone.
Is there a solution to this on Android 4.2 ?
Thanks.
Anybody who can help with this ?
thx.
This should be the same solution as with cifs and others...
http://forum.xda-developers.com/showthread.php?t=2065856
good question,i opened a similar 3ad in past days but no reply..HEREgscripts system and directory bind aren't working anymore..i think it's the changed mount points or how android manage them..
vorcers,
thanks for this information. But what do you mean by 'Stickmount writes the shell-commands in "/system/bin/debuggerd"' ?
/system/bin/debuggerd seems to be a binary file. How can we write shell commands in it ?
Thanks.
..
mrmrmrmr said:
vorcers,
thanks for this information. But what do you mean by 'Stickmount writes the shell-commands in "/system/bin/debuggerd"' ?
/system/bin/debuggerd seems to be a binary file. How can we write shell commands in it ?
Thanks.
Click to expand...
Click to collapse
any ideas ?

[Q] How to change the "screen tap" sound?

BEFORE YOU READ ANYTHING, please note that I have ALREADY TRIED to no avail.
Hi guys,
If anyone could please help me with this, that'd be great. So, I have mounted /system as read-write numurous ways, a terminal emu, an app, and adb. I also heard somewhere that "chmod 777 /system" may help with permissions. I did all that. Second, I mounted using ES and retrieved my own sound to replace "TW_Touch" and "S_HW_Touch.ogg." However, once the copy/paste operation is complete, if I try to play the file to make sure it worked, there's no sound in the file anymore. Basically the file is silenced the moment it goes into /system/media/audio/ui. Can anyone help me here?
Thanks in advance,
Superluig164

Categories

Resources