It is currently Sat, 26 Nov 2022 05:13:37 GMT



 
Author Message
 Size difference when copying LARGE file

Are you copying a live file, or something in use by the database?
What does ls -l show for file size for original and copy?



 Thu, 20 Nov 2008 08:27:33 GMT   
 Size difference when copying LARGE file
In article <1149375551.171299.25...@c74g2000cwc.googlegroups.com>,

What does "ls -ls" show for the original and the copy?

Database files are frequently sparse, they have holes that have
never been written to and don't occupy actual disk space.  Eg:
        % dd if=/dev/zero of=t1 bs=1k count=1 seek=10k
        % cp t1 t2
        % ls -ls t1 t2
          40 -rw-r--r--   1 jgp      10486784 Jun  5 17:17 t1
        10256 -rw-r--r--   1 jgp      10486784 Jun  5 17:18 t2
        % du -s t1 t2
        40      t1
        10256   t2
t1 is only 40k on disk even though the final byte is at lseek
position 10486784.  One copied it grows to 10M since the holes
get filled in.

I believe ufsdump/ufsrestore are the only tools standard tools that
preserve holes in files.

Star ( http://cdrecord.berlios.de/old/private/star.html ) handles them.
--
Jim Prescott - Computing and Networking Group   j...@seas.rochester.edu
School of Engineering and Applied Sciences, University of Rochester, NY



 Sat, 22 Nov 2008 05:24:01 GMT   
 Size difference when copying LARGE file
In article <e627dh$...@harn.ceas.rochester.edu>,

If you use a pre S-2.6 or a recent Solaris, star is able to correctly copy
holes too. With star there is no need to be root in order to do this (at least
not on a recent Solaris version - the old Solaris hole interface forces you to
be root too).

--
EMail:jo...@schily.isdn.cs.tu-berlin.de (home) J?rg Schilling D-13353 Berlin
      j...@cs.tu-berlin.de                (uni)  
      schill...@fokus.fraunhofer.de       (work) Blog: http://schily.blogspot.com/
URL:  http://cdrecord.berlios.de/old/private/ ftp://ftp.berlios.de/pub/schily



 Sat, 22 Nov 2008 06:01:12 GMT   
 
   [ 3 post ] 

Similar Threads

1. Size difference when copying a large file in solaris

2. File size wrong, can't copy large file

3. Why the difference in block size after copy?

4. File size difference when nulling a file

5. Enable Large File Size in Aix file system

6. Difference between copy to and copy from nfs mounted disk

7. copy file too large

8. lpr: : copy file is too large ?

9. When I copy large files, I met IO ERROR

10. Please help--WindowsXP cannot copy large files to Samba


 
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software