0

I have an Ubuntu 18.04 server which is used by a backup software as a storage. The backup software saves the data to a xfs partition (/backup) which is on RAID5. The root filesystem is ext4.

When I check free space with df -h I get this result:

Filesystem      Size  Used Avail Use% Mounted on
/dev/md1         16T   11T  5,8T  64% /backup

When I check disk usage with du -h /backup I get this:

16G     /backup/backup_folder1
0       /backup/backup_folder2
1,4T    /backup/backup_folder3
4,8T    /backup/backup_folder4
0       /backup/backup_folder5
0       /backup/backup_folder6
0       /backup/backup_folder7
0       /backup/backup_folder8
23G     /backup/backup_folder9
3,5T    /backup/backup_folder10
35M     /backup/backup_folder11
675G    /backup/backup_folder12
2,7T    /backup/backup_folder13
69G     /backup/backup_folder14
58G     /backup/backup_folder15
158G    /backup/backup_folder16
103G    /backup/backup_folder17
14T     /backup/

And with xfs_quota -x -c "report -h" /backup I get this:

ser quota on /backup (/dev/md1)
                        Blocks              
User ID      Used   Soft   Hard Warn/Grace   
---------- --------------------------------- 
root            0      0  15,6T  00 [------]
user     13,1T      0  15,8T  00 [------]

Group quota on /backup (/dev/md1) Blocks
Group ID Used Soft Hard Warn/Grace


root 0 0 0 00 [------] user 13,1T 0 0 00 [------]

Has someone any idea what is the cause behind these differences? The main problem is that my backup software also sees that the xfs partition has 5,8TB free space (like the df -h does) and the backup jobs fails because of that.

I have seen many posts about df shows more used space than du but my case is reversed.

xfs_info /backup:

meta-data=/dev/md1               isize=512    agcount=32, agsize=132748288 blks
         =                       sectsz=4096  attr=2, projid32bit=1
         =                       crc=1        finobt=1 spinodes=0 rmapbt=0
         =                       reflink=1
data     =                       bsize=4096   blocks=4247945216, imaxpct=5
         =                       sunit=128    swidth=384 blks
naming   =version 2              bsize=4096   ascii-ci=0 ftype=1
log      =internal               bsize=4096   blocks=521728, version=2
         =                       sectsz=4096  sunit=1 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0

Any idea would be appreciated!

Thank you!

  • Check https://askubuntu.com/questions/280342/why-do-df-and-du-commands-show-different-disk-usage?rq=1 – pLumo May 31 '21 at 13:37
  • see also https://unix.stackexchange.com/questions/120311/why-are-there-so-many-different-ways-to-measure-disk-usage – Archemar May 31 '21 at 13:55
  • Thank you for comments. The articles were very informative but did not answer the question. As I said many articles are about why df shows more used space than du but in my case it is reversed. – PocsArc Jun 02 '21 at 11:36

0 Answers0