Answer the question
In order to leave comments, you need to log in
Where did the place in the empty directory go and how to see it?
(see the addition below, the situation has become simpler and more mysterious)
I accidentally noticed that I have one of the almost empty directories (only 5 files, the maximum file size is 254 bytes, they weigh 528 bytes in total, 8 directories) - but the du directory weighs as much as 2.8 megabytes . Root filesystem, ext4. A trifling size, but I wonder where such a wild overhead comes from? (I am aware of the cluster size, if anything, but this cannot explain the phenomenon)
[email protected]:~/locker-apps/test/users-OLD$ du -sh
2.8M .
[email protected]:~/locker-apps/test/users-OLD$ ls -al
total 2768
drwxr-xr-x 1 xenon xenon 2813952 Feb 11 20:49 .
drwxr-xr-x 6 xenon xenon 4096 Feb 10 22:52 ..
drwxr-xr-x 5 xenon xenon 4096 Jan 15 01:39 a
drwxr-xr-x 5 xenon xenon 4096 Feb 10 22:21 b
[email protected]:~/locker-apps/test/users-OLD$ du -sh a
32K a
[email protected]:~/locker-apps/test/users-OLD$ du -sh b
20K b
[email protected]:~/locker-apps/test/users-OLD$ tree -h
.
|-- [4.0K] a
| |-- [4.0K] r
| | |-- [ 254] userinfo.json
| | `-- [ 254] userinfo_create.json
| |-- [4.0K] rw
| | |-- [ 10] notebook.txt
| | `-- [ 5] test.txt
| `-- [4.0K] s
`-- [4.0K] b
|-- [4.0K] r
|-- [4.0K] rw
| `-- [ 5] notebook.txt
`-- [4.0K] s
8 directories, 5 files
[email protected]:~/locker-apps/test$ cp -a users-OLD/ /tmp/
[email protected]:~/locker-apps/test$ du -sh /tmp/users-OLD/
56K /tmp/users-OLD/
[email protected]:~/locker-apps/test/users-OLD$ ls -al
total 2760
drwxr-xr-x 1 xenon xenon 2813952 Feb 11 22:22 .
drwxr-xr-x 6 xenon xenon 4096 Feb 10 22:52 ..
[email protected]:~/locker-apps/test/users-OLD$ du
2756 .
[email protected]:~/locker-apps/test/users-OLD$ du --apparent-size
2748 .
Answer the question
In order to leave comments, you need to log in
Judging by the line
drwxr-xr-x 1 xenon xenon 2813952 Feb 11 20:49 .
in this directory at some point there were a lot (thousands) of files.
In ext2/3/4, a directory is such a "special file" that contains the names (and something else) of the files it contains. And if there are a lot of them, then the catalog itself will be large. But at the same time, there is no mechanism for reducing the size of the directory.
The standard option is to copy all the files from it to a new directory, delete this one and move the new one in its place.
perhaps a file was deleted from the directory that continues to hold the application?
try
lsof | grep-delete
Look at the output of the command
Perhaps the files in the directory have been deleted, but they are actually still in use by some application and therefore take up disk space.
lsof | grep '(deleted)'
Problem due to cyrillic characters in path to gulpfile.js (Username) C:\Users\ KuziaAser \Downloads\OpenServer\domains\potokblue
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question