Is there a limit to the number of files in /tmp?

Is there a limit to the number of files in /tmp?

Post by Thomas Da » Wed, 16 Apr 2003 05:24:24



recently my ultra60 gave an error saying could not start up another process
or something similar,
and in /var/adm/messages it said that tmp was full but it was only 20% full
but had thousands of zero length files that a cron job was duming into
there.  I rm the files and everything seemed to be working fine.  Is there a
limit to the number of files in the /tmp dir?
 
 
 

Is there a limit to the number of files in /tmp?

Post by Dave Uhrin » Wed, 16 Apr 2003 05:37:37



> recently my ultra60 gave an error saying could not start up another process
> or something similar,
> and in /var/adm/messages it said that tmp was full but it was only 20% full
> but had thousands of zero length files that a cron job was duming into
> there.  I rm the files and everything seemed to be working fine.  Is there a
> limit to the number of files in the /tmp dir?

What did 'df -e' tell you?

 
 
 

Is there a limit to the number of files in /tmp?

Post by Darren Dunha » Wed, 16 Apr 2003 10:42:12



> recently my ultra60 gave an error saying could not start up another process
> or something similar,
> and in /var/adm/messages it said that tmp was full but it was only 20% full
> but had thousands of zero length files that a cron job was duming into
> there.  I rm the files and everything seemed to be working fine.  Is there a
> limit to the number of files in the /tmp dir?

Yes there is (assuming you're using the default of a tmpfs filesystem
for /tmp).  It's mentioned somewhat in the man page..

# man tmpfs
File Systems                                           tmpfs(7FS)
[...]
     Another constraint is that the number of files available  in
     a   tmpfs  file  system  is calculated based on the physical
     memory of  the  machine   and  not  the  size  of  the  swap
     device/partition.   If  you  have too many files, tmpfs will
     print a warning message and you will be unable to create new
     files. You cannot increase this limit by adding swap space.

--

Unix System Administrator                    Taos - The SysAdmin Company
Got some Dr Pepper?                           San Francisco, CA bay area
         < This line left intentionally blank to confuse you. >

 
 
 

Is there a limit to the number of files in /tmp?

Post by Anthony Mandi » Wed, 16 Apr 2003 12:30:09



> Setup /tmp to be a real filesystem instead of tempfs ...

        Its tmpfs, Rolfie.

-am     ? 2003

 
 
 

Is there a limit to the number of files in /tmp?

Post by Mr Q. Z. Diabl » Wed, 16 Apr 2003 13:36:17





> > Setup /tmp to be a real filesystem instead of tempfs ...

>    Its tmpfs, Rolfie.

It's "it's", Tony...

;)

Mr Q. Z. D.
--
Drinker, systems administrator, wannabe writer, musician and all-round bastard.
"They've got to be protected/All their rights respected          ((o))
 Until someone we like can be elected." - Tom Lehrer             ((O))

 
 
 

Is there a limit to the number of files in /tmp?

Post by Anthony Mandi » Wed, 16 Apr 2003 19:01:57



Quote:> > > Setup /tmp to be a real filesystem instead of tempfs ...

> >       Its tmpfs, Rolfie.

> It's "it's", Tony...

        Its whatever I say it is, L. Diablo.

-am     ? 2003

 
 
 

Is there a limit to the number of files in /tmp?

Post by Chris Thomps » Wed, 16 Apr 2003 22:31:24





>> recently my ultra60 gave an error saying could not start up another process
>> or something similar,
>> and in /var/adm/messages it said that tmp was full but it was only 20% full
>> but had thousands of zero length files that a cron job was duming into
>> there.  I rm the files and everything seemed to be working fine.  Is there a
>> limit to the number of files in the /tmp dir?

>Yes there is (assuming you're using the default of a tmpfs filesystem
>for /tmp).  It's mentioned somewhat in the man page..

># man tmpfs
>File Systems                                           tmpfs(7FS)
>[...]
>     Another constraint is that the number of files available  in
>     a   tmpfs  file  system  is calculated based on the physical
>     memory of  the  machine   and  not  the  size  of  the  swap
>     device/partition.   If  you  have too many files, tmpfs will
>     print a warning message and you will be unable to create new
>     files. You cannot increase this limit by adding swap space.

But you can do so by patching tmpfs_maxkmem in /etc/system.

The "limit on inodes" is really a limit on the amount of kernel memory
used to store "inodes", directory entries, and symlink targets. For
the benefit of statvfs(2) the amount of kernel memory used and the limit
are converted into an inode count by dividing by the amount used by
a regular file with a shortish name. This is what "df -t /tmp",
"df -e /tmp" etc. displays.

The other thing to bear in mind is that this usage and limit applies
to all existing tmpfs filing systems combined. In Solaris 8 or later,
for example, "df -t /tmp /var/run" will show the same inode statistics
for both filing systems.

Chris Thompson
Email: cet1 [at] cam.ac.uk

 
 
 

1. How to limit the use of /tmp and /var/tmp by arbitrary users


|How can I limit or disable naughty users to write large file to /tmp or
|/var/tmp?

Disk quotas?

--
------------------------------------------------------------------------

Unsolicited bulk or commercial email is not welcome.             netcom.com
No warranty of any kind is provided with this message.

2. Sleepy Computer! <Yawn>

3. I am buying an Ultra 5 but am lost in part numbers ....

4. X on CGA - possible? :-)

5. WARNING: /tmp: File system full, swap space limit exceeded

6. NIS+

7. Maximum file number under /tmp

8. How to load video driver.

9. mailx: /tmp: Bad file number

10. WARNING: /tmp: File system full, swap space limit exceeded

11. /tmp vs /usr/tmp vs /var/tmp

12. find /tmp -atime +1 | rm does not delete my old tmp files :-(

13. FILE LIMITS AIX 4.3 limits file, original config etc