title: Error :Unable to open trace file '/mnt/sdcard/method.trace': Permission denied in android 3.0
body: <p>I am facing problem while creating trace file using </p>
  
  <pre><code>Debug.startMethodTracing("traceFile");   
  </code></pre>
  
  <p>I have also added</p>
  
  <pre><code>&lt;uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /&gt;
  </code></pre>
  
  <p>in manifest file
  But when I am trying to run the application I am getting this error</p>
  
  <pre><code>01-13 10:53:32.739: D/dalvikvm(1261): +++ active profiler count now 1
  01-13 10:53:32.739: I/dalvikvm(1261): TRACE STARTED: '/mnt/sdcard/traceFile.trace' 8192KB
  01-13 10:53:32.739: E/dalvikvm(1261): Unable to open trace file '/mnt/sdcard/traceFile.trace': Permission denied
  01-13 10:53:32.739: D/dalvikvm(1261): +++ active profiler count now 0
  01-13 10:53:32.950: D/AndroidRuntime(1261): Shutting down VM
  01-13 10:53:32.950: W/dalvikvm(1261): threadid=1: thread exiting with uncaught exception (group=0x40014760)
  01-13 10:53:33.070: E/AndroidRuntime(1261): FATAL EXCEPTION: main
  01-13 10:53:33.070: E/AndroidRuntime(1261): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.sample.internetTV/com.sample.internetTV.Internet_TV4}: java.lang.RuntimeException: Unable to open trace file '/mnt/sdcard/traceFile.trace': Permission denied
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1736)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1752)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread.access$1500(ActivityThread.java:123)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:993)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.os.Handler.dispatchMessage(Handler.java:99)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.os.Looper.loop(Looper.java:126)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread.main(ActivityThread.java:3997)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at java.lang.reflect.Method.invokeNative(Native Method)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at java.lang.reflect.Method.invoke(Method.java:491)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:841)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:599)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at dalvik.system.NativeStart.main(Native Method)
  01-13 10:53:33.070: E/AndroidRuntime(1261): Caused by: java.lang.RuntimeException: Unable to open trace file '/mnt/sdcard/traceFile.trace': Permission denied
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at dalvik.system.VMDebug.startMethodTracingNative(Native Method)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at dalvik.system.VMDebug.startMethodTracing(VMDebug.java:175)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.os.Debug.startMethodTracing(Debug.java:458)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.os.Debug.startMethodTracing(Debug.java:406)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at com.sample.internetTV.Internet_TV4.onCreate(Internet_TV4.java:37)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1048)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1700)
  01-13 10:53:33.070: E/AndroidRuntime(1261):     ... 11 more
  </code></pre>
  
  <p>This was working fine in Android 2.2 version. But In Android 3.0 I am getting error
  So can anybody please help me to solve this problem.</p>
  
  <p>Thanks in Advance</p>