Advertisement
Guest User

Untitled

a guest
Sep 27th, 2017
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. with SSHTunnelForwarder(
  2. ('server.pt', 9922),
  3. ssh_password="pass_ssh",
  4. ssh_username="user_ssh",
  5. remote_bind_address=('localhost', 3306)) as server:
  6. myDB = pw.MySQLDatabase("dbname", user="db_user", passwd="db_pass")
  7.  
  8. OperationalError: (2003, "Can't connect to MySQL server on 'localhost' ([Errno 111] Connection refused)")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement