yashsingh1/xdaforums huggingface dataset:
[Android Software Development] krogoth:
Restoring backup won't help. I've tried this allready.

Messing with this xml file is dangerous and causes issues..
[Android Software Development] FuTChY:
if you have your original xml file restore it and remove any init.d script and then install the latest version.
[Android Software Development] vhick:
There is no point in applying code for specific apps. It just a code that you tell the app that it can write to external sd. But using xinternalsd will write external data of the app directly/automatically to external sd or if you specify the save path in one particular app to save its external data to micro sd card.

Its 755.

Cheers...
[Android Software Development] madhero:
This is sad and not worth the trouble. Be Careful guys.
[Android Software Development] jacobobbo:
Not working on Redmi note 3 pro on twrp System Aosp 5.1. 1 Kenzo.. :(
[Android Software Development] dadda:
Where can I find the init.d script at
[Android Software Development] FuTChY:
/system/etc/init.d

be sure about what you remove
[Android Software Development] dadda:
Which one to remove.
[Android Software Development] FuTChY:
i dont recognize any of them so i believe you dont have to remove anyone.
[Android Software Development] dadda:
Ok I'm going to restore my packages.xml and flash the new update in TWRP.
[Android Software Development] FuTChY:
Ok good luck

try to have a clean nandroid first.
[Android Software Development] dadda:
A clean nandroid never heard of that.
[Android Software Development] FuTChY:
I mean a nandroid backup without any modifications so that you can always revert changes if anything went wrong.
[Android Software Development] dadda:
Oh ok thanks.
[Android Software Development] smw6230:
No.

As I said I couldn't get it to work so I kept checking in on the thread and trying new "suggestions". I actually got it to work early on but the fix either overwrote itself after every boot or I had a 'google has stopped working error. I had a nandroid system backup so I used that as a base while tinkering. I'm pretty sure the end result was I installed Universal init.d from the playstore before I flashed the fix, because I didn't have that folder in system/etc, I then pasted the 11FixPermsMob script into the init.d folder. As I said I also had the XinternalSD module running in xposed.

FWIW, I didn't actually use the script on page 24. On page 26 someone made a flashable busybox zip for the mod that had the file included. I downloaded that zip and extracted 11FixPermsMob from there and inserted that file into my system/etc/ init.d. folder

Looking at my file now the 11FixPermsMob permissions are rwx r-w --x

BTW, I'm rooted running TWRP 3.0

BTW II, I never messed with the packages.xml file at all.

BTW III, As I mentioned in my post I had a working nandroid backup saved. I highly recommend having a pristine one saved before attempting anything with this mod. Having one stored allows you do flash this mod and tinker secure in the knowledge that if it doesn't work you can just do a restore and you'll be good as old.
[Android Software Development] dimm0k:
I've used XInternalSD in the past, great module except there doesn't seem to be much support for it these days so I'm trying to do things "on my own" so that I wouldn't depend on this module...
[Android Software Development] hiimpig1:
well, i not testing new version yet because im busy now

but could sunday i will backup my rom and retest !
[Android Software Development] rufus.wilson:
That would be brilliant. Thank you.
[Android Software Development] hiimpig1:
i still got FC but only happened with Google Play services and internet still not working

p/s : i going to file explorer and i dont see where is sdcard (not extsd) in my phone

and platform.xml have notting in there

u should create uninstall .zip file too
[Android Software Development] SAM209:
Does this work with Marshmallow?
[Android Software Development] rufus.wilson:
That is odd... Could you compare your original platform.xml and the modified one? Maybe I am modifying things elsewhere...

I have added the reverting in the latest release (v1.6b). V1.6b - 2016-01-27 - Recovery MD5 file.
[Android Software Development] phoberus:
6.0.1 (CM13 by Temasek)
[Android Software Development] rufus.wilson:
I don't think so as this problem has been resolved in Marshmallow.

You can always try, the latest version 1.6b will revert if you run it twice.

V1.6b - 2016-01-27 - Recovery MD5 file

Before you try it, make a nandroid backup of your system.
[Android Software Development] rufus.wilson:
:confused:

I thought this problem was only occuring in KitKat and Lollipop.
[Android Software Development] phoberus:
No problem, will try this fix in some weeks again :)
[Android Software Development] hiimpig1:
sorry i just flashed my old rom back !
[Android Software Development] SAM209:
No it wasn't. ComicRack for example can't read/write to the sd card. I tried the manual permissions file editing that worked on kitkat but it won't work with Marshmallow.
[Android Software Development] rufus.wilson:
This is because the APP author should update his code to request new permissions.

