Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

spawn ENOENT error

I'm trying to upload stuff to amazon s3 with the imager module. I keep getting the error message that says,

events.js:72
    throw er; // Unhandled 'error' event
              ^
Error: spawn ENOENT
    at errnoException (child_process.js:980:11)
    at Process.ChildProcess._handle.onexit (child_process.js:771:34)

I've already installed imagemagick on my computer, but it keeps saying it's unlinked, could this be the problem? I also tried linking using brew link imagemagick, but it's unable to link for some reason. I'm using OSx. Any fixes?

Thanks.

like image 904
jensiepoo Avatar asked Jul 30 '13 15:07

jensiepoo


People also ask

What does Enoent mean?

It's an abbreviation of Error NO ENTry (or Error NO ENTity), and can actually be used for more than files/directories.

How do you spawn in node JS?

The spawn function launches a command in a new process and we can use it to pass that command any arguments. For example, here's code to spawn a new process that will execute the pwd command. const { spawn } = require('child_process'); const child = spawn('pwd');

What is child process Nodejs?

Usually, Node. js allows single-threaded, non-blocking performance but running a single thread in a CPU cannot handle increasing workload hence the child_process module can be used to spawn child processes. The child processes communicate with each other using a built-in messaging system.


2 Answers

Please make sure the ImageMagick exe is included as part of PATH environment variable.

like image 147
Chandu Avatar answered Oct 15 '22 00:10

Chandu


Simply works on Ubuntu:

sudo apt-get install imagemagick
like image 33
Manwal Avatar answered Oct 14 '22 23:10

Manwal