1

If there is some data in the file system does it has to be moved?

1
  • 1
    We need much more details. And NO, extend XFS is not heavy operation and it can be done on the fly (w/o need to unmount the filesystem) Commented May 24 at 10:07

1 Answer 1

1

why don't you try? fallocate -l 2G img; mkfs.xfs img; sudo mount -o loop img /mnt; fallocate -l 4G img; sudo xfs_growfs /mnt should do that and give you an instant answer.

Anyways, no, growing modern filesystems, and especially XFS, is not a heavy operation. There's no data to be moved – there's just new free space; a couple of data structures need to be updated / created (if the new size implies more allocation groups). All in all, nearly no work.

2
  • Well, your command line test does not involve having any data in the filesystem, so it does not test that case, but I suppose you know anyway. Commented May 24 at 20:18
  • @jarno yep, but your can add as many files as you want after mounting it, to make the test more representative of what you have :) But I think you've known that, as well :) Commented May 25 at 9:50

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.