With WebMatrix, How do I Connect to a MySQL Database on a Colleague's Machine?
        Posted  
        
            by 
                Ash Clarke
            
        on Server Fault
        
        See other posts from Server Fault
        
            or by Ash Clarke
        
        
        
        Published on 2012-12-13T16:52:31Z
        Indexed on 
            2012/12/13
            17:04 UTC
        
        
        Read the original article
        Hit count: 530
        
I have scoured Google trying to discover how to do this, but essentially I want to connect to a colleague's MySQL database for working together on a Wordpress installation.
I am having no luck and keep getting an error about the connection not being possible:
Unable to connect to any of the specified MySQL hosts.
MySql.Data.MySqlClient.MySqlException (0x80004005): Unable to connect to any of the specified MySQL hosts.
   at MySql.Data.MySqlClient.NativeDriver.Open()
   at MySql.Data.MySqlClient.Driver.Open()
   at MySql.Data.MySqlClient.Driver.Create(MySqlConnectionStringBuilder settings)
   at MySql.Data.MySqlClient.MySqlPool.GetPooledConnection()
   at MySql.Data.MySqlClient.MySqlPool.TryToGetDriver()
   at MySql.Data.MySqlClient.MySqlPool.GetConnection()
   at MySql.Data.MySqlClient.MySqlConnection.Open()
   at Microsoft.WebMatrix.DatabaseManager.MySqlDatabase.MySqlDatabaseProvider.TestConnection(String connectionString)
   at Microsoft.WebMatrix.DatabaseManager.IisDbManagerModuleService.TestConnection(DatabaseConnection databaseConnection, String configPathState)
   at Microsoft.WebMatrix.DatabaseManager.Client.ClientConnection.Test(ManagementConfigurationPath configPath)
   at Microsoft.WebMatrix.DatabaseManager.Client.DatabaseHierarchyInfo.EnsureLoaded()
The connection details are copied from my colleague's connection string, with the exception of the server being modified to match the IP address of his machine.

I'm not sure if there is a firewall port I have to open or a configuration file I have to modify, but I'm not having much luck so far.
(There is a strong chance that, by default, web matrix / iis express doesn't set the mysql database it creates to accept remote connections. If anyone knows how to change this, that would be grand!)
Anyone have any ideas?
© Server Fault or respective owner