Grunt Serve | connect:livereload Port 9000 already in use
Asked Answered
S

1

6

I've used Yeoman to build an angular application using bower and grunt. Running grunt serve gives me this error:

Running "connect:livereload" (connect) task
Fatal error: Port 9000 is already in use by another process.

I have another process using port 9000 so I would like to just change the port for Grunt. I've tried to change the port in my Gruntfile, but I continue to get the same error. Here is the grunt sever settings from Gruntfile.js

 connect: {
     options: {
        port: 9002,
        hostname: 'localhost',
        livereload: 35729
  },
Slime answered 8/10, 2015 at 14:18 Comment(0)
A
10

Find the process id that is using the port:

sudo lsof -i :3000

Kill it:

kill -9 <PID>
Argumentation answered 1/10, 2016 at 19:12 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.