title: How to start multi ssh connection in one bash script?
body: <p>i have 10+ ssh server needs to do port forwarding when i start to work, but i'm tired to start those ssh connections one by one. i know in linux the powerful bash script can handle this problem. here is my bash script example</p>
  
  <pre><code>#!/bin/bash
  ssh -L 10001:somehost:3306 user@host1 -N
  ssh -L 10002:somehost:3306 user@host2 -N
  ssh -L 10003:somehost:3306 user@host3 -N
  ....
  </code></pre>
  
  <p>i found out that if the first ssh connection started, it just stopped at that line and wait it to close.</p>
  
  <p>could any one tell me how to fix it?</p>