title: [help]ActiveRecord::ConnectionNotEstablished
body: <p>my rails environment is</p>
  
  <p>Rails: 3.2.14,</p>
  
  <p>ruby: 1.9.3,</p>
  
  <p>system: ubuntu</p>
  
  <p>mysql: 5.5.32-0ubuntu0.12.04.1</p>
  
  <p>I create a mysql database,and to test the database, I connect It from my mysql workbench in windows.so, I want to show that,my mysql database in ubuntu is run correctly</p>
  
  <p>but ,when I run the website in browser , I get the error: activerecord::connectionnotestablished . </p>
  
  <p>the full trace is:
  <code></p>
  
  <p>activerecord (3.2.14) lib/active_record/connection_adapters/abstract/connection_pool.rb:410:in <code>retrieve_connection'
  activerecord (3.2.14) lib/active_record/connection_adapters/abstract/connection_specification.rb:171:in</code>retrieve_connection'
  activerecord (3.2.14) lib/active_record/connection_adapters/abstract/connection_specification.rb:145:in <code>connection'
  activerecord (3.2.14) lib/active_record/query_cache.rb:67:in</code>rescue in call'
  activerecord (3.2.14) lib/active_record/query_cache.rb:61:in <code>call'
  activerecord (3.2.14) lib/active_record/connection_adapters/abstract/connection_pool.rb:479:in</code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/callbacks.rb:28:in <code>block in call'
  activesupport (3.2.14) lib/active_support/callbacks.rb:405:in</code><em>run</em>_72338529_<em>call</em>_445636797__callbacks'
  activesupport (3.2.14) lib/active_support/callbacks.rb:405:in <code>__run_callback'
  activesupport (3.2.14) lib/active_support/callbacks.rb:385:in</code>_run_call_callbacks'
  activesupport (3.2.14) lib/active_support/callbacks.rb:81:in <code>run_callbacks'
  actionpack (3.2.14) lib/action_dispatch/middleware/callbacks.rb:27:in</code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/reloader.rb:65:in <code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/remote_ip.rb:31:in</code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/debug_exceptions.rb:16:in <code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/show_exceptions.rb:56:in</code>call'
  railties (3.2.14) lib/rails/rack/logger.rb:32:in <code>call_app'
  railties (3.2.14) lib/rails/rack/logger.rb:16:in</code>block in call'
  activesupport (3.2.14) lib/active_support/tagged_logging.rb:22:in <code>tagged'
  railties (3.2.14) lib/rails/rack/logger.rb:16:in</code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/request_id.rb:22:in <code>call'
  rack (1.4.5) lib/rack/methodoverride.rb:21:in</code>call'
  rack (1.4.5) lib/rack/runtime.rb:17:in <code>call'
  activesupport (3.2.14) lib/active_support/cache/strategy/local_cache.rb:72:in</code>call'
  rack (1.4.5) lib/rack/lock.rb:15:in <code>call'
  actionpack (3.2.14) lib/action_dispatch/middleware/static.rb:63:in</code>call'
  railties (3.2.14) lib/rails/engine.rb:484:in <code>call'
  railties (3.2.14) lib/rails/application.rb:231:in</code>call'
  rack (1.4.5) lib/rack/content_length.rb:14:in <code>call'
  railties (3.2.14) lib/rails/rack/log_tailer.rb:17:in</code>call'
  rack (1.4.5) lib/rack/handler/webrick.rb:59:in <code>service'
  /home/hxh/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/httpserver.rb:138:in</code>service'
  /home/hxh/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/httpserver.rb:94:in <code>run'
  /home/hxh/.rvm/rubies/ruby-1.9.3-p448/lib/ruby/1.9.1/webrick/server.rb:191:in</code>block in start_thread'
  </code></p>
  
  <p>my <code>database.yml</code> is:
  </p>
  
  <pre><code>development:
    adapter: mysql2
    encoding: utf8
    reconnect: false
    database: r4rmusic_development
    pool: 5
    username: root
    password:123 
    host:127.0.0.1
    socket: /var/run/mysqld/mysqld.sock
  </code></pre>
  
  <p>my <code>Gemfile</code> is:
  </p>
  
  <pre><code>source 'https://rubygems.org'
  gem 'rails', '3.2.14'
  gem 'mysql2'
  
  group :assets do
    gem 'sass-rails',   '~&gt; 3.2.3'
    gem 'coffee-rails', '~&gt; 3.2.1' 
  
    gem 'uglifier', '&gt;= 1.0.3'
  end
  
  gem 'jquery-rails'
  </code></pre>
  
  <p>please help me</p>