title: I am unable to use MySQL due to a "refused connection"
body: <p>I am trying to run the no-install version of MySQL on Windows XP located in <em>C:/mysql/</em> on my machine.</p>
  
  <p>The error message I receive within a PHP file when I try to connect to MySQL reads.</p>
  
  <blockquote>
    <p>Could not connect: No connection could be made because the target machine actively refused it</p>
  </blockquote>
  
  <p>I have edited the config file <em>my.ini</em> and altered/added the following.</p>
  
  <pre><code>[client]
  port        = 3306
  socket      = C:/mysql/tmp/mysql.sock
  
  [mysqld]
  port        = 3306
  socket      = C:/mysql/tmp/mysql.sock
  basedir = C:/mysql/
  datadir = C:/mysql/data/
  bind-address = 127.0.0.1
  skip-networking
  enable-named-pipe
  </code></pre>
  
  <p>When I run mysqld.exe I can confirm it is running within command prompt tasklist.
  However when I try cmd <em>netstat -a</em> I cannot see any port usage at 3306.</p>
  
  <p>Inside MySQL error logs, it reads.</p>
  
  <blockquote>
    <p>140411 13:30:34 [Note] c:\mysql\bin\mysqld.exe: ready for connections.
    Version: '5.5.37-log'  socket: ''  port: 0  MySQL Community Server (GPL)</p>
  </blockquote>
  
  <p>The port: 0 doesn't look correct to me, but I am not sure.</p>
  
  <p>When I run mysql.exe direct in cmd I get the following returned</p>
  
  <pre><code>ERROR 2003 (HY000): Can't connect to MySQL server on 'localhost' (10061)
  </code></pre>
  
  <p>Some things I have tried already.</p>
  
  <ul>
  <li>Placing a copy of <em>my.ini</em> in C:/WINDOWS and also a copy within C:/mysql</li>
  <li>Changing <em>bind-address = 127.0.0.1</em> to <em>bind-address =
  localhost</em></li>
  <li>Inside PHP file MySQL connection variants, <em>localhost</em>, <em>127.0.0.1</em>, <em>127.0.0.1:3306</em> inside basic mysql_connect()</li>
  <li>Created tmp/mysql.sock file (in case dir + file not existing matters)</li>
  <li>Commented out <em>skip-networking</em> in <em>my.ini</em></li>
  <li>After running mysqld.exe whilst running ran mysqladmin.exe in cmd which returns 'Can't connect to MySQL server at 'localhost'</li>
  <li>Running telnet localhost 3306 returns 
  '<em>Connecting To localhost...Could not open connection to the host, on port 3306: C
  onnect failed</em>'</li>
  <li>Commented out <em>bind-address</em> in <em>my.ini</em> to allow default settings.</li>
  <li>Ran mysqld.exe with user root (<em>-u root</em>) also inserted <em>user = root</em> in <em>my.ini</em></li>
  <li>Set Windows Firewall to off.</li>
  </ul>
  
  <p>Thanks in advance.</p>