[MENTION=5499170]phoberus[/MENTION], [MENTION=4559392]SAM209[/MENTION],

See above if your query is about a certain app not being able to access the SD card. There may hold the answer.
[Android Software Development] satanas17:
Hi,

Here is my little contribution :

Moto G 4G LTE

BeanStalk MM 6.0.1Rom v6.0.6 : http://xdaforums.com/moto-g/4g-development/rom-beanstalk-6-03-12-27-2015-t3280520

Phone is booting well and everything seems ok...but really don't know what to do for testing further...

I'm totally noob in those testings but ask me and tell me what to do [MENTION=6935794]rufus.wilson[/MENTION] and i'll do my best ;)
[Android Software Development] rufus.wilson:
Thank you for your contribution however Marshmallow (Android 6.0, API 23) does not suffer from the same problem as KitKat and Lollipop. If you have a problem with an app, you should contact directly the author and point him to the thread I have linked to in the OP.
[Android Software Development] satanas17:
Ok ;)

Misunderstanding on your dev...will try to read little more carefully, English isn't my native language ;)
[Android Software Development] rufus.wilson:
To be completely honest with you I added it probably at the same time you were testing/reporting... :o
[Android Software Development] SAM209:
But what if they don't? There must be a workaround or something.
[Android Software Development] rufus.wilson:
This is slightly off-topic but my understanding is that if an app doesn't ask for the permission android will not let it do what it wants to do.

I don't think there is any workaround except going back to Lollipop or modify the sources.
[Android Software Development] satanas17:
:laugh::laugh::laugh::laugh:

no worries ;)
[Android Software Development] vinimdi:
I don't know if I understood completely this fix, but a good way to test if works is installing spotify on MM, cause the app can't recgonize the sdcard as a external storage and I have to change manually the path to spotify store its files on extsd. I'll try it, if Spotify start to store the files on extsd this is a huge step up. If I didnt understand the purpose of this fix, pls let me know.

Cheers

