title: node and or npm issue
body: <p>I am having various permission and or path issues with some npm packages, this time being deployd's dpd binary.  However it still seems related to pretty much any other familiar frustrating npm path issue that i receive now and then. Its pretty much a familiar face of npm usage it seems, given my constant use of -g, and not, when installing npm packs..</p>
  
  <p>So far to resolve it I tried reinstalling deployd and mongodb many times from user and globally, i have even reinstalled npm.   im getting consistent package errors when running dpd.  I found lots related, but none that have worked.  Here is my issue when running dpd today.  Any grand suggestions?</p>
  
  <p>When ran from linux i the following 
      $ dpd
      starting deployd v0.8.4...
      Failed to start MongoDB (Make sure 'mongod' are in your $PATH or use dpd --mongod option. Ref: <a href="http://docs.deployd.com/docs/basics/cli.html" rel="nofollow">http://docs.deployd.com/docs/basics/cli.html</a>)
      bye</p>
  
  <pre><code>$ sudo dpd
  starting deployd v0.8.4...
  Failed to start MongoDB (Make sure 'mongod' are in your $PATH or use dpd --mongod option. Ref: http://docs.deployd.com/docs/basics/cli.html)
  bye
  
      $ dpd --mongod ./.dpd/pids
      starting deployd v0.8.4...
      child_process.js:1162
          throw errnoException(err, 'spawn');
                ^
      Error: spawn EACCES
          at exports._errnoException (util.js:746:11)
          at ChildProcess.spawn (child_process.js:1162:11)
          at exports.spawn (child_process.js:995:9)
          at Object.exports.restart (/usr/bin/node_modules/bin/lib/node_modules/deployd/lib/util/mongod.js:38:14)
          at start (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:149:16)
          at Object.&lt;anonymous&gt; (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:280:31)
          at Module._compile (module.js:460:26)
          at Object.Module._extensions..js (module.js:478:10)
          at Module.load (module.js:355:32)
          at Function.Module._load (module.js:310:12)
          at Function.Module.runMain (module.js:501:10)
          at startup (node.js:129:16)
          at node.js:814:3
  </code></pre>
  
  <p>even if i run it sudo i get the same error. </p>
  
  <pre><code>$ sudo dpd --mongod ./.dpd/pids
  starting deployd v0.8.4...
  child_process.js:1162
      throw errnoException(err, 'spawn');
            ^
  Error: spawn EACCES
      at exports._errnoException (util.js:746:11)
      at ChildProcess.spawn (child_process.js:1162:11)
      at exports.spawn (child_process.js:995:9)
      at Object.exports.restart (/usr/bin/node_modules/bin/lib/node_modules/deployd/lib/util/mongod.js:38:14)
      at start (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:149:16)
      at Object.&lt;anonymous&gt; (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:280:31)
      at Module._compile (module.js:460:26)
      at Object.Module._extensions..js (module.js:478:10)
      at Module.load (module.js:355:32)
      at Function.Module._load (module.js:310:12)
      at Function.Module.runMain (module.js:501:10)
      at startup (node.js:129:16)
      at node.js:814:3
  </code></pre>
  
  <p>When ran from windows on a samba share mapped network drive i get this</p>
  
  <pre><code>dpd &gt; fs: missing callback Error: EPERM, open 'C:\Program Files (x86)\Deployd\node_modules\deployd\.latestversion'
  </code></pre>
  
  <p>what am i doing wrong here?</p>
  
  <p>I cannot find this file, nor this line of code anywhere, 
  child_process.js:1162
          throw errnoException(err, 'spawn');
  when i grep for it, one reference does turn up for the line of code, that's /bin/node, and when i open it in vim, it looks encrypted... i think ill look again, and that line may be there... hmm.</p>
  
  <p>ok i did find that line in node binary itself, </p>
  
  <pre><code>this.spawnfile = options.file;
  
    var err = this._handle.spawn(options);
  
    // Run-time errors should emit an error, not throw an exception.   if (err === uv.UV_EAGAIN ||
        err === uv.UV_EMFILE ||
        err === uv.UV_ENFILE ||
        err === uv.UV_ENOENT) {
      process.nextTick(function() {
        self._handle.onexit(err);
      });
      // There is no point in continuing when we've hit EMFILE or ENFILE
      // because we won't be able to set up the stdio file descriptors.
      // It's kind of silly that the de facto spec for ENOENT (the test suite)
      // mandates that stdio _is_ set up, even if there is no process on the
      // receiving end, but it is what it is.
      if (err !== uv.UV_ENOENT) return err;   } else if (err) {
      // Close all opened fds on error
      stdio.forEach(function(stdio) {
        if (stdio.type === 'pipe') {
          stdio.handle.close();
        }
      });
  
      this._handle.close();
      this._handle = null;
      throw errnoException(err, 'spawn');   }
  </code></pre>
  
  <p>is this some kind of crazy permission error?  i think i set at 755 to all files, and dirs when ran as user as well.. no selinux installed, might have some facls... doubt it, in this dir..</p>
  
  <p>I reinstalled npm and nodejs, and didnt help.  This is on an arch  linux box. </p>
  
  <p><strong>Edit</strong>: yeah that's not working either for some reason, even after i resolved the other one by correcting permission issues.</p>
  
  <pre><code>$ dpd -d --mongod /usr/bin/node_modules/bin/lib/node_modules
  starting deployd v0.8.4...
  deployd v0.8.5 is available.
  
  child_process.js:1162
      throw errnoException(err, 'spawn');
            ^
  Error: spawn EACCES
      at exports._errnoException (util.js:746:11)
      at ChildProcess.spawn (child_process.js:1162:11)
      at exports.spawn (child_process.js:995:9)
      at Object.exports.restart (/usr/bin/node_modules/bin/lib/node_modules/deployd/lib/util/mongod.js:38:14)
      at start (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:149:16)
      at Object.&lt;anonymous&gt; (/usr/bin/node_modules/bin/lib/node_modules/deployd/bin/dpd:280:31)
      at Module._compile (module.js:460:26)
      at Object.Module._extensions..js (module.js:478:10)
      at Module.load (module.js:355:32)
      at Function.Module._load (module.js:310:12)
      at Function.Module.runMain (module.js:501:10)
      at startup (node.js:129:16)
      at node.js:814:3
  </code></pre>