View Single Post
Old 02-17-2011, 10:02 AM  
camperjohn64
Confirmed User
 
Industry Role:
Join Date: Feb 2005
Location: Los Angeles
Posts: 1,531
Best way to copy from server to server?

I have a video converter on www.*.com. After converting, it sends the file to img.*.com and want your ideas on how to send the file across. They are on different servers.

Currently, on www.*.com, I use something like this:

Code:
        fsockopen('img1.domain.com', 80);    
        fputs($fp,"POST /image_upload.php HTTP/1.1\r\n");
        etc etc etc...(also sends MD5 and password)
On the recieving end (img1.*.com), I have image_upload.php that takes the POST'ed file and saves it disk...

Code:
        if (MD5 security check) {
        $fp = fopen(IMAGE_PATH . '/'. $filename,"w");
        fwrite($fp,$uploaded);
        fclose($fp);
This has been working fine between several servers, for a couple of years of service, but it's failing on 100MB + video files.

Does anyone think there is a better method of doing this?

JM
__________________
www.gimmiegirlproductions.com

Last edited by camperjohn64; 02-17-2011 at 10:03 AM..
camperjohn64 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote