* R4: setting a swap file
@ 2011-11-26 16:31 Matias Seco
2011-11-26 19:20 ` Edward Shishkin
0 siblings, 1 reply; 3+ messages in thread
From: Matias Seco @ 2011-11-26 16:31 UTC (permalink / raw)
To: reiserfs-devel
if we would like to set a swap file through:
dd if=/dev/zero of=/swapfile1 bs=<int number (kb)> count=<bs*int number>
we should consider bs (block size) equal to cluster size's plugin
value? (4k, 8k, 16k, 32k or 64k)
PS: sorry, if this thread could be off topic from mailinglist scope,
if it is, please notify me :)
Regards,
Matias
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: R4: setting a swap file
2011-11-26 16:31 R4: setting a swap file Matias Seco
@ 2011-11-26 19:20 ` Edward Shishkin
2011-11-26 20:24 ` Matias Seco
0 siblings, 1 reply; 3+ messages in thread
From: Edward Shishkin @ 2011-11-26 19:20 UTC (permalink / raw)
To: Matias Seco; +Cc: reiserfs-devel
On 11/26/2011 05:31 PM, Matias Seco wrote:
> if we would like to set a swap file through:
>
> dd if=/dev/zero of=/swapfile1 bs=<int number (kb)> count=<bs*int number>
>
Why do you create a swap file via dd from /dev/zero?
Wouldn't be better to create a "hole file" via truncate(2)?
Holes don't occupy any space in a file managed by reiser4
cryptcompress plugin.
>
> we should consider bs (block size) equal to cluster size's plugin
> value? (4k, 8k, 16k, 32k or 64k)
>
Not necessarily.
Clusters are logical blocks in a file which are compressed
independently. If file size is not a multiple of cluster size,
then file's tail will be compressed unless it is not smaller
than cplug->min_size_deflate().
Edward.
>
> PS: sorry, if this thread could be off topic from mailinglist scope,
> if it is, please notify me :)
>
> Regards,
> Matias
> --
> To unsubscribe from this list: send the line "unsubscribe reiserfs-devel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: R4: setting a swap file
2011-11-26 19:20 ` Edward Shishkin
@ 2011-11-26 20:24 ` Matias Seco
0 siblings, 0 replies; 3+ messages in thread
From: Matias Seco @ 2011-11-26 20:24 UTC (permalink / raw)
To: reiserfs-devel
Perfect!, thanks for the advice
Matias
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-11-26 20:24 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-26 16:31 R4: setting a swap file Matias Seco
2011-11-26 19:20 ` Edward Shishkin
2011-11-26 20:24 ` Matias Seco
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.