Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MySQL access error #36

Open
bennyzr opened this issue Jan 30, 2017 · 0 comments
Open

MySQL access error #36

bennyzr opened this issue Jan 30, 2017 · 0 comments

Comments

@bennyzr
Copy link

bennyzr commented Jan 30, 2017

The script generates errors when trying to access MySQL.

At the step:
Okay to drop all existing databases named rails-devise-pundit? 'No' will abort immediately! (y/n) y

run bundle exec rake db:drop from "."
[Simple Form] Simple Form is not configured in the application and will use the default values. Use rails generate simple_form:install to generate the Simple Form configuration.
rake aborted!
Mysql2::Error: Access denied for user 'rails-devise-pundit'@'localhost' (using password: NO)
/home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in load' /home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in

'
Tasks: TOP => db:drop => db:check_protected_environments
(See full trace by running task with --trace)
run bundle exec rake db:create:all from "."
Access denied for user 'rails-devise-pundit'@'localhost' (using password: NO)Please provide the root password for your MySQL installation


Mysql2::Error: No database selected: GRANT ALL PRIVILEGES ON rails-devise-pundit_development.* TO 'rails-devise-pundit'@'localhost' IDENTIFIED BY '' WITH GRANT OPTION;
Couldn't create database for {"adapter"=>"mysql2", "encoding"=>"utf8", "reconnect"=>false, "database"=>"rails-devise-pundit_development", "pool"=>5, "username"=>"rails-devise-pundit", "password"=>nil, "host"=>"localhost"}
rake aborted!
ActiveRecord::StatementInvalid: Mysql2::Error: No database selected: GRANT ALL PRIVILEGES ON rails-devise-pundit_development.* TO 'rails-devise-pundit'@'localhost' IDENTIFIED BY '' WITH GRANT OPTION;
/home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in load' /home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in

'
Mysql2::Error: No database selected
/home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in load' /home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in '
Mysql2::Error: Access denied for user 'rails-devise-pundit'@'localhost' (using password: NO)
/home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in load' /home/benny/.rbenv/versions/2.3.1/bin/bundle:22:in '
Tasks: TOP => db:create:all
(See full trace by running task with --trace)

All subsequent commands to the database fail as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant