Miscalculates folder size [$50]

Bug #1200787 reported by 982c80311320c1b
46
This bug affects 9 people
Affects Status Importance Assigned to Milestone
Files
Fix Released
Medium
meese

Bug Description

I selected everything in my root folder, which added up to 140.7 Terabyte. The progress bar shows the correct value.

Related branches

Revision history for this message
982c80311320c1b (alexander-wilms) wrote :
Changed in pantheon-files:
status: New → Confirmed
Cody Garver (codygarver)
Changed in pantheon-files:
milestone: none → 0.3-beta1
importance: Undecided → Medium
Revision history for this message
José M. Benítez (jmiguelbenitez) wrote :

I am not able to reproduce this bug. How did it happen? Maybe because the external drive was unmounted?

Is it still happening to anyone?

Revision history for this message
José M. Benítez (jmiguelbenitez) wrote :

Ok, I was able to reproduce the bug in the end. I tried with an external hard drive and everything went fine (see the previous comment). However, the size goes crazy when I plug my phone.

Bad news is "du" calculates the same (wrong) amount. Or this is good news, I don't know.

I'll try to search for more information.

Cody Garver (codygarver)
Changed in pantheon-files:
assignee: nobody → elementary UX Team (elementary-design)
Cody Garver (codygarver)
Changed in pantheon-files:
milestone: isis-beta1 → isis-beta2
Revision history for this message
Paweł Kowalik (pkowalik) wrote :

I'm getting exactly the same result, while using only one 500 GB hard disk with separate / and /home partitions.

Revision history for this message
Danielle Foré (danrabbit) wrote :

Is there a reason this is assigned to UX team? Sounds like a purely technical problem

Changed in pantheon-files:
assignee: elementary UX Team (elementary-design) → nobody
Revision history for this message
Danielle Foré (danrabbit) wrote :
summary: - Miscalculates folder size
+ Miscalculates folder size [$50]
Revision history for this message
Danielle Foré (danrabbit) wrote :
Revision history for this message
Lewis Goddard (lewisgoddard) wrote :

Test:
Try running `ls -l /proc/kcore`
For me, the last line will report that that "file" is 140737486266368 bytes in size.
In actual fact is it almost nothing, and is used to view into the kernel.

Summary:
Sparse files list the size in the header, and some are silly.
This makes `du`, while more efficient because of the header checking,
vulnerable to repeating this silliness as fact.

References:
http://superuser.com/questions/349715/why-are-the-proc-and-sys-folders-more-than-100-tb-in-size
http://en.wikipedia.org/wiki/Sparse_file

Revision history for this message
Stinger (e-mindahl) wrote :

I'm getting exactly the same result, while using only one 320 GB hard disk with separate / and /home partitions.
Confirming bug.

Revision history for this message
Stinger (e-mindahl) wrote :

Re #8
Took a screenshot of the properties from the /proc/kcore

meese (meese)
Changed in pantheon-files:
status: Confirmed → In Progress
assignee: nobody → meese (meese)
RabbitBot (rabbitbot-a)
Changed in pantheon-files:
status: In Progress → Fix Committed
Changed in pantheon-files:
status: Fix Committed → Fix Released
Cody Garver (codygarver)
Changed in pantheon-files:
milestone: freya-beta2 → 0.2
Revision history for this message
Morgan Risch (morgan-risch) wrote :

Bug seems to have reappeared in Loki.

Revision history for this message
Zisu Andrei (matzipan) wrote :

Hey Morgan,

Can you please file a separate bug?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.