Help answer threads with 0 replies.
Go Back > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Ubuntu This forum is for the discussion of Ubuntu Linux.


  Search this Thread
Old 08-25-2009, 09:40 AM   #1
LQ Newbie
Registered: Aug 2009
Posts: 2

Rep: Reputation: 0
Angry Permit an ODBC connection to my MYSQL database

I'm a new boy to Linux/Ubuntu and I've got a problem. I've setup a UBUNTU Workstation 8.04.2. (the reason for Workstation is the GUI). Installed all the updates.
Installed apache 2

I've got a backup of a database I've restored to this machine. I've successfully transfered the program and got it up and running.

I can see it from any pc using a web browser using its internal ip address

So now I want to access it via ODBC so that I can generate reports. I've got the correct ODBC driver installed on the windows PCs (It works fine accessing another UBUNTU server's DBase).

For the life of me I can't figure out how I tell the server to permit access??!!! I've surched everywhere. The MySQL site suggests:

$ CREATE USER (blah blah blah) in the /etc/mysql subdirectory

I've tried this but it doesn't recognise the "CREATE" command. Lord knows why.

I've also tried:
$ SHOW GRANTS for admin@localhost (this I believe should be a default) and the UBUNTU says it doesn't recognise the"SHOW" command and that I should

$ apt-get install nmh

Which I did do - with no success.

As you can see - I don't know what I'm doing. I'm trying hard but ignorance is definitely a no no with this OS!!! Anyone got any suggestions!!!
Old 08-25-2009, 10:26 AM   #2
Registered: Apr 2006
Location: Cambridge, UK
Distribution: Ubuntu Jaunty
Posts: 45

Rep: Reputation: 16
I'm no expert, and I'm sure others will give you better and fuller advice, but to kick off:

Those CREATE USER and SHOW GRANTS commands you found are mysql commands, not Ubuntu. So you need to go into mysql first with:

mysql -u user -p
where 'user' is your mysql username (or possibly 'root' if you haven't set up additional users).

When you are in mysql, remember to end mysql commands with a semi-colon or they won't execute.

Other things to check are whether there is a firewall (either on your Ubuntu server, or in a router on the network) blocking the MySql port which is 3306 as standard.

Also check if your /etc/hosts.allow and /etc/hosts.deny files are set up correctly and not stopping connections. You can Google these or

man hosts.allow
man hosts.deny
for more info.

Hope that's helpful for starters.
Old 08-27-2009, 08:26 AM   #3
LQ Newbie
Registered: Aug 2009
Posts: 2

Original Poster
Rep: Reputation: 0
Hi Ivanmaxx,

Thanks alot for that... You see!!! I didn't even realise that. I know what my MySQL username and password is so I'll go in and give it a try.

Thaks again.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Perl Mysql Database connection big Linux - Newbie 1 07-03-2009 12:41 AM
Permit number of connection from same user on SSH Panagiotis_IOA Linux - Networking 5 08-03-2007 09:55 AM
Slackware 11 + mysql 5.0.24 + OpenOffice 2.0.3 + ODBC connection bgeddy Slackware 6 01-29-2007 04:42 PM
MySQL ODBC driver fails when trying to add a DSN to MySQL banjoman Linux - Software 0 01-24-2005 09:59 AM
ODBC connection to MySQL darius Linux - Software 2 09-29-2003 06:40 PM > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 06:16 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration