How to fix “A server is already running.” error in Ruby on Rails

Luckily this is an easy fix. You error message will more accurately say something along the lines of:

A server is already running. Check /home/greg/odin/spitter/tmp/pids/

If you run cat on the file referenced in the message, it will return a 5 digit number like 30351.

cat /home/greg/odin/spitter/tmp/pids/ returns the ID of the process.

30351 is the ID of the process running the current rails server. Run kill -9 30351 to end the process and free up room for a new server.

You are now free to run rails s to boot up the server.

Table of Contents