5

I want to test XFS dedup feature, so i put a new HD to my fileserver VM. I started rsync files from old disk to new one, but I got "No space left on device".

This is my df -h output:

Filesystem                 Size  Used Avail Use% Mounted on
/dev/mapper/debian7-root   982G  576G  356G  62% /
/dev/mapper/owncloud-data  600G  600G  181M 100% /mnt/owncloud-data

I want to copy /var/www/owncloud/data/ (inside / disk)

du -sh /var/www/owncloud/data/
571G    /var/www/owncloud/data/

to /dev/mapper/owncloud-data.

I typed (when /dev/mapper/owncloud-data was empty)

rsync -av --progress /var/www/owncloud/data/*  /mnt/owncloud-data/

but I got "no space left on device".

So, why can't I fit 576GB of data on a 600GB disk?

Updated: maybe it isn't clear, but destination disk 600GB is XFS formatted, so there isn't any 5% reserved space.

peterh
  • 9,488
  • 16
  • 59
  • 88
CeccoMe
  • 163
  • 7
  • Possible duplicate of [Reserved space for root on a filesystem - why?](https://unix.stackexchange.com/questions/7950/reserved-space-for-root-on-a-filesystem-why) – muru Oct 20 '17 at 07:51
  • 5% of the space on ext4 is reserved for root by default, and 5% of 600 GB is 30 GB. – muru Oct 20 '17 at 07:51
  • @muru 600GB is XFS not ext4 – CeccoMe Oct 20 '17 at 07:55
  • Hmm, in that case, try the `xfs_check` command to see if space is overallocated somewhere – muru Oct 20 '17 at 08:04

1 Answers1

7

I've solved it: in the source data there is 47GB of files hardlinked. Now I'm trying rsync with -H option, I can see at start of rsync it has freed 70GB of data hard linking a lot of files.

Thank you

CeccoMe
  • 163
  • 7