Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
XFS docker volume from sparse file
root@ip-172-18-21-22:~# dd if=/dev/zero of=myxfs bs=1 count=0 seek=2G
0+0 records in
0+0 records out
0 bytes copied, 0.000199112 s, 0.0 kB/s
root@ip-172-18-21-22:~# mkfs.xfs myxfs
meta-data=myxfs isize=512 agcount=4, agsize=131072 blks
= sectsz=512 attr=2, projid32bit=1
= crc=1 finobt=1, sparse=0, rmapbt=0, reflink=0
data = bsize=4096 blocks=524288, imaxpct=25
= sunit=0 swidth=0 blks
naming =version 2 bsize=4096 ascii-ci=0 ftype=1
log =internal log bsize=4096 blocks=2560, version=2
= sectsz=512 sunit=0 blks, lazy-count=1
realtime =none extsz=4096 blocks=0, rtextents=0
root@ip-172-18-21-22:~# docker volume create -d local -o o=loop -o type=xfs -o device=/root/myxfs loopivol
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.