[mdlug] Help: Changing open file limits on Ubuntu 8.04

Aaron Kulkis akulkis00 at gmail.com
Fri Mar 27 18:28:29 EDT 2009


Michael wrote:
> Hey all;
> I am at my wits end on this problem on one of my Web servers that also hosts
> my NFS mounts. I am asking here out of last resort because my Google-fu has
> failed me.
> 
> It appears as though I am running out of available open file descriptors.
> The current set up is only allowing 1024. My big user: www-data is also
> under the same limits. This is causing quite a bit of latency on the server,
> which might come under quite a bit of load.
> 
> So far, I have made sure to place in /etc/security/limits.conf:
> 
> 
> *   hard    nofile  65536
> *   soft    nofile  65536
> 
> 
> I also updated sysctl.conf:
> 
> 
> fs.file-max = 65536
> 
> 
> After sysctl -p I can
> 
> $ cat /proc/sys/fs/file-max
> 65536
> 
> 
> but ulimit -n still reads 1024. And trying to set it leads to errors:
> 

Non-root users can only LOWER their ulimits.

For the new limits to take effect, I believe you'll have to reboot.

> $ ulimit -n 65536
> -bash: ulimit: open files: cannot modify limit: Operation not permitted




More information about the mdlug mailing list