Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Here is the technical description.

My laptop's config:

  • IP Adress:
  • MySQL Server 5.0 on port 3306
  • Operating System: Ubuntu
  • The database is in this machine

My friend's laptop config:

  • IP Adress:
  • MySQL Server 5.0 on port 3306
  • Operating System: Windows XP

Both are on a wireless LAN connected through a Belkin router ( I put this but its not working:

url = "jdbc:mysql://"

How can I configure things connect to this database?

share|improve this question

migrated from May 31 '12 at 21:26

This question came from our site for system and network administrators.

Questions about home networks and personal computers are off-topic per the faq – MDMarra May 31 '12 at 12:59

MySQL is a TCP protocol running on port 3306 by defauly, hence there is nothing special beyond ensure that you have enabled binding to a public IP address in the /etc/my.cnf file;

port            = 3306
bind-address            =

On the client you would need to install the jdbc drivers for MySQL;

For windows XP they can be downloaded from here;

For ubuntu, there are package version in the repository;

# aptitude search mysql | grep JDBC
p   libmysql-java                   - Java database (JDBC) driver for MySQL 

You can use any client, mysql provide a workbence tools product;

or you can use Libreoffice and their database connection to view the tables;

Or use a scripting language like php;

or even just the command line client;

$ mysql -h192.168.2.5 -uuserXXX -e "show databases;"
| Database           |
| information_schema | 
| badger1             | 
| cacti              | 
share|improve this answer
thank you very much for your answer. my friend can access to my database in windows xp but my goal is to access to ** his database in ubuntu**. i have windows xp – waelbk May 31 '12 at 13:03
how do you wish to access it?, is the database already running in Ubuntu, or do you need to install it? – Tom H May 31 '12 at 13:33
i found a solution thanks for your help – waelbk May 31 '12 at 19:18
$ mysql -u root -p Enter password: mysql> use mysql mysql> GRANT ALL ON . to root@'' IDENTIFIED BY 'your-root-password'; mysql> FLUSH PRIVILEGES; – waelbk May 31 '12 at 19:23

This might sound stupid but have you checked if your Ubuntu machine has its firewall running? That has tripped me up a few times on both Windows and Linux.

A quick check is to run: sudo iptables -L

Here is a how-to from the ubuntu site:

share|improve this answer

Have you configured remote access for your MySQL server ? If not, read this.

share|improve this answer

You must log in to answer this question.