title: How to log in mysql DB in remote host
body: <p>I use mysql in vm1 host which ip is:10.104.xx.xx. 
  I can log in DB successfully like is:</p>
  
  <pre><code>mysql  -uStack -pqwerasdf##123 hpcusers;
  </code></pre>
  
  <p>and the grants of Stack user is:</p>
  
  <pre><code>show grants for Stack@'%';
  </code></pre>
  
  <p>the result:</p>
  
  <pre><code>+--------------------------------------------------------------+
  | Grants for Stack@%                                           |
  +--------------------------------------------------------------+
  | GRANT ALL PRIVILEGES ON *.* TO 'xiezy'@'%' WITH GRANT OPTION |
  | GRANT ALL PRIVILEGES ON `hpcusers`.* TO 'xiezy'@'%'          |
  +--------------------------------------------------------------+
  2 rows in set (0.00 sec)
  </code></pre>
  
  <p>Now I want to log in DB from remote vm2 host. I use:</p>
  
  <pre><code>mysql -h10.104.xx.xx -uStack -pqwerasdf##123 hpcusers    
  </code></pre>
  
  <p>But it is unlucky, I am fail, the result is:</p>
  
  <pre><code>Warning: Using a password on the command line interface can be insecure.
  ERROR 2003 (HY000): Can't connect to MySQL server on '10.104.xx.xx' (110)
  </code></pre>
  
  <p>The mysql version in vm1 host is </p>
  
  <pre><code>Server version: 5.6.25-73.1 Percona Server (GPL), Release 73.1, Revision 07b797f
  </code></pre>
  
  <p>The mysql version in vm2 host is:</p>
  
  <pre><code>Server version: 5.7.24-log MySQL Community Server (GPL)
  </code></pre>
  
  <p>At the same time, I can</p>
  
  <pre><code>ping 10.104.xx.xx
  </code></pre>
  
  <p>successfully in vm2 host. and I can log in vm1 successfully</p>
  
  <pre><code>ssh root@10.104.xx.xx
  </code></pre>
  
  <p>Who can help me? Why I can't remote log in DB ?</p>