Lag Guide
Lag is omnipresent in Second Life. But there is a large degree of variability in terms of how badly it affects each of us. As the number of simultaneous avatars at Asphyxiation Point grows, we expect more people to be affected by the same as the effect of outdated graphics cards, faulty internet connections become more obvious under the increased load.
This guide attempts to provide a basic primer on what is lag and how to debug and combat the same. We hope doing so will help make living and playing at Asphyxiation Point even more pleasant !
This guide attempts to provide a basic primer on what is lag and how to debug and combat the same. We hope doing so will help make living and playing at Asphyxiation Point even more pleasant !
Understanding lag
Unfortunately, lag is a catch-all term employed to describe three very different things. While there is no non-technical way to describe these sources, understanding the technology is not really necessary to follow the rest of the guide. Feel free to skip.
Second Life operates on a client server model like much of the internet. The "SIM" is the server, the internet is the network and our viewer runs on the client.
The server is responsible for keeping track of where our avatars are, simulating physics, running scripts and sending us the massive amounts of data that we need. The client is your personal desktop/laptop/tablet/phone that actually displays the world to you and allows you to interact with it using the data the server has sent it. The network is what glues it together by transmitting your data back and forth. |
So what is lag? Lag is a catch-all term to describe any kind of delay between what your brain expects to see vs. what you actually see. The actual source can be any of the above three components but the user perceives it as a deterioration in expected performance. This can refer to delay between attempting to move vs. when your avatar actually moves, a delay in how often your screen draws the scene or even a delay in executing a script once you have clicked on your HUD. In the worst case, your computer may just lock up and refuse to accept your inputs ! In the following few sections, we will provide tools and guidelines to try and bridge this gap. However, there is only so much performance you can squeeze out of your machine / ISP. At some point you will have to condition your mind to accept the gap or invest into a new graphics card / ISP.
Your combat tool
The Statistics Bar ( CTRL + SHIFT + 1 ) is the single most important tool in helping you combat lag. It tells you just how well (or poorly) your viewer is performing and gives you guidance on which type of lag you may be facing so that you may address the same.
More importantly, combating lag is all about making trade-offs. You have to give some to get some. In the case of lag, you give up a bit in visual realism to gain a bit more system reliability / usability. The statistics window helps you associate numbers with every piece of visual realism you give up on. Picking the right battleground is equally important in making your combat tool most effective. In the case your lag suddenly spikes through the roof you don't get a choice of course. However, if you are trying to optimize day-to-day performance by playing with your settings, we recommend :
|
Server Lag
Server lag occurs when the SIM is unable to keep up with tracking multiple avatars, sending them the data they need, simulating physics & running scripts. Server performance is constantly monitored by the Asphyxiation Point Administration Team and so is least likely to be lagging you down. But you can help us help you by letting us know if you notice any deterioration in the following :
Please note that :
While we monitor server lag constantly, you do not want things to actually break before we step in. So please help us help you by monitoring the following items. The two most important ones have already been addressed under the SIM rules :
- Time Dilation. Should be above 0.99.
- SIM FPS. Should be above 44.5.
Please note that :
- Scripts and physics only impact server lag. If the Time Dilation and SIM FPS appear fine, it is your client / network making you lag. The tips mentioned below are to help you help us keep the SIM healthy.
- SIM FPS will drop momentarily every time an avatar teleports / logs in and out of SIM. This is expected behavior though reducing avatar scripts will make this experience a bit more pleasant..
- Server lag affects all avatars on SIM equally. Moving closer or further away from scripted / physics enabled objects / avatars will not have any effect on server lag.
While we monitor server lag constantly, you do not want things to actually break before we step in. So please help us help you by monitoring the following items. The two most important ones have already been addressed under the SIM rules :
- Vehicles : Pick them up when not in use. They are expensive in both physics and scripts. Use the tourist bike instead !
- Prim Pets & babies : The more amazing / interactive they are, the more expensive they are in SIM resources.
- Avatars : Remove all unnecessary scripts. This includes HUDs, meters and invisible attachments such as weapons / props.
- Attachments : Do a "Script Count" by right clicking attachments and delete resizer / recolor scripts from script heavy ones.
- Sit down : Believe it or not, sitting down reduces the number of physics computations.
- Furniture : De-rez poseballs and shut down MLP based systems when not in use.
- Decor : Delete resizer/recolor/texture animation/particle/light scripts when done decorating. Keep a copy !
Client Lag
Everything you see has to be drawn by your graphics card. When there is too much to draw, when your computer cannot keep up, you experience client-side lag. This is the main reason why you lag around too many avatars and why client side lag is the most common form of lag at Asphyxiation Point. Symptoms include jerky or sluggish movement, locking up of your viewer and frequent crashes. If you feel you are suffering from client side lag, open up the statistics bar and look at the following :
Please note that :
Please try and compare FPS numbers to make the right trade-offs as some measures will be more effective on certain graphics cards than others. In decreasing order of importance, try the following :
The following additional changes involve the Advanced Menu (CTRL+ALT+D) and need to be redone every-time you relog. Recommend using as temporary measures in high lag situations :
- FPS (The big bar on top)
Please note that :
- Client side lag is local to you. It is a direct result of how powerful your computer is. Adapting to high lag situations involves reducing the "quality" of your SL experience in some way or another. Some of these you may want to do to optimize day-to-day performance. Other (more drastic) measures you may wish to reserve for particularly laggy situations.
- What should be the right FPS value is thus very subjective. Shooting for 30 FPS is a good baseline to start with. Since game-like performance is not very important to us, doing so leaves us with a lot of wiggle room for more laggy situations. Individual expectations and hardware limitations may vary so feel free to adjust your target FPS accordingly.
Please try and compare FPS numbers to make the right trade-offs as some measures will be more effective on certain graphics cards than others. In decreasing order of importance, try the following :
- Set your graphics to Low or Mid : Preferences → Graphics -> General → Quality and speed.
- Reduce your draw distance ( do you really need to see 512m away? ).
- Ensure that anisotropic filtering and anti-aliasing are both disabled in Preferences → Graphics → Hardware Settings tab.
- Reduce Max Avatar Complexity in Preferences → Graphics -> General (Particularly helpful in events).
- Disable atmospheric shaders in Preferences → Graphics -> General.
- Turn particles off: Preferences → Graphics → Max. particle count - set to 0.
- Deselect both "Render alpha masks" options under Preferences → Graphics → Rendering.
- Turn off animated textures using Developer → Rendering → Animated Textures (CTRL+ALT+Q for Developer Menu).
The following additional changes involve the Advanced Menu (CTRL+ALT+D) and need to be redone every-time you relog. Recommend using as temporary measures in high lag situations :
- Disable alphas altogether using Advanced → Rendering Types → Alphas.
- Identify (and derender) particularly laggy avatars (Advanced -> Performance Tools -> Show Render Weight for Avatars).
- Disable rendering of avatars altogether: Advanced → Rendering Types → Avatar.
Network Lag
Network lag occurs when there are problems somewhere in the network between your computer and the LL servers. Open up the statistics bar and look at the following :
Symptoms of a poor connection include (but are not limited to):
Network lag is complicated as its a function of both your home network and your Internet Service Provider. Below are some basic steps you can try to mitigate network lag. But it is by no means an exhaustive list.
- Packet loss. Ideally this should be 0%. If it isn't you have a connectivity issue and are losing data,
- Ping SIM. Ideally, this should be under 200. Folks further away from the US may have naturally high ping times.
- Bandwidth (UDP Data Received). This should be several hundred KB/s on TPing in. Will go down with time.
Symptoms of a poor connection include (but are not limited to):
- Failure of your avatar or textures to rez.
- Object information not display in hover tips when you mouse over them.
- Teleport failure. and random disconnections.
Network lag is complicated as its a function of both your home network and your Internet Service Provider. Below are some basic steps you can try to mitigate network lag. But it is by no means an exhaustive list.
- Some firewall software and anti virus programs are known to inhibit or interfere with a good connection.. You may want to temporarily disable them and see if the situation improves.
- Video streaming, voice over IP, file transfer and other bandwidth intensive tasks compete for precious bandwidth resources. Shut down non-essential programs and check to see if your roommate / family is hogging the network all for themselves.
- If on a wireless connection, try moving to a different room. Better yet, try a wired connection. It is possible that it is not your ISP but your home network that is at fault.
- Play with your bandwidth settings. Too high, or too low, a value will result in network lag. For information on how to determine your optimal bandwidth, refer to this page.
References
Unfortunately, there is no one authoritative guide on Second Life Lag. Most of the existing documentation is maintained by the Second Life community. More importantly, a lot of the notecards and blog entries on the topic were written years ago and have not been updated since. I have tried to ensure that this guide is both comprehensive and up-to-date but if you are still facing issues or wish to do your own research, please take a look at :