[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] AW: AW: [Xen-users] Understanding sparse-files
Oh, sh.t ;) Well, no big clue to see that, if the real size is zero! I hope, i'll think a little deeper next time i am asking, thanks again for your time spent to answer. Kind regards, Florian > -----Ursprüngliche Nachricht----- > Von: John Haxby [mailto:john.haxby@xxxxxxxxxx] > Gesendet: Dienstag, 16. Dezember 2008 16:14 > An: Rustedt, Florian > Cc: xen-users@xxxxxxxxxxxxxxxxxxx > Betreff: Re: AW: [Xen-users] Understanding sparse-files > > Rustedt, Florian wrote: > > Thank you! > > > > That was exactly what i needed ;) > > > > > > My pleasure. > > > Does the choosen blocksize has impact on the formatting, so > do i need to take smaller blocksizes if i want to use the > space with the filesystem i am choosing more efficiently? > > Or is it just for calculation, so formatting a "dd bs=512K > seek=2048" results exactly in the same filesystemlayout after > formatting as a "dd bs=1M seek=1024" would do? > > So in both cases, i can use a "mkfs.ext2 -b 512 huge" and > the resulting file mounts in both cases equally with a 256 > Byte blocksize? > > > > Files don't have block sizes :-) dd just multiples the > block size and > seek to find the starting offset. In fact, as the count is > zero (write nothing at all to the file), dd bs=1M seek=20480 > count=0 turns into this: > > open("/dev/zero", O_RDONLY) = 3 > dup2(3, 0) = 0 > close(3) = 0 > lseek(0, 0, SEEK_CUR) = 0 > open("huge", O_RDWR|O_CREAT, 0666) = 3 > dup2(3, 1) = 1 > close(3) = 0 > ftruncate(1, 21474836480) = 0 > > The important call is the last one. > > jch > > ********************************************************************************************** IMPORTANT: The contents of this email and any attachments are confidential. They are intended for the named recipient(s) only. If you have received this email in error, please notify the system manager or the sender immediately and do not disclose the contents to anyone or make copies thereof. *** eSafe scanned this email for viruses, vandals, and malicious content. *** ********************************************************************************************** _______________________________________________ Xen-users mailing list Xen-users@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-users
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |