AMARANT

Server lags

Recommended Posts

Please guys help me out to solve my problem. The thing is that my server starts to lag if it has 10-12+ people online. The lags are like: delay on sending chat message, on starting vehicle engine, turning on/off lights, even entering a vehicle and so on.

Here is a screenshot of my server CPU usage given by performancebrowser:

http://i.imgur.com/PGMq3g3.jpg

I assume it's because of using much element data or bad hosting but I don't know how to check it :( I can give more information if you need, just tell me. Thanks in advance.

Share this post


Link to post

did you try to check /debugscript 3? maybe there are spamming errors that makes the people lag when they enter the vehicles. Check it up that might help!.

Share this post


Link to post
did you try to check /debugscript 3? maybe there are spamming errors that makes the people lag when they enter the vehicles. Check it up that might help!.

Of course, I always use debugscript. It's clear and there are no any errors or warnings. I can't figure out what else may cause these lags because scripts seem OK. I don't experience any FPS drop or something. It's just some delays.

Share this post


Link to post
Do the players pings fluctuate?

Ping is okay too, 50-150. It's very strange and I don't know what to do :(

Share this post


Link to post

It's your host then, although there is not high CPU usage it is still throttling the CPU, causing the lag.

Share this post


Link to post

Can high client CPU usage affect these lags? Because I see some resources with "onClientRender" and "onClientPreRender" eat 4-5% CPU.

Share this post


Link to post

Is there anyway you can can get the cpu graphs of the actual server box? Although performance browser shows the scripts usage, there could be something else on the host box eatting up the CPU. Or it could be memory or something such as that.

Share this post


Link to post
Is there anyway you can can get the cpu graphs of the actual server box? Although performance browser shows the scripts usage, there could be something else on the host box eatting up the CPU. Or it could be memory or something such as that.

Unfortunately, I only can see a small piece of information provided by my hosting services. It shows there that my server eats:

  • - 6-7% CPU
    - 0.2% RAM
    - 6% Hard drive

I can give a screenshot of my client scripts from performancebrowser if it's needed.

Share this post


Link to post

What the box says your server use if kind of irrelevant assuming you're on a shared host, in that case the lag might be caused by someone else on the same box. Lag spikes are usually also caused by lack of CPU, is it a cheap host? if so then they probably oversell a lot.

Share this post


Link to post

It's hard to guess without specific information's. It could be bandwidth, cpu , latency.

http://www.aidanfinn.com/?p=9566

Did you Add a rate-limit option for that specific port, but a rate-limit will not distinguish between good or bad traffic. Meaning if an attack comes in it's very possible it'll flood out legitimate traffic.

I've seen lot's of people trying to protect themselves from DOS by limiting incoming packets.

If you did that, It would be best to attempt to filter said traffic by analyzing the packet contents and forming a block rule.

So if this is what you did, blocking packets by specific patterns or types will be the most effective, as long as the traffic pattern doesn't also match traffic needed by the server.

Use netsh to capture IPsec events.

Did you change some HKEY on your system ?

Here some good value you can add.

hkey_local_machine \system \currentcontrolset \services \tcpip \parameters \synattackprotect=1 REG_DWORD

hkey_local_machine \system \currentcontrolset \services \tcpip \parameters \tcpmaxconnectresponseretransmissions=2 REG_DWORD

hkey_local_machine \system \currentcontrolset \services \tcpip \parameters \tcpmaxdataretransmissions=3 REG_DWORD

hkey_local_machine \system \currentcontrolset \services \tcpip \parameters \enablepmtudiscovery=0 REG_DWORD

added HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters added SynAttackProtect with value of 2

you should read this assuming you're using windows server

https://technet.microsoft.com/en-us/sys ... sping.aspx

https://blogs.technet.microsoft.com/ask ... h-perfmon/

if you use GNU/Linux you can tweak you SYSCTL and recompile your kernel for more something that fit your needs.

Wireshark could be useful for spot-checking one or two stations that are exhibiting symptoms. If you are actually losing packets, you would need more than that, you would need to perform a correlated capture - one on each side, and identify where a packet may be sent but not received, or something else like re-transmits.

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.