4.3 sd card issues fixed

Search This thread

occupational_hazard

Senior Member
Mar 20, 2011
1,363
525
McAlester
I am currently working on a solution to fix 4.4 with more stable results.

I have created a flashable zip that works in an aftermarket recovery. It replaces the platform.xml file with modified file that has the necessary permission line to make the sd card writable now. That is the only thing changed. I added the under WRITE_EXTERNAL_STORAGE.

You need to be on a custom recovery. This update only applies to I9505G. If you do not have an S4 GOOGLE EDITION PHONE, then please disregard and move on.

Warning; You are flashing this at your own risk. I am not responsible for broken devices, deleted memory cards, phones thrown from raging, or WW3.

Download the flashable from here: http://d-h.st/Eif

Download the modified platform.xml to replace the original from here if you would rather push it: http://d-h.st/ooU
(this is not needed with zip, already included)

1. Place the zip the on your internal or external drive.
2. Reboot to your custom recovery, ie ( twrp, cwm)
3. Create a backup, have a restore point if it does not work.
4. Wipe dalvik and cache
5. Install the zip file
6. Wipe the dalvik and cache just to be sure.
7. Reboot phone.

Test to make sure it worked by using any file explorer, ie(solid explorer, root explorer, etc.) and creating a new folder, text document, or whatever. Do this through the phone, not a p.c. If it does not work, reboot to recovery, restore back to previous point and let me know asap.
 
Last edited:

occupational_hazard

Senior Member
Mar 20, 2011
1,363
525
McAlester
I did use Samurai's Odin package to update to mh5. I figures it would revert the permissions. My zip still works.

And TWRP 2.6.3.0 is out.

Sent from my GT-I9505G using Tapatalk 4
 

bleez99

Senior Member
May 1, 2011
313
263
Nvidia Shield
Google Pixel 6 Pro
I have created a flashable zip that works in an aftermarket recovery. It replaces the platform.xml file with modified file that has the necessary permission line to make the sd card writable now. That is the only thing changed. I added the <group gid="media_rw"/> under WRITE_EXTERNAL_STORAGE.

You need to be on a custom recovery. This update only applies to I9505G. If you do not have an S4 GOOGLE EDITION PHONE, then please disregard and move on. This is only for the MH1 4.3 firmware that does not allow you to write to the sdcard.

Warning; You are flashing this at your own risk. I am not responsible for broken devices, deleted memory cards, phones thrown from raging, or WW3.

Download the flashable from here: http://d-h.st/Eif

Download the modified platform.xml to replace the original from here if you would rather push it: http://d-h.st/ooU
(this is not needed with zip, already included)

1. Place the zip the on your internal or external drive.
2. Reboot to your custom recovery, ie ( twrp, cwm)
3. Create a backup, have a restore point if it does not work.
4. Wipe dalvik and cache
5. Install the zip file
6. Wipe the dalvik and cache just to be sure.
7. Reboot phone.

Test to make sure it worked by using any file explorer, ie(solid explorer, root explorer, etc.) and creating a new folder, text document, or whatever. Do this through the phone, not a p.c. If it does not work, reboot to recovery, restore back to previous point and let me know asap.

You're welcome.

http://xdaforums.com/showthread.php?p=44370296

When dialog fails, it's time for violence.
 

occupational_hazard

Senior Member
Mar 20, 2011
1,363
525
McAlester
Really I would have never thought of doing that. That's ground breaking. Extraordinary!

Now do more research and you will see people have trouble writing to that file with root and trying a multitude of file explorers. And mounting system r/w. I still couldn't. Hence the links to the flashable in the op.

So....


Your welcome.

Sent from my GT-I9505G using Tapatalk 4
 
  • Like
Reactions: apollokid

bleez99

Senior Member
May 1, 2011
313
263
Nvidia Shield
Google Pixel 6 Pro
Really I would have never thought of doing that. That's ground breaking. Extraordinary!

Now do more research and you will see people have trouble writing to that file with root and trying a multitude of file explorers. And mounting system r/w. I still couldn't. Hence the links to the flashable in the op.

So....


Your welcome.

Sent from my GT-I9505G using Tapatalk 4

My sincere apologies. I'm having a bad day. I'm glad I could contribute to your work.

When dialog fails, it's time for violence.
 

wilbarger

Senior Member
Aug 8, 2012
692
416
USA
Prior to updating, I was running CM 10.2. I flashed back to stock 4.3 from here http://xdaforums.com/showthread.php?t=2442445 and then flashed 4.4 from here http://xdaforums.com/showthread.php?t=2544056. After that (which went flawlessly), I copied the SD card fix from this thread and then installed it. No issues at all and everything works perfectly.

