Re: moving file from one server to another
| From: | Richard Lynch | Date: | Mon, 02 Oct 2006 22:05:21 +0000 |
| Subject: | Re: moving file from one server to another | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-242509@lists.php.net to get a copy of this message | ||
On Sat, September 30, 2006 5:25 am, Nick Wilson wrote:
> yes. i'd considered rsync but the file needs to be available on the
> image server immediately. scp'ing it should work, but of course imnow
> having fun with the apache user and try9ing to work out how to give it
> an ssh profile :)
Here's your first problem.
There *IS* no such thing as "immediately" in this world.
It's a nonsense word in this context.
How much time do you REALLY have here as a constraint?
Re-think this carefully, because any answer that doesn't provide at
least a few seconds is just plain Wrong. :-)
Now, once you've got "immediately" out of your head, ponder whether or
not the user really wants to sit around, even for a few extra seconds,
while *YOU* dink around with this scp stuff.
I don't.
Would you?
Of course not!
The user wants to upload the file, and then use those seconds to do
something else useful, instead of watching your locked-up web
application do "nothing" that is useful to them.
If that LAMP/thttp connection gets slogged by a lot of uploads, the
LAST thing you want is all your users sitting around *waiting* on that
task which is, by definition, out-of-band with what the user wants to
do.
--
Some people have a "gift" link here.
Know what I want?
I want you to buy a CD from some starving artist.
http://cdbaby.com/browse/from/lynch
Yeah, I get a buck. So?