0

I have did all the procedures as mentioned in several places and I also learned from lynda.com video tutorial. I used Mac 10.7 and I installed rubystack. I created the databases, add and checked the database.yml here is you can see it again.

development:
  adapter: mysql2
  encoding: utf8
  reconnect: false
  host: localhost
  database: simplecmsdevelopment
  pool: 5
  username: simple_cms
  password: maiwandj
  socket: /tmp/mysql.sock

Therefore, when I run rake db:schema:dump it print the following errors

bash-3.2$ rake db:schema:dump
/Applications/rubystack-1.9.3-18/ruby/lib/ruby/gems/1.9.1/gems/bundler-1.5.2/lib/bundler/runtime.rb:220: warning: Insecure world writable dir /usr/local/bin in PATH, mode 040777
rake aborted!
Access denied for user 'simplecms'@'localhost' (using password: YES)
/Applications/rubystack-1.9.3-18/simplecms/config/environment.rb:5:in `' Tasks: TOP => db:schema:dump => environment (See full trace by running task with --trace)

3 Answers 3

1

Have you granted permissions for that user on that database? i.e., GRANT ALL PRIVILEGES ON simplecmsdevelopment.* TO simple_cms@localhost;

Sign up to request clarification or add additional context in comments.

1 Comment

Yes, I have done the "GRANT ALL PRIVILEGES" but I received the same error.
0

You'll want to grant permissions on the simplecmsdevelopment database for simple_cms@localhost:

GRANT ALL PRIVILEGES ON 'simplecmsdevelopment'.* TO 'simple_cms'@'localhost';

You might want to change the directory permissions to something like 755 for /usr/local/bin as well... That should fix the warning.

3 Comments

Yes, I have done the "GRANT ALL PRIVILEGES" but I received the same error.
Check your database.yml, did you username "simplecms" instead of "simple_cms" somewhere? Error message displays the first, whereas your database.yml sniplet shows the latter.
No, it is correct, but let me tell you that when I create my rails project and I also created mysql database, but when I checked the file database.yml, there was no changed. The username was root, but I granted the simple_cms username.
0

DB yml Config file mentions username: simple_cms, but error message in console mentions user 'simplecms'@'localhost'.... I would suggest you should rewrite db yml configurations. I guess you might be having wrong username 'simplecms' written for test environment.... most probably.... do check...

1 Comment

No, it was mistaken by the editor, but the original error is the same as simple_cms@localhost.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.