We are lucky to have SamuriHL and MJHawaii helping us out with our phones. Sorry, left out occupational_hazard. No disrespect meant.
 

occupational_hazard

Senior Member
Mar 20, 2011
1,363
525
McAlester
Below is the text from the platform.xml that is on my phone after I updated. There shouldn't be any need to flash on 4.4. But please let me know if I am wrong. I also can make the original 4.3 platform.xml file to flash so you can update through recovery of that is the issue


<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->

<!-- This file is used to define the mappings between lower-level system
user and group IDs and the higher-level permission names managed
by the platform.

Be VERY careful when editing this file! Mistakes made here can open
big security holes.
-->
<permissions>

<!-- ================================================================== -->
<!-- ================================================================== -->
<!-- ================================================================== -->

<!-- The following tags are associating low-level group IDs with
permission names. By specifying such a mapping, you are saying
that any application process granted the given permission will
also be running with the given group ID attached to its process,
so it can perform any filesystem (read, write, execute) operations
allowed for that group. -->

<permission name="android.permission.BLUETOOTH_ADMIN" >
<group gid="net_bt_admin" />
</permission>

<permission name="android.permission.BLUETOOTH" >
<group gid="net_bt" />
</permission>

<permission name="android.permission.BLUETOOTH_STACK" >
<group gid="net_bt_stack" />
</permission>

<permission name="android.permission.NET_TUNNELING" >
<group gid="vpn" />
</permission>

<permission name="android.permission.INTERNET" >
<group gid="inet" />
</permission>

<permission name="android.permission.READ_LOGS" >
<group gid="log" />
</permission>

<permission name="android.permission.READ_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
</permission>

<permission name="android.permission.WRITE_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
<group gid="sdcard_rw" />

</permission>


<permission name="android.permission.ACCESS_ALL_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
<group gid="sdcard_rw" />
<group gid="sdcard_all" />
</permission>

<permission name="android.permission.WRITE_MEDIA_STORAGE" >
<group gid="media_rw" />
</permission>

<permission name="android.permission.ACCESS_MTP" >
<group gid="mtp" />
</permission>

<permission name="android.permission.NET_ADMIN" >
<group gid="net_admin" />
</permission>

<!-- The group that /cache belongs to, linked to the permission
set on the applications that can access /cache -->
<permission name="android.permission.ACCESS_CACHE_FILESYSTEM" >
<group gid="cache" />
</permission>

<!-- RW permissions to any system resources owned by group 'diag'.
This is for carrier and manufacture diagnostics tools that must be
installable from the framework. Be careful. -->
<permission name="android.permission.DIAGNOSTIC" >
<group gid="input" />
<group gid="diag" />
</permission>

<!-- Group that can read detailed network usage statistics -->
<permission name="android.permission.READ_NETWORK_USAGE_HISTORY">
<group gid="net_bw_stats" />
</permission>

<!-- Group that can modify how network statistics are accounted -->
<permission name="android.permission.MODIFY_NETWORK_ACCOUNTING">
<group gid="net_bw_acct" />
</permission>

<permission name="android.permission.LOOP_RADIO" >
<group gid="loop_radio" />
</permission>

<!-- ================================================================== -->
<!-- ================================================================== -->
<!-- ================================================================== -->

<!-- The following tags are assigning high-level permissions to specific
user IDs. These are used to allow specific core system users to
perform the given operations with the higher-level framework. For
example, we give a wide variety of permissions to the shell user
since that is the user the adb shell runs under and developers and
others should have a fairly open environment in which to
interact with the system. -->

<assign-permission name="android.permission.MODIFY_AUDIO_SETTINGS" uid="media" />
<assign-permission name="android.permission.ACCESS_SURFACE_FLINGER" uid="media" />
<assign-permission name="android.permission.WAKE_LOCK" uid="media" />
<assign-permission name="android.permission.UPDATE_DEVICE_STATS" uid="media" />
<assign-permission name="android.permission.UPDATE_APP_OPS_STATS" uid="media" />

<assign-permission name="android.permission.ACCESS_SURFACE_FLINGER" uid="graphics" />

<!-- This is a list of all the libraries available for application
code to link against. -->

<library name="android.test.runner"
file="/system/framework/android.test.runner.jar" />
<library name="javax.obex"
file="/system/framework/javax.obex.jar"/>

</permissions>




