[TriLUG] cp of /dev hangs, but not tar

James Tuttle jjtuttle at trilug.org
Sat Jun 16 13:08:03 EDT 2007


Robert Dale wrote:
> On 16 Jun 2007 12:10:33 -0400, Jon Carnes <jonc at nc.rr.com> wrote:
>> I'm certain that cp does a write then a read to verify... or rather it
>> calls a disk-write process that does a write then a read before giving
>> the thumbs up back to the cp process. Of course it's been a long, long
>> time since I've looked at the source code for cp.
> 
> No it doesn't and thank goodness.  Copying files would take almost
> twice as long if it had to read it back and verify.  cp does a dumb
> copy and checks for the usual errno (ie. write failed).  It's
> sufficient for most tasks.
> 

Thanks.

Yeah, my python copy process takes much, much longer, but verifying data
is absolutely essential at work.  I assumed cp did some size comparison,
which isn't adequate.

Sorry to hijack the thread.

-- 
--
---Jim Tuttle
------------------------------------------------------
url: http://www.prairienet.org/~jtuttle/
PGP key: http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x69B69B08




More information about the TriLUG mailing list