wood burning stoves 2.0
The moose likes Linux / UNIX and the fly likes mysql Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "mysql" Watch "mysql" New topic


Ranch Hand

Joined: Nov 23, 2000
Posts: 67
I installed mysql when Linux operating system is installed.
And i write a c++ database connectivity program.
When I give mysqladmin status in the command prompt
I got an error: Cann't connect to local MySQL server through socket /var/lib/mysql.sock(111).
Pls give me a solution for this...
Guy Allard
Ranch Hand

Joined: Nov 24, 2000
Posts: 776
Have you set up the mySQL userid(s) and Passwords? That is a usual problem.
See: http://www.mysql.com/doc/A/c/Access_denied.html
This is totally different that 'normal Unix' login ID's/PW's. MySql ID's can (but do not have to) be the same as the Unix userid. Passwords can also be different.
Additionally, GRANT's probably need to be issued via mySQL root to allow particular mySQL users to access particular DB resources without interactively specifying a password.
Make sure you can access the DB/tables from the command line before you try C++ access.
RTFM at www.mysql.com.
Regards, Guy
I agree. Here's the link: http://aspose.com/file-tools
subject: mysql
It's not a secret anymore!