title: Unable to open socket file: target process not responding or HotSpot VM not loaded
body: <p>I need to execute the following command from a web application deployed on <code>cloudfoundry</code>.</p>
  
  <pre><code>String javaHome = System.getenv("JAVA_HOME");
  String javaLocation = javaHome+"/bin/java";
  
  String command = javaLocation+" -Xms256m -Xmx512m -Dcom.sun.btrace.probeDescPath=. -Dcom.sun.btrace.dumpClasses=false -Dcom.sun.btrace.debug=false -Dcom.sun.btrace.unsafe=false -cp "+btraceLib+":"+toolsLib+ " com.sun.btrace.client.Main "+pid+" "+probeScript;
  
  Process p = runTime.exec(command);
  </code></pre>
  
  <p>But I get the following error:</p>
  
  <pre><code>Unable to open socket file: target process not responding or HotSpot VM not loaded
  </code></pre>
  
  <p>I tried with different bounds on heap-size for jvm but get the same error.</p>
  
  <p>How can I resolve the error? </p>