Perl sparse file maker (was Re: sparse files)

Randal Schwartz merlyn at iwarp.intel.com
Wed Dec 13 11:02:08 AEST 1989


In article <242 at estinc.UUCP>, fnf at estinc (Fred Fish) writes:
| This is about the 2nd or 3rd posting I've seen with a sample program to
| create sparse files.  You guys are working too hard!  :-)
| 
| Try:
| 
| 	echo "This is a sparse file." | dd of=sparsefile seek=1000 bs=1k

And, if you don't have echo (:-),

perl -e 'seek(STDOUT,2**20,0); print "This is a sparse file.";' >sparsefile

Just another Perl hacker (waiting for comp.lang.perl on my machine),
-- 
/== Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ====\
| on contract to Intel's iWarp project, Hillsboro, Oregon, USA, Sol III  |
| merlyn at iwarp.intel.com ...!uunet!iwarp.intel.com!merlyn	         |
\== Cute Quote: "Welcome to Oregon... Home of the California Raisins!" ==/



More information about the Comp.unix.questions mailing list