MySQL Connection over network
I'm entering the below at the command prompt of my machine in an attempt to connect to mysql on another machine but I get a message saying "Can't connect to MySQL server on '192.168.0.1 '"
Can someone give me some pointer on how to connect. Thanks.
Code:
mysql -h 192.168.0.1 -u root -p
Re: MySQL Connection over network
i think its a user previledge issue. user root run only in a localhost where mysql installed, that if you dont change anything in the user right.
Re: MySQL Connection over network
Double check and make sure you can even ping
Re: MySQL Connection over network
hi,
here is connection strings for MySql
ODBC
o ODBC 2.50 Local database:
"Driver={mySQL};Server=localhost;Option=16834;Database=mydatabase;"
o ODBC 2.50 Remote database:
"Driver={mySQL};Server=data.domain.com;Port=3306;Option=131072;Stmt=;Database=my-database;Uid=username;Pwd=password;"
o ODBC 3.51 Local database:
"DRIVER={MySQL ODBC 3.51 Driver};SERVER=localhost;DATABASE=myDatabase;USER=myUsername;PASSWORD=myPassword;OPTION=3;"
o ODBC 3.51 Remote database:
"DRIVER={MySQL ODBC 3.51 Driver};SERVER=data.domain.com;PORT=3306;DATABASE=myDatabase; USER=myUsername;PASSWORD=myPassword;OPTION=3;"
• OLE DB, OleDbConnection (.NET)
o Standard:
"Provider=MySQLProv;Data Source=mydb;User Id=UserName;Password=asdasd;"
• MySqlConnection (.NET)
o eInfoDesigns.dbProvider:
"Data Source=server;Database=mydb;User ID=username;Password=pwd;Command Logging=false"
This one is used with eInfoDesigns dbProvider, an add-on to .NET
Re: MySQL Connection over network
Thanks popskie (and others). I have setup another user with full privileges but I keep getting a message saying "Can't connect to MySQL server on '192.168.0.1'"
Any other suggestions?
How do others check the data in their mysql databases over a network? I don't want to have to go to the server machine each time I want to check some data has been added/saved etc....