Skip to main content

how to reduce number of threads for relay peer

1 reply [Last post]
henno_b
Offline
Joined: 2010-09-03
Points: 0

I am trying to install a proper relay/rendezvous peer on a webserver that I rent (...cheaply) by a perfectly normal internet service provider. Unfortunately, the number of processes and native threads that one is allowed to create on such a server is much too low (namely 96) for starting relay/rendezvous services, in fact it already crashes during start-up when trying to create the peergroups (thread pools, etc.). I have a few questions related to this topic, and I have not found useful answers anywhere on the web:

(QUESTION 1) does this problem also happen if I would run on a Windows server? my provider offers me to reinitialize the server from current Suse 11.3 to Windows 2008, but I would first like to be sure that this solves the issue before porting the whole site.

(QUESTION 2) (...i think i already know the answer to this one) is there any way to force green threads on a linux JVM, instead of using native threads? as far as I understand, this is completely impossible since java 3 and later, all linux threads are native. Can I make java threads "green" by encapsulating the entire java application + JVM in a C++ program, using JNI? Would the jxta.jar stuff still work in that case (I mean, has that ever been tried)?

(QUESTION 3) how do other people operate relay peers, then? Surely you must all run into this kind of problems, or are you all spending big money on hugely oversized corporate servers, just to have a higher threadcount limit? I really don't need e.g. 32 processors and 10 terrabytes of server storage, but i would still be forced to pay for that.

By the way, my relay peer and entire JXTA-based P2P application are running nicely on local machines, so that does not seem to be the problem. However, without a public IP address somewhere in the world it is close to being useless.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
henno_b
Offline
Joined: 2010-09-03
Points: 0

solved my own problem - it turned out that this "server" that I rented was a bit of a joke. The provider offers these cheap servers that actually run inside a virtual machine so that they can host a whole bunch of small servers on one actual server computer - hence the limitation of number of process threads, which is simply a fraction of the limit of their host operating system.

So - I upgraded to a completely oversized 250 GB disk / 4 core 64 bit @ 4GB RAM root server to run my 1 MB RAM relay/rendez-vous peer.

Guess what - it worked the first time. JXTA rocks!