Note that I did *not* measure network usage.
At the same time, I ran 'top' in an ssh session. This is what I observed:
- login-server uses 100% CPU in a fork, briefly, every 5 minutes. This does not have any effect on lag.
- char-server uses 100% CPU with a different pid (so it must be the fork), much more frequently than that. This does not have any effect on lag, but should probably be fixed anyway.
- about half the time, when a lag spike happens, the status of the map-server process changes from S to D. I expect that it actually happens all the time, but top and/or my eyes are not updating fast enough (since the lag I experienced was less than a second). at the time, map-server CPU is 1%. If the char-server is running a save, it is also set to D, and CPU usage is between 10% and 24%.
The map-server accesses the hard drive for three reasons (after startup that is):
- the MOTD when a player logs in, and @help. I plan to fix both of these eventually, but since Platinum has plenty of free RAM, they're unlikely to cause much of a problem.
- Writing the log. Also, gzipping during log rotation uses system(), which blocks (but would not leave the process with status D).
- Saving global variables. We should probably clear the obsolete ones, and maybe should maybe decrease the number of high scores from 10 to 5 (affects fluffy hunt as well as the new Illia quest)