I have my main web server and I need a seperate workhorse server, I cant get around this unfortunatly. The workhorse server generates a largeish (+100mb) SQL file which I need to import to the web server every day.
The way I see it, I have two options:
1. Option one – Allow the web server to connect to postgreSQL on the workhorse server and import the data directly from postgre running on the workhorse server
2. Option two – Export the SQL database from the workhorse server and upload it to AmazonS3. Then download the file from S3 on the web server and import it to postgreSQL server running on the web server.
My main concerns is to keep the system as simple, secure and reliable as possible. I want to limit the chances of the database getting corrupted.
From the answers I got, it looks like option 1 is the best best. To use the server as an SQL host and query it directly rather than move the SQL file.