0

My computer complained about no space left on device. I used du -hs * | sort -h to identify the biggest folders and kept going down the tree. I then found multiple directories I've been recently scp-ing to, all following this patten:

(base) user@computer:pathtodir$ du -hs
3.4G    .
(base) user@computer:pathtodir$ du * -hs
217M    checkpoint.pth.tar
127K    code
835     log.txt

From what I understand, these numbers should be adding to the same, yet there are 3.1G missing. I do not expect much to be within the code folder nor other files. The checkpoint.pth.tar file has been scp-ed with multiple versions on top of each other.

1

Apparently, I was missing the dotfiles, I should have also done du -hs .[^.]* instead to find them.

1
  • 1
    ... or shopt -s dotglob followed by your original du -hs * (note that options come before operands). – Kusalananda Nov 16 '20 at 7:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.