In Game Random 5 sec Lag/Spike Possibly Found

Check here for server status and maintenance.

Moderator: Forum Moderators

User avatar
joeyz
BF2 & UT2004 Server Founder
Posts: 200
Joined: Fri Feb 17, 2006 4:44 pm

In Game Random 5 sec Lag/Spike Possibly Found

Post by joeyz » Wed Jul 24, 2013 2:24 am

Tonight while playing with the team, we were in goliath at end of a wave with just a few monster and the 5 second lag,freeze, spike or whatever you call it happened. It also happened during another map during a wave count down. This tells me that something else is going on and may not not be the preloading of a monster model, mesh, texture, etc.

This spike has turned me to examination of RPG.INI database on the server. Discovered that it was 26 meg in file size. I open it in text pad to reveal number of lines in the file. There are 528222 lines in the flat file database text file. Also, every 300 seconds, this RPG database gets updated. Having said all that, i believe the evil spike is due to the RPG file too large and eating up memory and machine cycles to update player data.

Tomorrow night, after work, i will clean up the this RPG file and remove all the excess old player data to about 1000 lines. Will then load it up on server and resume game play and test my theory. Spike should go away. Imagine the engine having to parse through (read, write, and save) to such an enormous database. I do not think that UT has to open and close the database for it stays open during the game. Its the updating and saving that would eat memory and cpu machine cycles saving a 26 meg file every 300 seconds (5 minutes) which is about these spikes are happening.

Meanwhile, i have increased the server max client internet speed from 10,000 to 15,000. So far, players have reported improvements on graphics, lag, and getting better packets.

More to follow tomorrow night.

Joey
Flak of Power +10 [Powerups: 3 Sturdy, 2 infs, 1 Healing, 1 Vorpal, 1 Lucky, 1 Poison 5x, 1 Protection 5x, 1 Retaliation x5, 1 Retention, 1 Super Force, 2 Speed 5x, 2 Damage 5x, 2 Energy 5x, 1 Penetrating, 1 Razorbomb]

Duffy
Private
Private
Posts: 17
Joined: Mon Mar 12, 2012 5:03 am
Contact:

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Duffy » Wed Jul 24, 2013 10:44 am

Thanks for the update and all the work you are doing with the server :clap:

User avatar
Archangel
Master Sergeant
Master Sergeant
Posts: 783
Joined: Sat Jul 07, 2007 11:04 pm
Location: Asskicker in Heaven
Contact:

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Archangel » Wed Jul 24, 2013 1:37 pm

Great........Glad to hear it.... :cheers:
Image

User avatar
Archangel
Master Sergeant
Master Sergeant
Posts: 783
Joined: Sat Jul 07, 2007 11:04 pm
Location: Asskicker in Heaven
Contact:

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Archangel » Wed Jul 24, 2013 2:51 pm

Just finished playing DM-Egyptionstyle and there was more lag then ever.....
Image

User avatar
Mobster
UT2004 Server Admin
UT2004 Server Admin
Posts: 845
Joined: Thu Jul 20, 2006 6:02 pm
Location: New York
Contact:

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Mobster » Wed Jul 24, 2013 4:15 pm

Note some of the newer maps Joey has added to the server, aren't optimized for invasion.

Like last night he was mentioning maps not having enough player starts.
What could also be part of it is not enough path nodes, bulky texture, mesh files, and not being properly zoned.

Then again anything could be causing the lag, and the spikes. :rambo:
Mob
Monster Madness RPG WoP Invasion Server Administrator - UT 2004
Map Editor - UT 2004

Skype: jriv193
Image

User avatar
Archangel
Master Sergeant
Master Sergeant
Posts: 783
Joined: Sat Jul 07, 2007 11:04 pm
Location: Asskicker in Heaven
Contact:

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Archangel » Wed Jul 24, 2013 8:39 pm

Joey must have tweaked the game and the damn nuke settings......on Goliath map, there were soooo many damn nukes flyin at me in wav 18 (more than 10). Also, server is crashing to default Goliath map alot.
Image

User avatar
ZombieSlayer
Second Lieutenant
Second Lieutenant
Posts: 2077
Joined: Thu Nov 16, 2006 9:41 pm

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by ZombieSlayer » Wed Jul 24, 2013 10:42 pm

You want to know what will help? Trim the (other) .ini file with all of the players in it (sorry just got out of finals so my brain is melted and I can't think of it's name). It's huge and also gets updated every 5 minutes or everyone time someone levels.
If you lost your cd and have the old drive and have not reinstalled UT2004 or reformatted the drive, you can find your old cd key in the registry here ...

My Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Unreal Technologies\Installed Apps\UT2004