Sent from my GT-I9505G using Tapatalk
 
Last edited:
  • Like
Reactions: randolphslim

wilbarger

Senior Member
Aug 8, 2012
692
416
USA
I think you may be mistaken. After flash, it is as you stated. From what I understand, you will need to add (either by editing or by using your file in this thread) to change platform.xml to have <group gid="media_rw" /> statement under WRITE_EXTERNAL_STORAGE

Are you saying that you can store to external SD without this statement? I could not until I made the change.
 

jimmyjoebob

Senior Member
Jun 3, 2010
111
11
Below is the text from the platform.xml that is on my phone after I updated. There shouldn't be any need to flash on 4.4. But please let me know if I am wrong. I also can make the original 4.3 platform.xml file to flash so you can update through recovery of that is the issue


<?xml version="1.0" encoding="utf-8"?>
<!-- Copyright (C) 2008 The Android Open Source Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->

<!-- This file is used to define the mappings between lower-level system
user and group IDs and the higher-level permission names managed
by the platform.

Be VERY careful when editing this file! Mistakes made here can open
big security holes.
-->
<permissions>

<!-- ================================================================== -->
<!-- ================================================================== -->
<!-- ================================================================== -->

<!-- The following tags are associating low-level group IDs with
permission names. By specifying such a mapping, you are saying
that any application process granted the given permission will
also be running with the given group ID attached to its process,
so it can perform any filesystem (read, write, execute) operations
allowed for that group. -->

<permission name="android.permission.BLUETOOTH_ADMIN" >
<group gid="net_bt_admin" />
</permission>

<permission name="android.permission.BLUETOOTH" >
<group gid="net_bt" />
</permission>

<permission name="android.permission.BLUETOOTH_STACK" >
<group gid="net_bt_stack" />
</permission>

<permission name="android.permission.NET_TUNNELING" >
<group gid="vpn" />
</permission>

<permission name="android.permission.INTERNET" >
<group gid="inet" />
</permission>

<permission name="android.permission.READ_LOGS" >
<group gid="log" />
</permission>

<permission name="android.permission.READ_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
</permission>

<permission name="android.permission.WRITE_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
<group gid="sdcard_rw" />

</permission>


<permission name="android.permission.ACCESS_ALL_EXTERNAL_STORAGE" >
<group gid="sdcard_r" />
<group gid="sdcard_rw" />
<group gid="sdcard_all" />
</permission>

<permission name="android.permission.WRITE_MEDIA_STORAGE" >
<group gid="media_rw" />
</permission>

<permission name="android.permission.ACCESS_MTP" >
<group gid="mtp" />
</permission>

<permission name="android.permission.NET_ADMIN" >
<group gid="net_admin" />
</permission>

<!-- The group that /cache belongs to, linked to the permission
set on the applications that can access /cache -->
<permission name="android.permission.ACCESS_CACHE_FILESYSTEM" >
<group gid="cache" />
</permission>

<!-- RW permissions to any system resources owned by group 'diag'.
This is for carrier and manufacture diagnostics tools that must be
installable from the framework. Be careful. -->
<permission name="android.permission.DIAGNOSTIC" >
<group gid="input" />
<group gid="diag" />
</permission>

<!-- Group that can read detailed network usage statistics -->
<permission name="android.permission.READ_NETWORK_USAGE_HISTORY">
<group gid="net_bw_stats" />
</permission>

<!-- Group that can modify how network statistics are accounted -->
<permission name="android.permission.MODIFY_NETWORK_ACCOUNTING">
<group gid="net_bw_acct" />
</permission>

<permission name="android.permission.LOOP_RADIO" >
<group gid="loop_radio" />
</permission>

<!-- ================================================================== -->
<!-- ================================================================== -->
<!-- ================================================================== -->

<!-- The following tags are assigning high-level permissions to specific
user IDs. These are used to allow specific core system users to
perform the given operations with the higher-level framework. For
example, we give a wide variety of permissions to the shell user
since that is the user the adb shell runs under and developers and
others should have a fairly open environment in which to
interact with the system. -->

<assign-permission name="android.permission.MODIFY_AUDIO_SETTINGS" uid="media" />
<assign-permission name="android.permission.ACCESS_SURFACE_FLINGER" uid="media" />
<assign-permission name="android.permission.WAKE_LOCK" uid="media" />
<assign-permission name="android.permission.UPDATE_DEVICE_STATS" uid="media" />
<assign-permission name="android.permission.UPDATE_APP_OPS_STATS" uid="media" />