Sorry I got it wrong =(....i missed the "doest not work on MM" on the first post...sorry guys
[Android Software Development] keytor69:
2.1b kept on giving me error 2

2.0 also gave me error 2

1.9 installed ok

twrp 3.0.2.0

Samsung Galaxy Note 4

Android 6.0.1

Different Version links

http://xdaforums.com/devdb/project/?id=13505#downloads
[Android Software Development] almeewar:
Tried V2.1b - 2016-05-19 at Sony Xperia SP CM13.0-2016-05-29 - didn't work ("Updater process ended with ERROR: 2").
[Android Software Development] madhero:
Anyone knows how to revert back to original? I've read the OP but don't quite get which file to replace which. I've checked my files and as attached, this is what I have. Any guidance is much appreciated.
[Android Software Development] Durocks:
Confirmed version 1.9b working on Galaxy S7 Edge G935F (Stock Rom & Kernel, Root + Xposed). Newer versions return "Error: 2".

Thank You.
[Android Software Development] zolee_:
S5 on Alexandr rom CPE2

Latest version giving error 2

1.9b stuck at "Samsung" (second screen) pulsing for 15min now...

Had to revert back to original packages.xml othervise it wont boot.
[Android Software Development] zolee_:
[MENTION=364936]madhero[/MENTION]

In twrp go to advanced and then file browser

There go to data/system

Rename packages.xml to for example packages.xml.bkp

Then rename packages.xml-rw-20160517xyxyxy.bak (asuming that is the latest one by the date in the filename) to packages.xml

Clean cache & dalvik, reboot
[Android Software Development] FuTChY:
Probably the first backed up file in the attached image. it's the earliest.
[Android Software Development] Robbie P:
unexpected elif line 67 of update binary. 2.1b

Trying to get this to work on HD2 marshmallow rom, API 23

Edit; if I put ui_print "blah" between then and elif, I then get unexpected else line 202

Edit2; if I put ui_print "dunno" between then and else, the script finishes. But the rom hangs on bootanimation. After re-installing, I see "dunno" in recovery.log, but also see ch_con not found.

*******************************

SDCARD PERMISSION FIX v2.1b

by RW

*******************************

- Mounting /system

- Mounting /system

- Detecting current API version

2+0 records in

2+0 records out

2 bytes (2B) copied, 0.023591 seconds, 84B/s

API v23 detected

/tmp/updater: line 216: ch_con: not found

dunno

- Unmounting /system

- Done !

BTW I added a couple of lines in the mount section to mount /system from ext partition on sdcard (specific to my device), so the line 216 relates to line 214 in the original binary script.

TWRP 2.8.7.0

Hope this all helps.

Edit 3; new /data/system/packages.xml is empty
[Android Software Development] M94Khaled:
Error 2

Error 2 when flashing v2.1b on Xperia Z2.
[Android Software Development] Tecalote:
Question to this method

Can I try this instead of flashing the fix from rufus wilson, or should I flash the fix and add your init.d command file as you have written?
[Android Software Development] FuTChY:
My init.d file is a subset of the original fix of rufus wilson

You can try it, but you need to take a nandroid backup or backup your original xml file first just in case anything went wrong.
[Android Software Development] Tecalote:
Thanks for the fast answer, I will try it this evening and tell you the result tomorrow

Does it work even with the version 1.9b? because some weeks ago I tried to flash the 2.1b and got an error and a Bootloop
[Android Software Development] FuTChY:
I actually didn't flash 1.9 or 2.1. I just used the script in my post. If you have time, please test it :)
[Android Software Development] Tecalote:
Okay, thanks... I will test it soon and tell you, how it works on my device
[Android Software Development] FuTChY:
Good luck. I wish it does.
[Android Software Development] charisma_:
I tried 2.1b and gave me error 2

Then installed 1.9 and it worked

CM 13

twrp 3.0.2.0

LG L90 II (LG D410)
[Android Software Development] Fenopy:
2.1b- Error: 2

2.0b- Error: 2

1.9b- Successful

After flashing 1.9b, my issues seem to be resolved with writing to my SD Card via apps that do not request permissions (tested with swiFTP).

Device Info:

LG V10 (T-Mobile variant)

LG-H901

TWRP 3.0.2.0 (unofficial)

Android 6.0, stock-rooted
[Android Software Development] dhruubo:
Got bootloop after flashing 1.9b
[Android Software Development] J0kker:
Cm13 on oneplus x, the script is working for a few weeks now. :)
[Android Software Development] FuTChY:
Are you asking or telling us :D

Actually I'm not running CM13 now. So I can't tell.
[Android Software Development] J0kker:
Edited, don't know why my emote resulted in two? lol
[Android Software Development] FuTChY:
What's emote please ? :rolleyes:
[Android Software Development] J0kker:
Sorry, I meant smiley, emote is a French word I think.
[Android Software Development] FuTChY:
No problem, you're french but it's not your fault :D :highfive:
[Android Software Development] Toi_n:
Thank's 1.9b Worked on my note 4 (910F) MM6.0.1 TW stock rom

Also here, tried out TWRP and Philz recovery both unsuccessful and same error with V2.0 and 2.1........

