diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index 795707ec5d..4690ddaa4d 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -254,7 +254,7 @@ class Partition():
                 # Bitbake variable ROOTFS_SIZE is not defined so compute it
                 # from the rootfs_dir size using the same logic found in
                 # get_rootfs_size() from meta/classes/image.bbclass
-                du_cmd = "du -ks %s" % rootfs_dir
+                du_cmd = "du -ks --apparent-size %s" % rootfs_dir
                 out = exec_cmd(du_cmd)
                 self.size = int(out.split()[0])
 
@@ -273,7 +273,7 @@ class Partition():
         """
         Prepare content for an ext2/3/4 rootfs partition.
         """
-        du_cmd = "du -ks %s" % rootfs_dir
+        du_cmd = "du -ks --apparent-size %s" % rootfs_dir
         out = exec_cmd(du_cmd)
         actual_rootfs_size = int(out.split()[0])
 
@@ -349,7 +349,7 @@ class Partition():
         """
         Prepare content for a btrfs rootfs partition.
         """
-        du_cmd = "du -ks %s" % rootfs_dir
+        du_cmd = "du -ks --apparent-size %s" % rootfs_dir
         out = exec_cmd(du_cmd)
         actual_rootfs_size = int(out.split()[0])
 
