directory size info and reconfiguration on a linux file system

Hi

I am new to Linux and have been trying to install and configure it on a machine.  I currently have the following filesystem on Linux 2.4.21-37EL OS.  

df -k /tmp

Filesystem    1k-Blocks      Used           Available     Use%  Mounted On
/dev/hda2     37341064     2006512     33437680     6%     /

I need to ensure there is 400MB available on the tmp directory

when I perform a ls -la on / I get

drwxrwxrwx     13     root     root     4096     Feb     9     11:11      tmp

what does the 4096 relate to?
are there any limitations on the amount of space that tmp can use?  if so how do i determine what this is and how can i reconfigure it?

Thanks in advance
Keogh_bAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

ravenplCommented:
> what does the 4096 relate to?
to the size of the directory entry itself. You may think of directory as of a special file, which has directory entries inside.

> are there any limitations on the amount of space that tmp can use?  if so how do i determine what this is and how can i reconfigure it?
No. To limit that, You would need to put the /tmp on separate partition.
Keogh_bAuthor Commented:
So the tmp or any other file on the filesystem can grow as large as the available space?

So why is there a directory entry size, what purpose does it server if the directory can grow to the size of the available space?
ravenplCommented:
> So the tmp or any other file on the filesystem can grow as large as the available space?
Yes. But there may be some additional limits like per_user_quota

> So why is there a directory entry size, what purpose does it server if the directory can grow to the size of the available space?
As I said before. Directory is a special file. Inside the special file are entries (directory entries). Every name(and more) of file inside the dir must be kept somwhere. THis data is counted as directory size.
The more file/entries in the dir, the larger amount of space it will use.
You can test it by creating some large number of empty files within the dir.
[ also note, that on ext2/3 filesystem the size of directory only grows, never shrinks, one have to delete the dir and recreate to drop the dir diskspace usage down ]

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Linux

From novice to tech pro — start learning today.