This seems like it would be a common problem, but I just can't seem to find the solution through google searches, etc.
I just created a new Rails 3.2.6 application and configured it to use the PostgreSQL database for my local development. I followed this RailsCast and was able to get everything installed and set up correctly.
However, whenever I try to do any rails generate or rake commands (rails generate model
, rake db:migrate
etc), I get the following error referring to my development.log
file:
Rails Error: Unable to access log file. Please ensure that /Users/****/projects/rails_projects/rails_app/log/development.log exists and is chmod 0666. The log level has been raised to WARN and the output directed to STDERR until the problem is fixed.
I see these other stackoverflow questions/answers, but they don't fit my case exactly:
- Rails: Unable to access log file <- This is back in the days of Rails 2.2
- Ruby on Rails Setup: Unable to access log file <- This is regarding a production environment using Apache. I am on a local development environment.
Other than that error, my application runs fine. Also, if I create a new rails application with all its defaults, I don't get this error.
Any suggestions/hints would be much appreciated. Or if you need any more information about my local environment, please let me know.