Re: MySQL via SSH Tunnel
- From: Frank Schenk <frank@xxxxxxxxxxx>
- Date: Tue, 23 May 2006 18:44:24 +0200
Andreas Stallmann wrote:
Hallo zusammen,....
ich versuche - einigermaßen verzweifelt - MySQL über eine SSH-Verbindung zu betreiben.
Versuche ich aber einen Verbindungsaufbau via mysql, scheitert dies:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LC ~ # mysql -u root -P 3307 localhost
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (111)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Der Socket existiert. Wenn ihn lösche, ist die Fehlermeldung allerdings die selbe.
Wenn ich nicht ganz falsch liege connected sich MySQL immer über den mysqld.sock wenn du als Host localhost angibst. Gib ihm ne IP, dann sollte er sich über TCP/IP verbinden.
Steht aber auch alles im Handbuch:
A.2.2. Can't connect to [local] MySQL server
http://dev.mysql.com/doc/refman/4.1/en/can-not-connect-to-server.html
A MySQL client on Unix can connect to the mysqld server in two different ways: By using a Unix socket file to connect through a file in the filesystem (default /tmp/mysql.sock), or by using TCP/IP, which connects through a port number. A Unix socket file connection is faster than TCP/IP, but can be used only when connecting to a server on the same computer. A Unix socket file is used if you don't specify a hostname or if you specify the special hostname localhost.
gruß, Frank
.
- References:
- MySQL via SSH Tunnel
- From: Andreas Stallmann
- MySQL via SSH Tunnel
- Prev by Date: MySQL via SSH Tunnel
- Next by Date: Migration von MyISAM nach InnoDB
- Previous by thread: MySQL via SSH Tunnel
- Next by thread: Re: MySQL via SSH Tunnel
- Index(es):
Relevant Pages
|
|