On 4/26/21 10:17 AM, Federico Ressi wrote:
Hey Frederico,
Do you know if this is fixed in upstream cloud-init already? Fedora 34, which is about
to
be released tomorrow has cloud-init-20.4-1.fc34.
This is fixed by the upstream commit:
commit 6603706eec1c39d9d591c8ffa0ef7171b74d84d6
Author: Eduardo Otubo <otubo(a)redhat.com>
Date: Thu Jan 23 17:41:48 2020 +0100
Do not use fallocate in swap file creation on xfs. (#70)
When creating a swap file on an xfs filesystem, fallocate cannot be used.
Doing so results in failure of swapon and a message like:
swapon: swapfile has holes
The solution here is to maintain a list (currently containing only XFS)
of filesystems where fallocate cannot be used. The, on those fileystems
use the slower but functional 'dd' method.
Signed-off-by: Eduardo Otubo <otubo(a)redhat.com>
Co-authored-by: Adam Dobrawy <naczelnik(a)jawnosc.tk>
Co-authored-by: Scott Moser <smoser(a)brickies.net>
Co-authored-by: Daniel Watkins <daniel(a)daniel-watkins.co.uk>
LP: #1781781
And is available on cloud-init >= 20.1, which is the case for Fedora 34.
In case this is a critical bug for you, please file a BZ and assign it to me. I
can check the possibility for a backport.
Thanks!