Score:1

Why file size is different when select them from the size when copying?

eg flag

I select several files in Thunar file manager and I see that they have 1.9Mib size (on the bottom panel). But they're actually about 5Gb and I see that when copy them into the other place.

enter image description here

Score:3
id flag

Because when you select the folder for copying, Thunar only reports the size of the folder itself and not the contents contained.

Selecting 2 folders and 1 file shows only 176 bytes as that is the size of the script file:

enter image description here

enter image description here

Right clicking on one of them and selecting Properties shows full size of all:

enter image description here

Hope this helps!

Score:1
es flag

Some of them may be sparse files; at least before they are copied. Some file managers don't copy sparse files correctly, i.e. they fill the "gaps" in the file with real zeroes, actually consuming that disk space. Thunar is one of them.

Unfortunately, it's not that trivial with standard tools to find out what files are in reality sparse files.

[sh @ balrog] .../work/test/sparse 11 % ls -l
total 1028
-rw-rw-r-- 1 sh sh 1049624576 Feb  5  2016 sparse-1MB.bin
-rw-rw-r-- 1 sh sh       8192 Jun 16  2020 sparse-8k
-rw-rw-r-- 1 sh sh       8192 Jun 16  2020 sparse-8k-zero
-rw-rw-r-- 1 sh sh 1048576000 Feb  5  2016 sparse-zero.bin

[sh @ balrog] .../work/test/sparse 12 % ls -lh
total 1,1M
-rw-rw-r-- 1 sh sh 1001M Feb  5  2016 sparse-1MB.bin
-rw-rw-r-- 1 sh sh  8,0K Jun 16  2020 sparse-8k
-rw-rw-r-- 1 sh sh  8,0K Jun 16  2020 sparse-8k-zero
-rw-rw-r-- 1 sh sh 1000M Feb  5  2016 sparse-zero.bin

[sh @ balrog] .../work/test/sparse 13 % ls -lhs
total 1,1M
1,0M -rw-rw-r-- 1 sh sh 1001M Feb  5  2016 sparse-1MB.bin
4,0K -rw-rw-r-- 1 sh sh  8,0K Jun 16  2020 sparse-8k
   0 -rw-rw-r-- 1 sh sh  8,0K Jun 16  2020 sparse-8k-zero
   0 -rw-rw-r-- 1 sh sh 1000M Feb  5  2016 sparse-zero.bin

QDirStat can tell you:

QDirStat showing sparse files

Thunar cannot:

Thunar showing sparse files

It shows you the wrong combined size; well, at least the wrong sizes before it mangles those files when it copies them, because then you will really need the full size, even though that's not at all necessary, and you won't have a true 1:1 copy of those files when Thunar is done messing with them.

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.