Access denied for user 'root'@'localhost' (using password: NO)

136 views
Skip to first unread message

Renato Viana

unread,
Nov 21, 2010, 9:25:38 AM11/21/10
to rubyonra...@googlegroups.com
I am getting this message after run: ruby script/server and click in
"About your application environment" in the browser.

--
Posted via http://www.ruby-forum.com/.

Distilling Rails

unread,
Nov 21, 2010, 9:28:10 AM11/21/10
to rubyonra...@googlegroups.com
I am getting this message when click in "About your application
environment"

--
Posted via http://www.ruby-forum.com/.

Hassan Schroeder

unread,
Nov 21, 2010, 9:36:47 AM11/21/10
to rubyonra...@googlegroups.com
On Sun, Nov 21, 2010 at 6:25 AM, Renato Viana <li...@ruby-forum.com> wrote:
> I am getting this message after run: ruby script/server and click in
> "About your application environment" in the browser.

You need to specify the appropriate username/password for your
database in config/database.yml .

Have you done any "getting started with Rails" tutorials?

--
Hassan Schroeder ------------------------ hassan.s...@gmail.com
twitter: @hassan

gezope

unread,
Nov 22, 2010, 8:35:03 AM11/22/10
to Ruby on Rails: Talk
Hello Renato,

Find the file yourapp/config/database.yaml, open it, and set it well.
You have to know your database username+password, if any. Any also the
database have to installed, and the database's gem also. Check it with
'mysql -v' and 'gem list m' or 'sqlite3 -v' and 'gem list sq', you
will see if something is missing, then istall it.

If you use ruby script/server instead of rails server, means that you
use Rails 2.3.X version ,and not the latest Rails 3. Chack your
versions: "ruby -v", "gem -v", "gem list", "rails -v".

It's a really good idea to update, since Rails 3 is completely
refactored and many new ideas in it, so if you study Rails 2, you will
need to restudy many things later. (sudo) "gem update"

Or the best solution: install RVM, version manager, so you can choose
which Ruby or Rails you wish to use.

Good luck,
Zoltán

pradeek k

unread,
Apr 17, 2012, 11:59:51 PM4/17/12
to rubyonra...@googlegroups.com
1.grant all privileges in mysql with your yaml database
2.add password to your yaml
3.if yaml parse error,check whether you didnt leave any space in between your password and password line column,if not put one space,it has to follow in all all lines.
for eg:password: your_password.
4.try rake db:migrate --trace

Greg Akins

unread,
Apr 18, 2012, 7:57:49 AM4/18/12
to rubyonra...@googlegroups.com
On Tue, Apr 17, 2012 at 11:59 PM, pradeek k <prad...@gmail.com> wrote:
> 1.grant all privileges in mysql with your yaml database
> 2.add password to your yaml
> 3.if yaml parse error,check whether you didnt leave any space in between
> your password and password line column,if not put one space,it has to follow
> in all all lines.
> for eg:password: your_password.
> 4.try rake db:migrate --trace
>

5. Check the date on the forum to make sure you didn't respond to a
year-old message.

> On Sunday, November 21, 2010 7:55:38 PM UTC+5:30, Ruby-Forum.com User wrote:
>>
>> I am getting this message after run: ruby script/server and click in
>> "About your application environment" in the browser.
>>
>> --
>> Posted via http://www.ruby-forum.com/.
>

> --
> You received this message because you are subscribed to the Google Groups
> "Ruby on Rails: Talk" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/rubyonrails-talk/-/vAzlxvrhwlwJ.
> To post to this group, send email to rubyonra...@googlegroups.com.
> To unsubscribe from this group, send email to
> rubyonrails-ta...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/rubyonrails-talk?hl=en.

--
Greg Akins
http://twitter.com/akinsgre

Charles A. Lopez

unread,
Apr 18, 2012, 8:22:43 AM4/18/12
to rubyonra...@googlegroups.com
sounds like a permission issue on MySQL.

if you have shell access, try getting on the SQL monitor with the username and password.



--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
Reply all
Reply to author
Forward
0 new messages