How do I exclude directories when listing files in the current directory?
ls .
^ will include directories in the listing.
I'm using zfs on my FreeBSD 9.0 x64 and pretty happy with it, but I find it hard to count directory real, not compressed, size.
Surely I can walk over the directory and count every file size with ls, but I'd expect some extra key for du for that purpose.
So, how can I tell the directory size for dir placed on zfs with compression on?
Thamk you in advance for the advice, I simple can't rememeber there is no such a 'simple' way, without 'find ./ -type d -exec ls -l '{}' \; | awk ...'!
I am having a difficult time grasping what is the correct way to read the size of the files since each command gives you varying results. I also came across a post at http://forums.devshed.com/linux-help-33/du-and-ls-generating-inconsistent-file-sizes-42169.html which states the following;
du gives you the size of the file as it resides on the file system. ( IE will will always give you a result that is divisible by 1024 ).
ls will give you the actual size of the file.
What you are looking at is the difference between the actual size of the file and the amount of space on disk it takes. ( also called file system efficiency ).
What is the difference between as it resides on the file system and actual size of the fil
In Ubuntu 10.10, showing a file listing using ll
will occasionally show files with a * appended to the name of the file. What does this star mean?