Too many open files
From AzureusWiki
Symptom: After using Azureus for a while, you get messages popping up, saying that you couldn't open (some random file) because there are too many open files.
Make sure you are running 2.1 series version before you try changing anything, as it has fixed this problem for most people !
Problem: There are too many open files. (Well, duh.) Under unix, lots more things are files then might appear that way at first. The connection to your X server is a file, at least in as much as this error cares. Connections to trackers and peers (including seeds) are files, the files you're downloading are files (OK, no big surprise on that one), etc, etc. In Azureus, the two main reasons for this error are a) the downloads you are running have many files in them, and b) you are connected to many many other clients (i.e. network socket connections).
You can tell Azureus to only keep a limited number of file handles open by setting the Configuration->Files->Performance Options: Maximum files opened for read/write to something like 20.
To limit the number of socket handles consumed by Azureus, set the Configuration->Transfer: Maximum number of connections options to something less than 1000.
This should reduce the chances of seeing this error message. However, if you still reach the handle limit regularly, you can set the kernel limits higher:
Normaly, processes, at least on linux, are limited to 1024 file handles each (most unixes will have a similar limit). This, however, is changable, which gives us our workaround. It's only changable by root, which creates some caveats on our workaround. The first caveat is that you must have root access. The second is that I'm only going to give a recepie for using sudo, not su, because I use sudo, and not su. (Note that this does not cause Azureus to run as root.)
The workaround: sudo bash -c 'ulimit -n 8192; sudo -u username ./azureus'
(This assumes you want Az to run via the user 'username'. It also assumes that you are in the right directory. Edit it to match local reality.)
To change the limit globally, you can edit /etc/security/limits.conf file.
Note that Azureus will still complain if it gets to 8192 open handles, rather then only 1024, but 8192 should be more than enough for even the craziest of downloaders...
See http://sourceforge.net/tracker/index.php?func=detail&aid=811406&group_id=84122&atid=575154 for original info.
