On Tue, Feb 25, 2003 at 11:09:09PM +1100, JM Alonzo wrote: > On Tue, Feb 25, 2003 at 08:34:04PM +1100, Karl Bowden wrote: > > > > If I create an empty block device in a file (dd if=/dev/zero > > of=new_filesystem seek=10000 count=1 bs=1M) will it use up the whole 10G > > straight away or will it expand as nessecary? eg is the 10G just a quote > > or max size of the block? > > dd won't do that for you. google for sparse files. or if you want you > can read the docs at user-mode-linux. cheers.
dd WILL create sparse files with the seek option: $ dd if=/dev/zero count=1001 of=normal 1001+0 records in 1001+0 records out $ dd if=/dev/zero seek=1000 count=1 of=sparse 1+0 records in 1+0 records out $ ls -ls sparse normal 504 -rw------- 1 mlh users 512512 Feb 26 10:12 normal 8 -rw------- 1 mlh users 512512 Feb 26 10:13 sparse Matt -- SLUG - Sydney Linux User's Group - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug
