Hello folks
I'd like to try out the new butter filesystem / btrfs but I'm having some problems with the features I'm more interested in - the defragmentation and the shrinking/growing of the fs - both to be triggered by the "btrfsctl" executable.
First of all some details about the system on which I am performing the tests:
- Gentoo distribution
- Kernel 2.6.28
- btrfs-progs package version 0.18
- btrfs kernel module 0.17
I created a 5GB file, formatted and mounted it:
Code:
dd if=/dev/zero of=2delete.img bs=100k count=50000
Code:
mkfs.btrfs 2delete.img
WARNING! - Btrfs Btrfs v0.18 IS EXPERIMENTAL
WARNING! - see http://btrfs.wiki.kernel.org before using
fs created label (null) on 2delete.img
nodesize 4096 leafsize 4096 sectorsize 4096 size 4.77GB
Btrfs Btrfs v0.18
Code:
mount -v -o loop 2delete.img /mnt/temp/
df -h /mnt/temp/
Filesystem Size Used Avail Use% Mounted on
/dev/loop0 4.8G 28K 4.8G 1% /mnt/temp
Then I tried to shrink it, or defragment it, but the error message I get is always the same one:
Code:
btrfsctl -r -1M /mnt/temp
ioctl:: Inappropriate ioctl for device
Code:
btrfsctl -d /mnt/temp
ioctl:: Inappropriate ioctl for device
This doesn't work too:
Code:
btrfsctl -a
Scanning for Btrfs filesystems
failed to read /dev/sr0
And this doesn't bring back any interesting information:
Code:
btrfsctl -A /dev/loop0
operation complete
Btrfs Btrfs v0.18
I tried out all this as well with a "real" HDD (but it's an external one, connected through USB2) and I get exactly the same results.
Am I doing something wrong? Well, I think I did the same as explained here
http://btrfs.wiki.kernel.org/index.php/Btrfsctl so probably the support is not yet ok, or?
Thanks a lot.
