On Thu, Aug 12, 2010 at 3:59 PM, Andrew Farnsworth <farn...@gmail.com> wrote: > On Thu, Aug 12, 2010 at 4:56 PM, Richard Thomas <r...@dicksonlife.com> > wrote: >> >>> >>> Rich, >>> Great minds think alike! unfortunately type just gets part way and dies >>> with an error when apache grabs the file for writing. Xcopy does the same. >>> I cannot change the configuration of apache in any reasonable amount of >>> time (i.e. months) so I consider that a non-viable solution. >>> >>> Andy >>> >>> >> Hmm. OK, I'm stepping out of my bounds a little now but I think I recall >> Robocopy will keep retrying until a copy is successful. Might be worth a >> try. > > I'm going to start calling you Psychic in a minute. Sorry, it doesn't work > either because it is not possible to copy the entire 1Gb+ file in the time > between writes... it just fails over and over and over since it restarts the > copy from the beginning. > > Andy >
I should have thought of Robocopy earlier. Reading about the idea of using tail to snatch a bit of the file at a time made me think of it. We use it all the time to copy large files over small pipes. There is a trick to Robocopy in the flags and arguments. Try this: robocopy /Z /V /W:1 /R:9999 \path\to\logs\ \path\to\new\location\ apache.log /Z - restartable-on-error copy mode /V - verbose /W:1 - wait 1 second between retries (default is much larger I think) /R:9999 - retry 9999 times (default is 1 million, which might actually be better in this case) \path\to\logs - folder to copy source from \path\to\new\location\ - folder to copy to apache.log - actual name of file to copy (you can not just append this to the source folder argument as \path\to\logs\apache.log like you would with most command utilities) Even if apache kicks you every few bytes, robocopy will now pick up where it left off. -- Don Delp 618.616.2993 http://nesman.net/ -- You received this message because you are subscribed to the Google Groups "NLUG" group. To post to this group, send email to nlug-talk@googlegroups.com To unsubscribe from this group, send email to nlug-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/nlug-talk?hl=en