-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Salut
Am urmatoarea secventa de cod:
extern int get_socket_limit(void)
{
unsigned int socklimit = BNETD_MAX_SOCKETS;
#ifndef WIN32
struct rlimit rlim;
if(getrlimit(RLIM_NUMFILES, &rlim) < 0)
eventlog(eventlog_level_error, "get_socket_limit", "getrlimit returned
error: %s", strerror(errno));
else if(rlim.rlim_cur < socklimit)
socklimit = rlim.rlim_cur;
#else
/* FIXME: somehow get WSAData win32 socket limit here */
#endif
#if !(defined HAVE_POLL || defined HAVE_KQUEUE || defined HAVE_EPOLL)
if(FD_SETSIZE < socklimit)
socklimit = FD_SETSIZE;
#endif
/* make socket limit smaller than file limit to make sure log files,
db connections and save files will still work */
socklimit -= 64;
eventlog(eventlog_level_debug, "get_socket_limit", "limit: %d", socklimit);
return socklimit;
}
Problema e ca eventlog nu raporteaza mai mult de 4032 indeiferent ce ii
fac. Daca am ulimit -n 1024 zice corect. Daca am ulimit 4096 zice 4032
(corect). Daca am ulimit 8192 zice tot 4032. Banuiesc ca mai e o limita pe
undeva (probabil hardcoded prin kernel). Unde sa caut/modific ?
PS: the funny thing e ca si pe un FreeBSD (cred ca) face la fel
- ----------------------------
Mihai RUSU Email: [EMAIL PROTECTED]
GPG : http://dizzy.roedu.net/dizzy-gpg.txt WWW: http://dizzy.roedu.net
"Linux is obsolete" -- AST
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)
iD8DBQE/qCntPZzOzrZY/1QRArdHAJwIwaEMErvkBsva85PNB3/a5f8UagCgqJ4A
Nc0cEDEp2e2CcNffMUw/PaU=
=FNCc
-----END PGP SIGNATURE-----
---
Detalii despre listele noastre de mail: http://www.lug.ro/