<assign-permission name="android.permission.ACCESS_SURFACE_FLINGER" uid="graphics" />

<!-- This is a list of all the libraries available for application
code to link against. -->

<library name="android.test.runner"
file="/system/framework/android.test.runner.jar" />
<library name="javax.obex"
file="/system/framework/javax.obex.jar"/>

</permissions>




Sent from my GT-I9505G using Tapatalk

Are you sure about this? I think this is wrong and that the platform.xml file does not have that line in 4.4
 

wilbarger

Senior Member
Aug 8, 2012
692
416
USA
Maybe since I did not use your file on 4.3 and did the text edit of the file instead, it didn't carry forward when I upgraded. I do know that when I flashed your file, it changed the statement to "media" instead of <group gid="sdcard_r" />.

Here is what I now have <permission name="android.permission.WRITE_EXTERNAL_STORAGE" >
<group gid="sdcard_rw" />
<groud gid="media_rw" />
</permission>

Just to clarify, you can create a new folder on the SD card without the "media" statement??
 

Top Liked Posts

  • There are no posts matching your filters.
  • 9
    I am currently working on a solution to fix 4.4 with more stable results.

    I have created a flashable zip that works in an aftermarket recovery. It replaces the platform.xml file with modified file that has the necessary permission line to make the sd card writable now. That is the only thing changed. I added the under WRITE_EXTERNAL_STORAGE.

    You need to be on a custom recovery. This update only applies to I9505G. If you do not have an S4 GOOGLE EDITION PHONE, then please disregard and move on.

    Warning; You are flashing this at your own risk. I am not responsible for broken devices, deleted memory cards, phones thrown from raging, or WW3.

    Download the flashable from here: http://d-h.st/Eif

    Download the modified platform.xml to replace the original from here if you would rather push it: http://d-h.st/ooU
    (this is not needed with zip, already included)

    1. Place the zip the on your internal or external drive.
    2. Reboot to your custom recovery, ie ( twrp, cwm)
    3. Create a backup, have a restore point if it does not work.
    4. Wipe dalvik and cache
    5. Install the zip file
    6. Wipe the dalvik and cache just to be sure.
    7. Reboot phone.

    Test to make sure it worked by using any file explorer, ie(solid explorer, root explorer, etc.) and creating a new folder, text document, or whatever. Do this through the phone, not a p.c. If it does not work, reboot to recovery, restore back to previous point and let me know asap.
    2
    I have created a flashable zip that works in an aftermarket recovery. It replaces the platform.xml file with modified file that has the necessary permission line to make the sd card writable now. That is the only thing changed. I added the <group gid="media_rw"/> under WRITE_EXTERNAL_STORAGE.

    You need to be on a custom recovery. This update only applies to I9505G. If you do not have an S4 GOOGLE EDITION PHONE, then please disregard and move on. This is only for the MH1 4.3 firmware that does not allow you to write to the sdcard.

    Warning; You are flashing this at your own risk. I am not responsible for broken devices, deleted memory cards, phones thrown from raging, or WW3.

    Download the flashable from here: http://d-h.st/Eif

    Download the modified platform.xml to replace the original from here if you would rather push it: http://d-h.st/ooU
    (this is not needed with zip, already included)

    1. Place the zip the on your internal or external drive.
    2. Reboot to your custom recovery, ie ( twrp, cwm)
    3. Create a backup, have a restore point if it does not work.
    4. Wipe dalvik and cache
    5. Install the zip file
    6. Wipe the dalvik and cache just to be sure.
    7. Reboot phone.

    Test to make sure it worked by using any file explorer, ie(solid explorer, root explorer, etc.) and creating a new folder, text document, or whatever. Do this through the phone, not a p.c. If it does not work, reboot to recovery, restore back to previous point and let me know asap.

    You're welcome.

    http://xdaforums.com/showthread.php?p=44370296

    When dialog fails, it's time for violence.
    2
    That worked great, thank you!

    Sent from my GT-I9505G using Tapatalk 2

    Works well on 4.4 also.
    2
    Really I would have never thought of doing that. That's ground breaking. Extraordinary!

    Now do more research and you will see people have trouble writing to that file with root and trying a multitude of file explorers. And mounting system r/w. I still couldn't. Hence the links to the flashable in the op.

    So....


    Your welcome.

    Sent from my GT-I9505G using Tapatalk 4

    My sincere apologies. I'm having a bad day. I'm glad I could contribute to your work.

    When dialog fails, it's time for violence.
    1
    I like it

    Sent from my SGH-I317 using Tapatalk 2