osgrid.org
https://forums.osgrid.org/

Mysql Unable to connect to server errors
https://forums.osgrid.org/viewtopic.php?f=15&t=5082
Page 1 of 1

Author:  Christy Lock [ Tue Feb 25, 2014 5:03 pm ]
Post subject:  Mysql Unable to connect to server errors

If you are trying to connect scripts to your database but getting Unable to connect errors try these things they fixed it for me. Note that using 0.0.0.0 is unsecure though. If you know a better way to do this then please add it here. These errors all all over the net it's time we fix this.

Changes made to a new xampp install so that mysql was reachable from opensim or sl from any computer.

In this example I am using port 9400 and have forwarded that port to my computer that is running the apache server and mysql database using the xampp interface.
Your port may be different so just replace 9400 with your port number that you want to use.
I have put four "<--- DO THIS" on this page to make it easier to see the actions you must take.



1).
------------------------------------------------
xampp/mysql/bin/my.ini
Change bind-address="0.0.0.0"<--- DO THIS



2).
------------------------------------------------
xampp/apache/conf/httpd.conf
Look for the Listen and make it Listen 0.0.0.0:9400<--- DO THIS
or whatever port you are forwarding with your router. Your ISP is blocking port 80 that is why the default 80 won't work
This will give you "Unable to contact sever" errors if you try to access your db from lsl.



3).
------------------------------------------------
xampp/apache/conf/extra/httpd-xampp.conf

Now that we have port forwarded and changed your apache server to listen on port 9400 we have a new issue. When you click the Admin button your browser
will not open your mysql main page. This is beacuse it is looking for localhost port 80 phpmyadmin. You are now using localhost port 9400 phpmyadmin.

Open httpd-xampp.conf . Near the bottom you need to change Deny from all to Allow from all<--- DO THIS



This allows you to use your normal browser to open mysql after you made the changes to the listen.

Make sure to restart xampp panel after making this change.<--- DO THIS

Now you can use type the following into any browser to get to your mysql main page.

http://your external ip:9400/phpmyadmin/

Note that if you do not know what your external ip is just type Whatismyip into any browser and one of the links there should show you.


Alternatively you can also use:
localhost:9400/phpmyadmin


This all worked for me I hope it helps.


https://community.apachefriends.org/f/v ... 17&t=37286 this is where i got the info for solving the third issue

Page 1 of 1 All times are UTC - 5 hours
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/