Problem in Installation Step 4

Added by zz Su over 11 years ago

4. Create the database structure, by running the following command under the application root directory:
rake db:migrate RAILS_ENV="production"

----------------------------------------------------------------
C:\redmine-0.8.0>rake db:migrate RAILS_ENV="production"
(in C:/redmine-0.8.0)
rake aborted!
Access denied for user 'bduser'@'localhost' (using password: YES)

(See full trace by running task with --trace)

C:\redmine-0.8.0>
----------------------------------------------------------------
C:\redmine-0.8.0>rake db:migrate RAILS_ENV="production" --trace
(in C:/redmine-0.8.0)
  • Invoke db:migrate (first_time)
  • Invoke environment (first_time)
  • Execute environment
  • Execute db:migrate
    rake aborted!
    Access denied for user 'bduser'@'localhost' (using password: YES)
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /mysql_adapter.rb:527:in `real_connect'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /mysql_adapter.rb:527:in `connect'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /mysql_adapter.rb:186:in `initialize'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /mysql_adapter.rb:85:in `new'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /mysql_adapter.rb:85:in `mysql_connection'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /abstract/connection_specification.rb:292:in `send'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /abstract/connection_specification.rb:292:in `connection='
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /abstract/connection_specification.rb:260:in `retrieve_connection'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/connection_adapters
    /abstract/connection_specification.rb:78:in `connection'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/migration.rb:408:in
    `initialize'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/migration.rb:373:in
    `new'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/migration.rb:373:in
    `up'
    C:/redmine-0.8.0/vendor/rails/activerecord/lib/active_record/migration.rb:356:in
    `migrate'
    C:/redmine-0.8.0/vendor/rails/railties/lib/tasks/databases.rake:99
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in `call'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:546:in `execute'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in `each'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:541:in `execute'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:508:in `invoke_with_call_c
    hain'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in `synchronize'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:501:in `invoke_with_call_c
    hain'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:494:in `invoke'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1931:in `invoke_task'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in `top_level'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in `each'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1909:in `top_level'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in `standard_exceptio
    n_handling'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1903:in `top_level'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1881:in `run'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1948:in `standard_exceptio
    n_handling'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/lib/rake.rb:1878:in `run'
    C:/Ruby/lib/ruby/gems/1.8/gems/rake-0.8.1/bin/rake:31
    C:/Ruby/bin/rake:19:in `load'
    C:/Ruby/bin/rake:19

C:\redmine-0.8.0>
-----------------------------------------------------------------------------
windows xp
MySQL Server 5.1
Ruby-186-27

Replies (2)

RE: Problem in Installation Step 4 - Added by Brad Beattie over 11 years ago

Access denied for user 'bduser'@'localhost' (using password: YES)

Your username/password aren't accepted for your database. The problem isn't with Redmine; It's either the values you put in to your configuration of database.yml or your bduser doesn't have access to that schema.

RE: Problem in Installation Step 4 - Added by zz Su over 11 years ago

I thought "bduser" and "bdpasswd" are the username and password, what a stupid mistake.

Now I change it to the actual username and password of the database, and then I get:

C:\redmine-0.8.0>rake db:migrate RAILS_ENV="production"
(in C:/redmine-0.8.0)
1 Setup: migrating =======================================================
-- create_table("attachments", {:force=>true})
rake aborted!
undefined method `each' for #<Mysql:0x46bbb0c>

(See full trace by running task with --trace)

C:\redmine-0.8.0>
------------------------------------------------------------------------------
I google the web to find a solution posted by another user, that is to roll back mysql5.1 to mysql5.0, now it works properly.

Thanks for your kindly reply.

(1-2/2)