I have rooted a B&N Nook Glowlight running Android 2.1. The device does not come with an SD card, so I symlinked to another directory from /sdcard/. Now I need to set the Environment.getExternalStorageState() value so that apps will be able to find the "card". How does one set this value?

Note that other devices, such as the Nexus S, also do not have an SD Card, yet they do return a Environment.getExternalStorageState() value for applications that require it.

Note that I am not writing an Android application which uses this value. I need to set this value device-wide so that other applications (such as Anki and Opera will be able to find it.

1 Answer 1


The source for eclair's Environment.getExternalStorageState() is here. It looks like getExternalStorageState() comes to this:

return SystemProperties.get("EXTERNAL_STORAGE_STATE", MEDIA_REMOVED)

I think you want to take a look at the /system/build.prop file and check for a line like:


If it's there, try changing it to:


To do this, adb pull /system/build.prop, modify the file on your computer, then adb remount to make /system writable (or adb shell, su, mount -o rw,remount /system)... then exit back to your computer and adb push build.prop /system/build.prop to push the modified file to /system). Then reboot.

You can try temporarily (from root shell):


...if that works, you might then programmatically try:

SystemProperties.set("EXTERNAL_STORAGE_STATE", Environment.MEDIA_MOUNTED);

Hope this works out for ya.

  • Thank you! I am able to temporarily set the external storage as mounted via setprop EXTERNAL_STORAGE_STATE mounted. I'm trying to get the ADB working to set it permanently. Thank you!
    – dotancohen
    Oct 27, 2014 at 19:54
  • Glad it worked :)
    – fattire
    Oct 28, 2014 at 22:30
  • Yes, thank you! I still haven't resolved the entire issue, as this is a rooted B&N nook running Android 2.1, but you've put me on the right track.
    – dotancohen
    Oct 29, 2014 at 5:03

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .