Linux And Lag
zippy
Forum Police. Join Date: 2003-01-06 Member: 11956Members, Constellation
I have a linux server (2Ghz 1GB RAM) redhat 7.2 running NS
i can't play bast or hera on it, dam annoying, cpu usage <!--emo&:(--><img src='http://www.unknownworlds.com/forums/html/emoticons/sad.gif' border='0' style='vertical-align:middle' alt='sad.gif'><!--endemo-->
also in smalled standard maps turrets are a major lag whether it's alien's or marine's.
what tweaks can i do to sort this out.
zippy
i can't play bast or hera on it, dam annoying, cpu usage <!--emo&:(--><img src='http://www.unknownworlds.com/forums/html/emoticons/sad.gif' border='0' style='vertical-align:middle' alt='sad.gif'><!--endemo-->
also in smalled standard maps turrets are a major lag whether it's alien's or marine's.
what tweaks can i do to sort this out.
zippy
Comments
Look at your system setup and try to figure out where the "lag" is coming from. For that, try answering these questions:
1) Is your Maxplayers set to more then your CPU can handle. (2Ghz CPU shouldn't have more then 14-16 players for "low" ping)
2) Do you have more maxplayers then your bandwidth can handle, both upstream and downstream.
3) Do you have other applications running in the background taking up CPU cycles such as messageboard systems, etc.
4) Is your maxrate set too low not allowing the server to send more then xxxx amount of data. When there are a lot of things in a confined area bandwidth usage for updating goes up.
You can get optimized map from <a href='http://www.joe.to/ns/' target='_blank'>http://www.joe.to/ns/</a>
Also, when you installed redhat did you install everything or just the essentials. I believe full redhat can be more cpu intensive then windows.
currently it's on 18+reservered
pings are fine at start like any normal server, it's gotta be something to do with ns arghhh the pain.
don't make me have to turn it into a dod and cs server
or a nice 32 player dod <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
zippy
Also, there is nothing else running on the box but apache to serve up a stats page.
(I admin the server in question for zippy. =))
You forgot to tell us your connection, but just in case thats the problem keep in mind you should allow at least 3-4kbps per person (both up and down) and 5-10 for a bit more comfort in my experience. The average Cable and DSL connection is capped at ~50k or ~128k respectively. Thats ~8 players comfortably on the Cable and and a bit less then double that on the DSL. Just in case thats the problem...
Now it seems more likely that CPU-usage is the problem. Disable XWindows and Gnome/Sawfish/KDE (whatever you chose). Your average GUI + XWindows is a resource hog, although the new Mandrakes and Redhats do look awful perdy <!--emo&:p--><img src='http://www.unknownworlds.com/forums/html/emoticons/tounge.gif' border='0' style='vertical-align:middle' alt='tounge.gif'><!--endemo-->. Disable them and boot directly to the comm line where you have to open up a new term. If you end up needing Xwin/a GUI you can still start 'em up from the term using start xwin or something like that (its been ages since I've used a GUI *nix side, let alone had to start one manually).
Also, someone suggested upping the priority of the hlds process. Try it, can't hurt. Those 2 things together should increase performance.
A last issue, make sure you don't have dual processors! I don't know if your 2Ghz is from a one processor, or multiples. If its the latter, remember as of current HLDS releases, HLDS can only be run with one processor. Meaning, if you have 2 1Ghz processors, HLDS can really only use 1 Ghz.
Keep all that in mind, try it all out, I almost guarantee performance increases.
How do I go about upping the priority of HLDS?
I don't run any X-windows etc on teh box, just SSH in.
And I got those maps from joe.to I will see if that helps.
renice - alter priority of running processes
SYNOPSIS
renice priority [[-p] pid ...] [[-g] pgrp ...] [[-u] user ...]
<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
AS ROOT, regaurdless of what you run hlds as.
<!--QuoteBegin--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin-->renice -20 4993<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
just so you know
<!--QuoteBegin--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>QUOTE</b> </td></tr><tr><td id='QUOTE'><!--QuoteEBegin--> Range
goes from -20 (highest priority) to 19 (lowest).<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
i ain't talking ethernet here boy <!--emo&:p--><img src='http://www.unknownworlds.com/forums/html/emoticons/tounge.gif' border='0' style='vertical-align:middle' alt='tounge.gif'><!--endemo-->
zippy
it maybe close to 100mbs (thats 1562.5 64K channels) but i seriously doubt that an hosting company would pay for all that for what you pay a month <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo-->
I really don't think bandwidth is the issue. Its CPU. =/ Just did that renice thing on my hlds process to test it.
HOWEVER: With a 2Ghz CPU, you should be hosting 20-player games with some left over cycles for sure and no perceptable user 'lag'. The Fist of Ra test servers run more players than that in your config, and they are silky. I'd advise getting some more advice from Jack and others here about possible Linux tuning options. If it was a Win32 server, I'd suggest talking to... me. <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
And I'll wager you're getting this idea about the 100Mbit interface from looking at what speed your NIC is reporting back that it's capable of, or the bogus 'connected at 100/full duplex' value that win32 NIC's often reply with when jacked into broadband. Jack is right that there is no such thing in WAN terms. Maybe if they bonded 2 SONET OC-1's? You'd get 100.224 CIR in that scenario...
even if they did that, i doubt he has full access to it <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo-->
even if they did that, i doubt he has full access to it <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo--><!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
<!--c1--></span><table border='0' align='center' width='95%' cellpadding='3' cellspacing='1'><tr><td><b>CODE</b> </td></tr><tr><td id='CODE'><!--ec1-->telnet my.big.router
Trying some.ip.add.ress...
Connected to my.big.router
Escape character is '^]'.
User Access Verification
Username: verbose
Password:
This is a private computer facility. Any unauthorized access is
strictly prohibited and may be a violation of respective local and/or
federal laws.
Unauthorized access will be prosecuted to the fullest extent allowed
by applicable laws.
big.router
big.router>en
Password:
big.router#conf t
Enter configuration commands, one per line. End with CNTL/Z.
big.router(config)#int ser 1/0
big.router(config)#dsu bandwidth 105266<!--c2--></td></tr></table><span class='postcolor'><!--ec2-->
Voila. 100 megabit connection. Well, DOWN to 100 megabit, which isn't very cool, but...
big.router(config)#dsu bandwidth 105266<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
wouldn't they use subinterfaces instead? i mean, thats kinda pricey to limit an emtire serial link to 100mbit just for him <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo-->
oh btw we used shell access to make the server dl NS for it's self, 1070kbps <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
zippy
big.router(config)#dsu bandwidth 105266<!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
wouldn't they use subinterfaces instead? i mean, thats kinda pricey to limit an emtire serial link to 100mbit just for him <!--emo&;)--><img src='http://www.unknownworlds.com/forums/html/emoticons/wink.gif' border='0' style='vertical-align:middle' alt='wink.gif'><!--endemo--><!--QuoteEnd--></td></tr></table><span class='postcolor'><!--QuoteEEnd-->
To limit to 100Mbit...take away his gig card, and hand him a $15 Linksys. Why do it in software when you can do it in hardware <!--emo&:)--><img src='http://www.unknownworlds.com/forums/html/emoticons/smile.gif' border='0' style='vertical-align:middle' alt='smile.gif'><!--endemo-->
Im running 2, 18 person servers on a dual 1.266ghz IBM X330 on a 1.1mb SDSL line. I do (finally) have each of the servers bound to an individual CPU.
I get between 40-80ms (straight ping to the server gives me about 30-35ms). There is the occasional spike to 250ms when someone goes nuts with a turret farm or 6 hmg's go off on a hive at once, but its typically quite decent.
All running on a W2K server. I was looking at Linux (lots of questions in the nsserver channel) but haven't had the time to go back to it. I really would like to go to Linux once the CPU utilization gets down somewhat. Im a bit afraid after hearing that a 2ghz system cant handle an 18 person server.
/me stares dreamily in the distance for v1.1.
On an off topic, I got a lovely new tool to monitor cpu/bandwidth. Going to set it up for my servers as soon as I get a chance (leaving the country for a week).