Ce code fonctionne très bien:python problème de connexion MySQL
import MySQLdb
db = MySQLdb.connect("localhost", "root", "","bullsorbit")
cursor = db.cursor()
cursor.execute("Select * from table where conditions'")
numrows = int(cursor.rowcount)
print 'Total number of Pages : %d ' % numrows
mais si je donne mon adresse IP
db = MySQLdb.connect("192.168.*.*", "root", "","bullsorbit")
il donnera cette erreur
super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.OperationalError: (2003, "Can't connect to MySQL server on 'ip address' (111)")
Votre serveur est configuré pour permettre à la racine de se connecter sur une connexion non-localhost? –