558 Posts in 3589 Topics by 244 members
Page: 1 2
|Go to End||Next >|
24 December 2009 at 9:20am Last edited: 24 December 2009 9:42am
Just like the title says, is it possible to connect to a MySQL database which is hosted on a different ISP to the ISP that Silverstripe is hosted on?
Specifically my mate has his site hosted on one of the new Telecom hosting plans, but they use MSSQL. So was thinking I could connect to the MySQL database that's hosted on my isp!?
25 December 2009 at 1:24am
Doubtful , since the ISP that hosts your database probably does not allow direct connections to the MySQL server.
11 January 2010 at 8:47am
I've done it with loads of sites, you just need to put: mydomain.com
Rather than localhost in the _config.php file.
You may also need to allow the connection, on my cpanel on my MySQL host I just added the IP address and domain name from the control panel of my SS host.
I got stuck with one and the hosting company sorted it for me.
Need help or better instructions let me know!
13 January 2010 at 11:52am Last edited: 13 January 2010 11:53am
Cheers pinkpoliceman! I had a feeling it must be possible.
I've asked the hosting company to allow access for the for the websites IP address and domain and have also updated the details in the _config.php, but when installing silverstripe (mydomain.com/silverstripe/install.php) and after re-checking the requirements I am presented with a blank white page that doesn't do anything.
I'd just like to check that the 'localhost' line I need to change is:
Looking forward to your reply! Cheers.
13 January 2010 at 12:07pm
no not that part here is an example of the _config.php in the mysite folder.
$project = 'mysite';
$databaseConfig = array(
"type" => "MySQLDatabase",
"server" => "yourdomain.com",
"username" => "your_username_for_that_db",
"password" => "your_password_for_that_user",
"database" => "your_MySQL_DB",
// Sites running on the following servers will be
// run in development mode. See
// for a description of what dev mode does.
// This line set's the current theme. More themes can be
// downloaded from http://www.silverstripe.com/themes/
When you installed SS, you should have entered the details as above, (if that corresponds I don't the install screen to look at right now), the part you said just leave as is. Im not sure if you need the 'www.' when you enter the server address I haven't so far.
This includes some debug stuff which i find helpful.
Hope that's helpful! let me know if not!
14 January 2010 at 9:11am
I'm still unable to get Silverstripe to install and connect to the remote MySQL database, but I think it could be something to do with the hosting company not adding the IP address and domain name properly. I will check with them once they're back from holidays.
Just to double check - the database server name I'm connecting to is 'mysql.designalt.co.nz' and the database name is 'jacksmachinery'. I have connected to this before perfectly using a silverstripe installation that is hosted on the same domain (designalt.co.nz). Perhaps I should make another MySQL database alongside the 'jacksmachinery' one?
14 January 2010 at 9:23am
Yeah there's no harm in setting up another db.
When you try and install what message do you get? This could determine whether or not it is even finding the server or the db etc..?
14 January 2010 at 9:32am
Ahh no it's not finding the database at all. I've tried 'mysql.designalt.co.nz' along with plain old 'designalt.co.nz' too.
Error message I recieve is "Can't find the a MySQL server on 'mysql.designalt.co.nz': Unknown MySQL server host 'mysql.designalt.co.nz' (11004)"
Perhaps I'll wait until I have heard back from the hosting company that looks after the MySQL server and double check that they have the right IP and DNS.
Page: 1 2
|Go to Top||Next >|