question about reported directory size

Dan Nelson dnelson at
Wed Feb 23 18:24:41 GMT 2005

In the last episode (Feb 23), Robert Huff said:
> huff@>> dir /usr/lost+found/
> total 192
> drwxrwxrwt   2 root  wheel  194048 Feb 23 13:01 .
> drwxr-xr-x  22 root  wheel     512 Feb 23 03:38 ..
> 	Now I understand the 't' in the permissions ... sort of.
> 	a) does this mean the reported directory size will never
> 		shrink?
> 	b) is that the actual blocks in use, or an artifact?
> 	c) is is safe to delete and recreate the directory?

A directory is only truncated on the first file create after a delete;
this optimizes the common rm -rf case.  Touch a dummy file in there and
check the size again.

	Dan Nelson
	dnelson at

More information about the freebsd-questions mailing list