<div dir="ltr">If you call fallocate() over an existing region with data it shouldn&#39;t be wiped with 0s. You can also call fallocate() on a hole (in case file was ftruncate()ed to a large size) and that region should get &quot;allocated&quot; (i.e future write to an fallocated() region should NOT fail with ENOSPC).<div>
<br></div><div>BTW, does NetBSD have the equivalent of open_by_handle[_at]() and name_to_handle[_at]() system calls?</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Sat, Nov 16, 2013 at 12:40 PM, Emmanuel Dreyfus <span dir="ltr">&lt;<a href="mailto:manu@netbsd.org" target="_blank">manu@netbsd.org</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I note that glusterfs-3.5 branch requires fallocate(). That one does not<br>
exist in NetBSD yet. I wonder if it can be emulated in userspace: this<br>
is just about writing zeros to the new size, right?<br>
<span class="HOEnZb"><font color="#888888"><br>
--<br>
Emmanuel Dreyfus<br>
<a href="http://hcpnet.free.fr/pubz" target="_blank">http://hcpnet.free.fr/pubz</a><br>
<a href="mailto:manu@netbsd.org">manu@netbsd.org</a><br>
<br>
_______________________________________________<br>
Gluster-devel mailing list<br>
<a href="mailto:Gluster-devel@nongnu.org">Gluster-devel@nongnu.org</a><br>
<a href="https://lists.nongnu.org/mailman/listinfo/gluster-devel" target="_blank">https://lists.nongnu.org/mailman/listinfo/gluster-devel</a><br>
</font></span></blockquote></div><br></div>