I am switching machines and have attached the old hard drive (/dev/sda4
) to the new machine.
The old machine had a slightly smaller hard drive (720G
), compared to the new one (736G
), so I created a slightly larger partition as well.
So, I then ran rsync
to copy all the data to the new partition, as shown below:
linux-70e2:/ # time rsync -azprvl /mnt/external-disk/foo /media/sda4/
...
sent 169,237,139,987 bytes received 24,529 bytes 24,419,185.41 bytes/sec
total size is 190,542,953,489 speedup is 1.13
real 115m30.297s
user 112m13.068s
sys 3m59.996s
The data gets copied without errors.
However, when I do:
du -h -m -s /mnt/external-disk/foo /media/sda4/foo
I get:
162414 /mnt/external-disk/foo
181721 /media/sda4/foo
Could somebody please explain this massive difference? Why am I not getting the same results? This is driving me nuts for days now. There are a few other partitions as well and I'm getting similar discrepancies as well.
Both partitions are ext4
.
linux-70e2:/ # mount | grep sda4
/dev/nvme0n1p5 on /media/sda4 type ext4 (rw,relatime,data=ordered)
/dev/sda4 on /mnt/external-disk type ext4 (rw,nosuid,nodev,relatime,data=ordered,uhelper=udisks2)
To my knowledge, there is nothing wrong with both drives which are SSD-s. One of them is brand new. I've run e2fsck
on both of them.
In addition, I ran:
find -L /mnt/external-disk type/foo -type l
and this doesn't list any symlinks below the source directory.
This is not my first time using rsync
for this kind of thing, but I've never had this kind of issue before. Please, advise!