rails server bin/rails:6: warning: already initialized constant APP_PATH error

I couldn't find the an_initilizer.rb in my directory and I tried uninstalling/installing the spring gem but it didn't work.

However I did managed to finally get it working.

Apparently there is some conflict with spring and rails 4+.

I needed to run:

rake rails:update:bin 

But I ran across another error:

Library not loaded: libmysqlclient.18.dylib

I ran the following command which I found on another stackoverflow post:

sudo ln -s /usr/local/mysql/lib/libmysqlclient.18.dylib /usr/lib/libmysqlclient.18.dylib 

Then ran the original command:

 rake rails:update:bin 

Then run the server command:

 rails s

And now my WebBrick Server is running.


rake rails:update:bin to the rescue.


If you are on El Capitan (OS X 10.11), Security Integrity Protection (SIP) will prevent linking into /usr/lib to fix mysql. Link it into /usr/local/lib instead:

sudo ln -s /usr/local/mysql/lib/libmysqlclient.18.dylib /usr/local/lib/libmysqlclient.18.dylib