<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: openssh port forwarding with mysql in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940769#M577229</link>
    <description>Jordan,&lt;BR /&gt;Can you post something in order to attribute a bunny , because the solution is in this thread, and it would be good to find it in the search engine !!!&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Benoit&lt;BR /&gt;____________&lt;BR /&gt;Amour, amour, quand tu nous tiens, on peut bien dire : "Adieu, prudence !" Jean De La Fontaine</description>
    <pubDate>Wed, 02 Apr 2003 11:56:52 GMT</pubDate>
    <dc:creator>benoit Bruckert</dc:creator>
    <dc:date>2003-04-02T11:56:52Z</dc:date>
    <item>
      <title>openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940765#M577225</link>
      <description>Hi,&lt;BR /&gt;My question isn't simple, and is not specific for HP-UX, network or security, it's more a mixture of all this !!&lt;BR /&gt;The goal :&lt;BR /&gt;Through a ssh client which is connecting to internet through a routeur (nat inside the routeur) and accessing a lan sshd server (through another nat + firewall), I would like that any workstation on the LAN can connect to a mysql database which is running on the ssh client host !!&lt;BR /&gt;And the ssh client connection isn't permanent !!!&lt;BR /&gt;&lt;BR /&gt;I succeded from the ssh client to forward local port 3306 (mysql listener) to the 3306 of the sshd server.&lt;BR /&gt;ssh -C -R 3306:localhost:3306 &lt;SSHD_IP&gt;&lt;BR /&gt;(-g doesn't seems to work on remote forwarding).&lt;BR /&gt;From this server I can connect to mysqld through the tunnel, but only if I'm using the host 127.0.0.1 :&lt;BR /&gt;i.e. mysql -h 127.0.0.1&lt;BR /&gt;THe tcp 3306 port on the sshd server isn't listening on the others interface.&lt;BR /&gt;First question :&lt;BR /&gt;Is there a tool to open to all interfaces a listener port ?&lt;BR /&gt;&lt;BR /&gt;Second step, &lt;BR /&gt;I try another ssh tunnel from the sshd server to itself, with local port forwarding this time :&lt;BR /&gt;ssh -L3307:&lt;SSH_IP&gt;:3306 127.0.0.1 -g&lt;BR /&gt;which doesn't make any error, and a new port (3307) is listening.&lt;BR /&gt;The trouble :&lt;BR /&gt;when I connect from a lan workstation to the sshd server through mysql client, on port 3307, I have this error :&lt;BR /&gt;ERROR 2013: Lost connection to MySQL server during query&lt;BR /&gt;I think that the first step worked (sent signal, but not the answer !!!).&lt;BR /&gt;ANd on the sshd server this message (from sshd : &lt;BR /&gt;channel 2: open failed : connect failed : Connection refused)&lt;BR /&gt;&lt;BR /&gt;Any idea ??&lt;BR /&gt;I try to install also an sshd on the other side (mysql server) which is working good (local forwarding this time) if I don't use a router but a direct connection to the ISP (on the mysql server side). But this solution isn't the one I prefer (changing Ip address of the mysql server !!!)&lt;BR /&gt;&lt;BR /&gt;If any body could give an advice on the way to solve it ?&lt;BR /&gt;regards&lt;BR /&gt;Benoit&lt;/SSH_IP&gt;&lt;/SSHD_IP&gt;</description>
      <pubDate>Tue, 01 Apr 2003 16:02:26 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940765#M577225</guid>
      <dc:creator>benoit Bruckert</dc:creator>
      <dc:date>2003-04-01T16:02:26Z</dc:date>
    </item>
    <item>
      <title>Re: openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940766#M577226</link>
      <description>&lt;BR /&gt;So -g is required and it only works with -L. This means the database host cannot be the ssh client.&lt;BR /&gt;&lt;BR /&gt;Let's switch who is local and remote. The clients are in the local network. The database is in the remote network. So from a client host, this ssh command should work:&lt;BR /&gt;&lt;BR /&gt;ssh -nfgNCL 3306:db_host:3306 sshd_host&lt;BR /&gt;&lt;BR /&gt;You say this connection is only temporary. Do you mean it should only be available during business hours? And it may only be established by you at the remote site?&lt;BR /&gt;&lt;BR /&gt;Let me think about this...&lt;BR /&gt;</description>
      <pubDate>Tue, 01 Apr 2003 17:53:12 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940766#M577226</guid>
      <dc:creator>Jordan Bean</dc:creator>
      <dc:date>2003-04-01T17:53:12Z</dc:date>
    </item>
    <item>
      <title>Re: openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940767#M577227</link>
      <description>Well, I tried this (sshd server on the same host as mysql database), with the -g...&lt;BR /&gt;The listener is working well, but I have the channel2 error !!!&lt;BR /&gt;But I would rather create a second tunnel  with sshd on the lan and a &lt;BR /&gt;&lt;BR /&gt;Yes remote sites are connecting to the central site, and at this step, a process on a central site is connecting to mysql database on remote to get datas. Lines are not permanent, remote sites are connecting just 1 or 2 times everyday. And they are the manager of their own databases (updates are mostly on remote). &lt;BR /&gt;Public ip are changing every days on remotes, that's why I would rather find a solution (like the tunnel of the sshd on itself ) where the remote is the ssh client.&lt;BR /&gt;&lt;BR /&gt;The other way would be a full vpn, but licence cost ! and the remotes routers cannot support ipsec !&lt;BR /&gt;&lt;BR /&gt;What I would like to know is the channel 2 error , which is linked to ssh  ??&lt;BR /&gt;If you have any idea to investigate (a tool, a debug option ???)&lt;BR /&gt;sshd -d -d -d didn't gave more explanation, no more ssh -v...&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Benoit</description>
      <pubDate>Wed, 02 Apr 2003 08:37:00 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940767#M577227</guid>
      <dc:creator>benoit Bruckert</dc:creator>
      <dc:date>2003-04-02T08:37:00Z</dc:date>
    </item>
    <item>
      <title>Re: openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940768#M577228</link>
      <description>After more tests, I found the solution :&lt;BR /&gt;upgrade to openssh v3.6.1p1.&lt;BR /&gt;I used previously a sshd server :&lt;BR /&gt;3.5p1.&lt;BR /&gt;The fact to change the version made the loop working well , or maybe the fact to use loopback address ?? Or the fact to start from 0 with this new sshd !!!!!&lt;BR /&gt;command to open the 3307 or any other to the world :&lt;BR /&gt;ssh -L3307:127.0.0.1:3306 127.0.0.1 -g !!!! with the remote already connected to this server !!!&lt;BR /&gt;And it works like a charm.&lt;BR /&gt;From any workstation on the lan I can get the datas, and it works fast :&lt;BR /&gt;about  30s to generate a 1.3MB file from mysql datas !! on a 64Kbit/s line..&lt;BR /&gt;&lt;BR /&gt;thanks for your help !&lt;BR /&gt;Benoit</description>
      <pubDate>Wed, 02 Apr 2003 11:52:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940768#M577228</guid>
      <dc:creator>benoit Bruckert</dc:creator>
      <dc:date>2003-04-02T11:52:16Z</dc:date>
    </item>
    <item>
      <title>Re: openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940769#M577229</link>
      <description>Jordan,&lt;BR /&gt;Can you post something in order to attribute a bunny , because the solution is in this thread, and it would be good to find it in the search engine !!!&lt;BR /&gt;&lt;BR /&gt;regards&lt;BR /&gt;Benoit&lt;BR /&gt;____________&lt;BR /&gt;Amour, amour, quand tu nous tiens, on peut bien dire : "Adieu, prudence !" Jean De La Fontaine</description>
      <pubDate>Wed, 02 Apr 2003 11:56:52 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940769#M577229</guid>
      <dc:creator>benoit Bruckert</dc:creator>
      <dc:date>2003-04-02T11:56:52Z</dc:date>
    </item>
    <item>
      <title>Re: openssh port forwarding with mysql</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940770#M577230</link>
      <description>Hi Benoit. I glad you got it working! I'm not exactly sure how my remarks helped, but I'm happy to contribute even a little bit.</description>
      <pubDate>Wed, 02 Apr 2003 22:28:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/openssh-port-forwarding-with-mysql/m-p/2940770#M577230</guid>
      <dc:creator>Jordan Bean</dc:creator>
      <dc:date>2003-04-02T22:28:36Z</dc:date>
    </item>
  </channel>
</rss>

