Executing remote code

Not for 'how-to' coding questions but PHP theory instead, this forum is here for those of us who wish to learn about design aspects of programming with PHP.

Moderator: General Moderators

Post Reply
froth
Forum Commoner
Posts: 31
Joined: Sat Jan 22, 2005 9:26 pm

Executing remote code

Post by froth »

I'm using a script to generate a signature for a forum I'm active in but it's a very large forum and the script gets/makes some 5000000 requests per month! Since I'm using a free host and I only get 3GB transfer per month, I have five free accounts. The img tag is pointed at account #1 which decides dynamically which account to forward the request, then one of the other four accounts receives the request and passes the signature back to the browser. This solution saved me bandwidth-wise, but I'm having trouble maintaining and adding new things to my signature since it's hosted on five servers.

Is there any way I can keep the latest version of my code in a TXT document on server 1 and have servers 2-5 just read the code out of the file and execute it?
User avatar
Ambush Commander
DevNet Master
Posts: 3698
Joined: Mon Oct 25, 2004 9:29 pm
Location: New Jersey, US

Post by Ambush Commander »

Read about Distributed Environments. One of the problems that some admins have is making sure the applications on every server are the same. I think you should start coding a maintenance script, which can download the PHP code from the main server and replace it. A bit risky, but if you integrate good security I think it could save you a lot of work.
Post Reply