MySql 'not allowed to connect to host...'

Hi,

I recently posted a question to the group about reporting out of RT. The
answer I got was that it would probably be best to pull my reports
directly out of the SQL tables and go around the interface. Alright,
sounds like a plan.

Unfortunately I seem to have encountered another problem;

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to connect
to this MySQL server

But wait, you say! That’s easy to fix, you need to allow the other host
to connect to the database! – Ah, but alas, I have done that. Allowed
hosts is set to % and allowed db’s is also set to %.

MySQL Documentation suggests that perhaps I am using a binary based
mysql distribution that was build with a different glibc that the one I
am currently using. It also suggests that I either upgrade my glibc or
recompile MySQL. Since this is a production server naturally I’m
hesistent to screw around with it.

Ideas/Suggestions/Pain Killers?

Fred
Fred.Purdue Fred.Purdue@Pobox.com
Patient #345788532
Nova Scotia Government Mental Facility
“You’re not crazy, you’re just tired of using Windows™”

Unfortunately I seem to have encountered another problem;

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to
connect to this MySQL server

No password?

But wait, you say! That’s easy to fix, you need to allow the other
host to connect to the database! – Ah, but alas, I have done that.
Allowed hosts is set to % and allowed db’s is also set to %.

If you modified the grant tables with “UPDATE users SET …” then you
also need to FLUSH PRIVILEGES.

(darren)

We must respect the other fellow’s religion, but only in the sense and
to the extent that we respect his theory that his wife is beautiful
and his children smart.
– H.L.Mencken

[snip]

Unfortunately I seem to have encountered another problem;

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to connect
to this MySQL server

Are you able to telnet to the port mysql is listening on (usu. 3306, iirc). Is
there a firewall that you need to poke a hole in?

$.02.

Dave Hull
Senior Information Technology Analyst
The University of Kansas
voice: (785) 864-0403 || fax: (785) 864-0485

[ Firstly, if you’re getting the list in digest form, please make sure
that you change the subject line to be relevant, and not that of the
digest number. This helps people following archives and doing
subject-based sorting ]

From: darren chamberlain

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to
connect to this MySQL server

No password?

If it was a password error I would be either be getting asked for a
password or I would get a bad password response.

Depending on which varient of the mysql client you have, you should get
either ‘blah blah is not allowed’ or ‘Access is denied for blah (using
password: NO)’.

Try snarfing the rt mysql username and password out of the config.pm file
and specifying them directly, eg:

$ mysql -u rt_user -p rt_pass -h db.host rt2

( 'rt_pass' can be absent, and MySQL will prompt you )

The MySQL access controls also limit by database requested, although if
you are connecting as the mysql root user (and failing), then you probably
have more serious problems.

You could also try connecting to ‘localhost’ instead of ‘helpdesk.blah’.

I not only flushed the privileges but I also restarted mysql.

Then you have mysql root (admin) access.

                          Bruce Campbell                       RIPE

@ Systems/Network Engineer NCC
IETF55 - Atlanta, GA, Some 1st World Country Operations/Security

From: darren chamberlain

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to
connect to this MySQL server

No password?

If it was a password error I would be either be getting asked for a
password or I would get a bad password response.

Depending on which varient of the mysql client you have, you should get
either ‘blah blah is not allowed’ or ‘Access is denied for blah (using
password: NO)’.

I was questioning the wisdom of an empty password, not suggesting that
might be the problem. That bit was commentary, not help. :slight_smile:

(darren)

The language Unix is vastly more inconsistent than the language Perl.
And guaranteed to remain that way, forever and ever, amen.
– Larry Wall

Actually, both machines are on the same network. Telnet’ing to 3306 returns
the same msgFrom: dphull@ku.edu [mailto:dphull@ku.edu]
Sent: Monday, November 18, 2002 2:29 PM
Cc: rt-users
Subject: Re: [rt-users] MySql ‘not allowed to connect to host…’

[snip]

Unfortunately I seem to have encountered another problem;

shell> mysql -h helpdesk.corp.newoppinc.org -u root
ERROR 1130: Host ‘helpdesk.corp.newoppinc.org’ is not allowed to connect
to this MySQL server

Are you able to telnet to the port mysql is listening on (usu. 3306, iirc).
Is
there a firewall that you need to poke a hole in?

$.02.

Dave Hull
Senior Information Technology Analyst
The University of Kansas
voice: (785) 864-0403 || fax: (785) 864-0485

rt-users mailing list
rt-users@lists.fsck.com
http://lists.fsck.com/mailman/listinfo/rt-users

Have you read the FAQ? The RT FAQ Manager lives at http://fsck.com/rtfm