Tzakol
Specialist
Specialist
Posts: 75
Joined: Sat Mar 22, 2008 8:42 am

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Tzakol » Thu Jul 25, 2013 11:51 pm

Has it made a difference in game play?
Image

Sys

SM SYS-8048B-TRFT
256GB DDR4
OGL

User avatar
Gothicize
Sergeant
Sergeant
Posts: 440
Joined: Sat Mar 25, 2006 5:01 pm
Location: WA

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by Gothicize » Thu Jul 25, 2013 11:53 pm

Not sure yet. He's updating as I type.

User avatar
joeyz
BF2 & UT2004 Server Founder
Posts: 200
Joined: Fri Feb 17, 2006 4:44 pm

Re: In Game Random 5 sec Lag/Spike Possibly Found

Post by joeyz » Fri Jul 26, 2013 3:19 pm

Okay, i have completed my analysis and we have corrected majority of the problem.

First let me explain for there are many definitions of lag, spikes, freezes, etc and can be caused by many things in the game.

The spike we are refering to is where you are in game and all of sudden you find yourself froze and running against the wall for about 5 seconds long. lol

After playing the game sunday and monday night, i have determined this is not lag but a server game freeze spike that was reported to happen randomly and lasts for about 5 to 6 seconds long which totally disrupts the game. After experiencing this myself, Being spiked to running in walls, i have determined that the length of this 5-6 long spike cannot be an object loading on the map that is not preloading/cached in memory. Objects that are not preloaded can cause a pause for a only a second and does take 5-6 seconds. To help identify the problem, i wrote down the time everyone got zapped with the big spike. After playing a full 20 waves, i examined my data collection of times when these spikes happened. Discovered that these spikes are happening 5 to 6 min apart, a timed event. I ruled out monsters for they are different on every wave in the script and my other monster mutator randomly spawns boss monsters. This analysis led me to examine all the server ini data files on server; my hunt was for a timed event. While examining the UT2004RPG.ini (player stat flat text database file), discovered it took a long 5-6 seconds to open the text file and it froze my system while opening (27 meg text file) In the database, there is a call to server to update RPG player stats every 300 seconds. Now that i know the size of this file and calling to read, write and save player stats, i closed the file and monitored the game time and cpu. Sure enough, every time the game hits 300 seconds the server cpu spiked up and froze the game for 5-6 seconds. We have confirmed the evil doer :) The RPG database was so large and taking enormous amount of machine cycles and memory to update player data every 300 seconds. :)

To know what i am saying, have you ever saved a file on your pc and it freezes everything you do until file completes the save? Thats what is going on here with the server.

Now that i know the problem, we can fix it. For the past few nights, paintball and myself have been working hard on cleaning/purging the RPG database. Here is some data we discovered:

- discovered the RPG text file was over 20 megs. Inside the database, it had over 30,000 player records and 540,000 lines of player stat data.

My goal was was to achieve 50% purge of old player stats under level 15 but we have exceeded that goal:

- deleted over 23,000 players and their data
File size changes:
Start: 21427k (529118k lines)
End: 8338k (177020 lines)

During our process, noticed the file was unicode and not ansi utf-8 format. Converted the file back to original ansi utf-8
After Encode/Optomize: new file size is: 4169k

The Reduction Difference:

FileSize: - 61%
Filsize Optomized: - 81%
Lines: - 67%
Estate file size: 4.07 megs

Applied the new RPG file to server last night around 1130PM. Joined server and we played for a few maps until 4AM. The long server spike of 5-6 seconds went away (the spike to where your running into walls as the server crashed).

There is still a possible 1 second spike but not often. Tonight, paintball and i will purge half of the database again. Pending if we can stay awake, loss of sleep 3 nights in a row. A little more work and it will be gone totally.

Lastly, please note that when i converted the database to ansi utf-8 there were alot of player names that had invalid ansi characters. All invalid characters were replaced by a "?" symbol. Attention players, if you rejoin server and your stats arent there, it is most likely that your name had an invalid character. As a temp solution, please replace that character with a ? Mark and it will be there. Please see me and i will fix your name/stats one by one to what it was. I dont ever delete any players whom built there stats on server. If you have a new cd key and carry imposter, i can fix that too.

Til then, enjoy the game and give feedback.


Joey
Flak of Power +10 [Powerups: 3 Sturdy, 2 infs, 1 Healing, 1 Vorpal, 1 Lucky, 1 Poison 5x, 1 Protection 5x, 1 Retaliation x5, 1 Retention, 1 Super Force, 2 Speed 5x, 2 Damage 5x, 2 Energy 5x, 1 Penetrating, 1 Razorbomb]

Post Reply

Return to “Server News”