John Reiser wrote:
> On 3/16/21, David Howells wrote:
> > John Reiser wrote:
> >
> >> See the manual page "man 2 getdents".
> > Um, which bit? I don't see anything obvious to that end.
>
> On that manual page:
> =
> The system call getdents() reads several linux_dirent structures from the
* Steven Whitehouse:
> If you are looking for a hint on how large a buffer to allocate, then
> st_blksize is generally used as a hint for directory reads, or
> otherwise, a fixed size buffer or a page or two. The st_size field is
> meaningless for directories and you'll get all kinds of odd resul
On 3/16/21 11:51 AM, John Reiser wrote:
> On 3/16/21, David Howells wrote:
>> John Reiser wrote:
>>
>>> See the manual page "man 2 getdents".
>>
>> Um, which bit? I don't see anything obvious to that end.
>
> On that manual page:
> =
> The system call getdents() reads several linux_dirent st
Hi,
On 16/03/2021 16:51, John Reiser wrote:
On 3/16/21, David Howells wrote:
John Reiser wrote:
See the manual page "man 2 getdents".
Um, which bit? I don't see anything obvious to that end.
On that manual page:
=
The system call getdents() reads several linux_dirent structures from
On 3/16/21, David Howells wrote:
John Reiser wrote:
See the manual page "man 2 getdents".
Um, which bit? I don't see anything obvious to that end.
On that manual page:
=
The system call getdents() reads several linux_dirent structures from the
directory
referred to by the open file d
John Reiser wrote:
> See the manual page "man 2 getdents".
Um, which bit? I don't see anything obvious to that end.
On AFS directories are handled as files that the filesystem downloads and
parses locally. The size returned in st_size is the size of the directory
content blob.
David
On 2/26/21 7:07 AM, Eric Sandeen wrote:
In short, "size" of a dir doesn't tell you much.
In ext4 it tells you (proportionally to other dirs) how many files
you have got at maximum in that directory in its entire history. :-)
Regards.
--
Roberto Ragusamail at robertoragusa.it
_
* Eric Sandeen:
> So, as one example on ext4 - directories never shrink.
> # rm -f dir/*
> # ls -ld dir
> drwxr-xr-x. 2 root root 69632 Feb 26 00:49 dir
>
> 69632 byte directory with no files in it, wh.
e2fsck -D will shrink such directories in an offline operation, I think.
Thanks,
Florian
Dnia Thu, Feb 25, 2021 at 06:20:34PM -0300, Sergio Belkin napisał(a):
> Hi,
> Tools such as ls or stat report the size of a directory. Of course it is
> not the content size.
It depends on the filesystem. For Cephfs, directory size _is_ the content
size:
% ls -lh
drwxrwxr-x. 3 zdzichu zdzichu
On 2/25/21 6:56 PM, John Reiser wrote:
>> Tools such as ls or stat report the size of a directory. Of course it is not
>> the content size.
>> stat -c %s /home/sergio/.config
>> 6550
>>
>> What does 6550 mean in btrfs context?
>
> Regardless of filesystem type, the size of a directory is the sum
El jue, 25 feb 2021 a las 21:58, John Reiser ()
escribió:
> > Tools such as ls or stat report the size of a directory. Of course it is
> not the content size.
> > stat -c %s /home/sergio/.config
> > 6550
> >
> > What does 6550 mean in btrfs context?
>
> Regardless of filesystem type, the size of
Tools such as ls or stat report the size of a directory. Of course it is not
the content size.
stat -c %s /home/sergio/.config
6550
What does 6550 mean in btrfs context?
Regardless of filesystem type, the size of a directory is the sum of the sizes
of the struct linux_dirent (or linux_dirent6
On Thu, Feb 25, 2021 at 2:21 PM Sergio Belkin wrote:
>
> Hi,
> Tools such as ls or stat report the size of a directory. Of course it is not
> the content size.
> stat -c %s /home/sergio/.config
> 6550
>
> What does 6550 mean in btrfs context?
stat -c %s reports the st_size of the directory in
I know next to nothing about btrfs, but on ext family of filesystems,
directories are technically just special files. Those files contain a simple
list of directory entries (i.e. filename <-> inode number pairs). So I guess in
the case of ext, stat reports the size of this list.
Hi,
Tools such as ls or stat report the size of a directory. Of course it is
not the content size.
stat -c %s /home/sergio/.config
6550
What does 6550 mean in btrfs context?
Thanks in advance!
--
--
Sergio Belkin
LPIC-2 Certified - http://www.lpi.org
_
15 matches
Mail list logo