Connecting the RevPi to a remote database

Topics about the Software of Revolution Pi
Post Reply
JeffCalgary
Posts: 10
Joined: 02 Apr 2019, 23:14
Answers: 0

Connecting the RevPi to a remote database

Post by JeffCalgary »

Hello,

I am trying to connect the RevPi to a remote database. I have run this code to connect to a local database and it works. I have also run it on a VM and it makes the connection. Here is the error message:

python main.py
Traceback (most recent call last):
File "main.py", line 9, in <module>
db = MySQLdb.connect(server, username0,password0)
File "/usr/lib/python2.7/dist-packages/MySQLdb/__init__.py", line 81, in Connect
return Connection(*args, **kwargs)
File "/usr/lib/python2.7/dist-packages/MySQLdb/connections.py", line 187, in __init__
super(Connection, self).__init__(*args, **kwargs2)
_mysql_exceptions.InterfaceError: (-1, 'error totally whack'

Any ideas?
Post Reply