I got lucky with Philz and 1.9b... thank you man!

PS : it works fore some apps, like Locus but I can not get TB to work with it right... humm, have to keep looking...(or maybe I just will revert to Lollipop... I hate it not to have control over my own memory...just so I buy there ****ty cloud storage... what about being in airplane mode..?)
[Android Software Development] mikhaelpermanto:
how to uninstall this "extSD fix" , because my phone is bootloop. what the solution mr ?
[Android Software Development] :No-Frost::
Go into recovery and delete the file created, then, restore the backup that the ZIP created... Sorry, don't have much time to explain it better...
[Android Software Development] mikhaelpermanto:
what file created to delete ? i dont understand :( , so what file i must restore ? any body can explain more ? thanks for the attention.
[Android Software Development] :No-Frost::
In twrp go to advanced and then file browser

There go to data/system

Rename packages.xml to for example packages.xml.bkp

Then rename packages.xml-rw-20160517xyxyxy.bak (asuming that is the latest one by the date in the filename) to packages.xml

Clean cache & dalvik, reboot

Copied from other user... Sorry for not giving the proper credits.
[Android Software Development] mikhaelpermanto:
thanks for expalining Mr, now i understand ... yeahhhh :good:
[Android Software Development] rufus.wilson:
Thank you, that helped to debug.
[Android Software Development] dreas74:
with my z3c concept os i have also the error2 with v2.2b :(

only the 1.9 version works for me.

(another thing, the download latest link in the first post links to the 2.1 version and not to the 2.2)
[Android Software Development] mattiadj:
error2 is here with 2.2.b

The best version remains 1.9
[Android Software Development] Yudh:
[MENTION=6935794]rufus.wilson[/MENTION]

In v1.9 went into bootloop

In v2.1 error 2 occurred.

Thanks for guidance for reverting

I am going to try v2.2

I am on marshmallow resurrection remix rom on my Samsung Galaxy Note 2(GT-N7100)
[Android Software Development] ggelo10:
error 2 on v2.2

android 6.0.1 r43 sgs3
[Android Software Development] rufus.wilson:
When does this error happen? (Screenshots accepted)
[Android Software Development] smsm0111:
I have huawei honor 3c with CM 13 on it .

this is ok in ''ADM'' & ''ZAPYA'' app , but

i install htc camera app on it and , but this error shown : your removable storage is unavailable . storage has been switches to internal storage .

why?
[Android Software Development] rufus.wilson:
Which version did you flash?
[Android Software Development] mattiadj:
Twrp 3.0.2 android 6.0.1 note 4 F
[Android Software Development] bnwg:
Sorry. Just want to confirm if it's the latest version 2.2b from the latest download link given as the file name and the upload date is not matched (2016-06-02) from the link
[Android Software Development] rufus.wilson:
Yep, forgot to update the link. Will do later. Thanks for reporting...
[Android Software Development] rufus.wilson:
Thank you. What do you see in the log window when you flash?
[Android Software Development] :
I can't backup apps with titanium backup to sdcard. So flashing this mod solve this problem?

Thank-You

RR 5.6.9 s4 mini
[Android Software Development] charisma_:
I found the solution for TB on youtube and it worked on my lg d410,

I tried to post the link but i have less than 10 posts
[Android Software Development] rufus.wilson:
Could you try the latest one v2.3b?

I have included a lot of debug messages to help me solve the problem.

Thanks
[Android Software Development] Robbie P:
a quick scan through of update-binary of 2.2b, I see then-elif and then-else at lines 148-150

might be causing the error 2 again?
[Android Software Development] Gambler FEX online:
you need to change a setting in Preferences - Backup folder location. Near the top is Storage Provider. Click and change to DocumentProvider.

http://xdaforums.com/note-3-tmobile/help/titanium-backup-sd-card-writable-t3048140
[Android Software Development] rufus.wilson:
Isn't it the correct way of writing? Seems OK from here.

It is indeed a problem. It should be fixed in the latest release.
[Android Software Development] Robbie P:
It might help the Developer to debug for users to post the recovery.log when testing. It provides more information than just "status 2", such as what line the error occurred.

In TWRP, immediately after flashing, go to advanced/copy-log-to-sd and then look for a file recovery.log on sdcard, then post it here.
[Android Software Development] vd69:
Where is the latest release?

Where is the latest release?
[Android Software Development] rufus.wilson:
v2.3b here. Did not think it would be difficult to find.
[Android Software Development] Faraco80:
Samsung I9505, cm-13.0-20160602-NIGHTLY, TWRP 3.0.2.0, Supersu 2.71, xposed v84...

Just flashed extsd 2.3 and worked fine.

I still have the problem that with whatsapp, it CAN write in external SD but CAN'T read from esternal SD.

Like someone said before, i just can see the images that i save in the esternal SD in the gallery after rebooting...

Sorry My bad english...
[Android Software Development] mattiadj:
No problem flashing latest 2.3b but the fix doesn't work. I have to use 1.9 version but I need to flash it at every new app installed. Very annoying.
[Android Software Development] TheMasterMindGT:
MM recently upgrade to 6.0.1 my Samsung S5 Verizon, I have root access and TWRP recovery, I installed this tool but I can not write access to SD.
[Android Software Development] Yudh:
No need to flash the zip for it . Watch YouTube videos

✌
[Android Software Development] rufus.wilson:
What does the recovery log say?

Which files do you have in /system/etc/init.d/?

Do you have a folder /system/xbin/?

Did it contain a busybox file?
[Android Software Development] rcatank:
i just boned my G900P on stock 6.0.1 with a TWRP flash of this. Got the latest 1.9b and bootloop - battery is going to explode. I can probably start a camp fire...

Going to restore system in the AM - hopefully thats all thats needed.
[Android Software Development] rufus.wilson:
You should try 2.3b which is the latest.
[Android Software Development] M94Khaled:
FIX 2.3 Not Installed

I'm trying to flash latest fix but the log file shows a problem init.d location i think!.. XPERIA Z2 MM 25.A.0.575

Installing zip file '/external_sd/ADM/Archives/ExtSD_Fix_rw-signed-v2.3b.zip'

Checking for MD5 file...

MD5 matched

I:Zip does not contain SELinux file_contexts file in its root.

I:Legacy property environment initialized.

*******************************

SDCARD PERMISSION FIX v2.3b

by RW

*******************************

[LOG] Creating timestamp

__bionic_open_tzdata: couldn't find any tzdata when looking for UTC0!

__bionic_open_tzdata: couldn't find any tzdata when looking for posixrules!

[LOG] finished - 20160603080844

[LOG] system not mounted

- Mounting /system

[LOG] finished

- Detecting current API version

API v23 detected

[LOG] Logic for API 23

[LOG] Script location: /tmp/ExtSD_fix_23_20160603080844.sh

- Installing init.d script

unzip: can't change directory to '/tmp/ExtSD_fix_23_20160603080844.sh': No such file or directory

[LOG] finished

- Setting script permissions

chown: /tmp/ExtSD_fix_23_20160603080844.sh: No such file or directory

chown: /tmp/ExtSD_fix_23_20160603080844.sh: No such file or directory

chmod: /tmp/ExtSD_fix_23_20160603080844.sh: No such file or directory

chcon: too few arguments

[LOG] finished

[LOG] init.d not supported

- Adding permisions

CANNOT LINK EXECUTABLE: cannot locate symbol "__register_atfork" referenced by "/system/bin/sh"...

page record for 0xb6f7804c was not found (block_size=32)

[LOG] finished

INFO ROM does not support init.d

- Removing script

rm: can't remove '/tmp/ExtSD_fix_23_20160603080844.sh': No such file or directory

[LOG] finished

- Unmounting /system

[LOG] finished

- Done !
[Android Software Development] rufus.wilson:
Thanks for reporting.

There is a problem in the zip file.

On top of this, it seems that your device does not support init.d. This means that you will have to flash the zip file at each app update and for new app installation.
[Android Software Development] M94Khaled:
Is it common for Xperia Z2 to not support init.d ??

Is there is any way to solve this?
[Android Software Development] rufus.wilson:
I don't know...

Could you check that the following folders do not exist?

/System/etc/init.d/

/etc/init.d/
[Android Software Development] :No-Frost::
Hey mate, wouldn't it be better that the script overwrite the package.xml file?

I've just deleted more than 60 mb of backup files :eek:
[Android Software Development] M94Khaled:
No, I can't see any of these folders.
[Android Software Development] rufus.wilson:
What if something goes wrong? I prefer to keep copies of files as it is the only way to revert...
[Android Software Development] :No-Frost::
Sorry, the autocorrect changed the word... I wanted to say that wouldn't be better to keep just one backup file and overwrite the package.xml.bak instead or creating a new one every time.

I'm not a shell script expert and what I did was to delete the part were the script renames a new backup with date and time, in order to overwrite the backup and prevent the creation of several files.
[Android Software Development] rufus.wilson:
I prefer to keep all versions to allow the user to go back to a previously working state.

Glad you changed it to suit your needs.
[Android Software Development] M94Khaled:
Hey, Solved It using [MENTION=4576707]Ryuinferno[/MENTION] http://xdaforums.com/showthread.php?p=32716412#post32716412

Should i find any files in the /init.d folder to cofirm that your fix is well installed?
[Android Software Development] rufus.wilson:
Excellent, I'll add the link to the description.

Yes, in /system/etc/init.d there should be at least a file.
[Android Software Development] rcatank:
OP's "download latest" link goes to 1.93b, had to go to Downloads tab for 2.3b - Just FYI OP

Also tried flashing 2.3b on G900P as mentioned earlier, and no go - Still in a boot lock.

Just restored /system partition, and I dont think that is helping either - been 10 minutes already waiting for boot. I have already cleaned delvik and cache few times in between already also.
[Android Software Development] DarkSJ1998:
[MENTION=6935794]rufus.wilson[/MENTION] Thanks a tonn buddy! v1.9b finally working for me on my YUREKA PLUS (tomato) on CM13.0 NIGHTLY! :D

V1.9b:-

Working great!

V2.1b:-

ERROR-2 here also

V2.3b:-

Flashed but no effect

It didn't work on RR 5.6.7 I don't know why...

Anyways, Thanks again!

---------- Post added at 10:25 PM ---------- Previous post was at 09:59 PM ----------

Restoring /system won't help coz the zip modifies a file in the /data partition.. you might wanna do it manually...

Use TWRP File Manager for it.

Go to /data/system & there should be a file named "packages-xxxxxxxxx.bak" there... you just need to remove the file named "packages.xml" & rename the .bak one to "packages.xml".

Correct me if I'm wrong guys :)
[Android Software Development] M94Khaled:
I also didn't see any effect effect after flashing 2.3b..

You should look in \system\etc\init.d\ folder, Supposedly after flashing, you should find a file called 99_EXTfix or somethin like that, in my case i didn't see this.. But i solved it by unzipping the fix2.3b file and copied the file with name indicated above and pasted it into the path above and rebooted and every thing went well.
[Android Software Development] Yudh:
Did you solve the problem you discovered ?

Also i am on resurrection remix ROM marshmallow

Which zip file I should use?

v1.9 caused bootloop v2.1 caused error=2

✌
[Android Software Development] DarkSJ1998:
Alright! Thanks for the info! :D

And, I have a query, we have to flash v1.9b after installing an app, right? Is this case the same with v2.3b? Or v2.3b is one time flash only?