If this is your first visit, check our documentation. To post, register or login.
Forums / Installing on a Linux/Unix Server / how about using a remote mySQL server

how about using a remote mySQL server

Locked

Started by ericgu on 6 Oct 2006, 1:45 PM · Views: 3,068

Results 1 to 6 of 6
This thread is locked. New replies are disabled.
6 Oct 2006, 1:45 PM
#1
ericgu avatar

ericgu

New Zenner

Join Date:
Aug 2005
Posts:
58
Plugin Contributions:
0

how about using a remote mySQL server

Can I use a remote mySQL server?

Will it cause any security or synchronization problem?

I am have several hosting accounts.
I am thinking of put my sites normal files on all those servers, and share one mySQL server on one VPS hosting.

So my site won't go offline.
Any hosting's down, I can simply switch the domain's DNS to point to another server.

Anyone give me suggestion on it?

Thanks a lot.

6 Oct 2006, 4:06 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: how about using a remote mySQL server

Zen Cart can use any accessible MySQL server for its data. If you wish to use a server other than "localhost", simply set the DB_SERVER parameter in your configure.php files to point to the proper server. The other DB_xxxxx settings need to suit the security credentials required for the database+user on that server.

There are security implications though.
If that server sits outside your hosting company's internal network of servers, then your data will be vulnerable to sniffing and theft.

There are performance issues too.
If that server sits outside your hosting company's internal network, then you have to use a slower connection to get to the database server, then wait for it to retrieve the data, and send it back across the slower connection again. Sometimes this can be problematic. Sometimes it's unnoticable.

Zen Cart will do what you tell it to do. How you secure it and how well it performs, are issues Zen Cart cannot resolve for you.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

6 Oct 2006, 4:49 PM
#3
ericgu avatar

ericgu

New Zenner

Join Date:
Aug 2005
Posts:
58
Plugin Contributions:
0

Re: how about using a remote mySQL server

thanks a lot

7 Oct 2006, 12:22 AM
#4
fluffytigger avatar

fluffytigger

Zen Follower

Join Date:
Dec 2005
Location:
My Own Fluffy Place, Pangea
Posts:
377
Plugin Contributions:
0

Re: how about using a remote mySQL server

Connect to the outside mysql server through SSL. I don't know if that's build in to the standard rpm, you might need to compile your own mysql.

Yeah! I'm small! I'm Fluffy! Stick tongue out

7 Oct 2006, 12:26 AM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,512
Plugin Contributions:
176

Re: how about using a remote mySQL server

Good point. Remember that encrypting to SSL will add another layer of slowdown, so if the internet connections between your webserver and the database server are slow in any way ... then your website will be too.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

7 Oct 2006, 3:43 PM
#6
vger avatar

vger

Past Contributor

Join Date:
Nov 2004
Location:
Norfolk, United Kingdom
Posts:
3,189
Plugin Contributions:
0

Re: how about using a remote mySQL server

I am have several hosting accounts. I am thinking of put my sites normal files on all those servers.

If your website is on a separate server to MySQL then the website will need to have a dedicated ip address to allow it to be set up as a 'Remote User ' on the MySQL server (for access).

If you have other websites spread across other servers they'd all need to have dedicated ip addrsses and all need to be set up as 'Remote Users'.
Personally I think it's a recipe for disaster.

So my site won't go offline. Any hosting's down, I can simply switch the domain's DNS to point to another server.

Yes, you can do that, and in about 48-72 hrs the various ISP's will have updated their records of where the domain is located and the sites will be back online. If you genuinely want to protect against sites going offline then there are two alternatives:

  1. Genuine Co-Location hosting (not cheap by any means)

  2. A server with three hard drives, two in Hardware RAID, the third for backups. If the one disc fails the other takes over - if both fail you have a backup which can be rolled out to new hard drives. Also not cheap.

Vger