Jump to content
Sign in to follow this  
JoeCool42

linux server multithreaded ?

Recommended Posts

We are running an OFP CRCTI server and got an dual opteron system for this job, but although the linux OFP server seems to be multithreaded (he starts 6 processes), he uses only one thread to do his job :-(

I there an option or possibility to tell the ofpserver to run on 2 or more cpus ?

Share this post


Link to post
Share on other sites

its not running on 6 threads and its not possible to run ofp on more than one cpu threads since the server is just not written for that

Share this post


Link to post
Share on other sites
its not running on 6 threads

Are you talking about linux dedicated server or windows?

On linux he starts 6 processes, but working does only one. For what are these processes, if only one is really working ?

I hopped some guys from Bohemia could drop a note here. I can't imagine that you dont know how your server works xmas_o.gif

It would be also very nice, if you could recompile the server with new libs. It took hours to find out which ancient libs the server needs.

Share this post


Link to post
Share on other sites
It would be also very nice, if you could recompile the server with new libs.

It's very unlikely that this will happen. If you are planning to run the server public (i.e. not passworded), you should probably look into running the win32 1.96c server on wine. Here is a description on how to set this up.

Share this post


Link to post
Share on other sites

s.o.s is right, multithreaded software does not imply to compute particular threads or processes on different cpus' or cores automatically. e.g the directshow api starts up 4 threads after creating the graphs etc., what does not mean the program will use multiprocessors or multicores automatically. so ofp is starting 6 threads yes, but that does not mean the ofp process was started 6 times and can run on 6 different cores or cpus. it just means, that the mainprocess swaps out 6 threads (networking, music, sound and so on) which share cputime from a single cpu, just to pretend to run independently from each other (its not running parallel, its time-shared). just imagine you want to fade out a current running music in your gameloop by decreasing its volume with a sleep function to halt every 20th millisecond, what would create a fade. if you wont use a own thread for this feature, the whole gameprocess will start halting every 10th millisecond. this thread runs on the very same machine like the ofp mainprocess, what makes ofp a multithread game but with the restriction to run on just a single cpu! you see the difference?!

the music example is a little bit silly, because you would use a timer instead of a sleep() function of course ... huh.gif

Share this post


Link to post
Share on other sites

Yup it starts 6 "threads/processes".

Unfortunately simulation only happens in one thread.

There are two other threads/processes that use some cpu also so it's a slight win to have multiple cpus anyway.

Some of these processes appear to be able to work without waiting for eachother. But there just isn't very much for the other threads to do (one appears to be networking). smile_o.gif

The good news here is that OFPs design where objects are local to a certain client should make it very easy to split AI simulation onto more threads. So perhaps we'll see a better multithreaded server for Arma. we can only hope. smile_o.gif

Here's a cpu usage output from my server right now (12 vs 12 CTI), 97 20 and 1 is cpu usage %

Quote[/b] ]

19472 ofp 25 0 218m 205m 4944 R 97 20.3 530:04.12 server

19475 ofp 15 0 218m 205m 4944 S 20 20.3 23:02.51 server

19474 ofp 15 0 218m 205m 4944 S 1 20.3 16:07.23 server

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×