Diacetyl is a naturally occurring compound formed during fermentation and has a perceived butter or butterscotch like flavor that is undesirable in most beers. It is important to note that other ingredients used in beer production, such as caramelized grains, may impart a somewhat similar flavor, and the two should not be confused.
Although Diacetyl is tolerated or even expected in some beer styles, recent research has shown that at very high levels and under the right conditions, it can be toxic. The good news is that diacetyl is typically only present at very low levels in beer and can be greatly minimized if certain protocols are followed.
One way to help reduce diacetyl in your beer is to clean and sanitize equipment properly because certain undesirable bacterias produce diacetyl. Another way to reduce the diacetyl in your beer is to pitch a sufficient quantity of healthy yeast and conduct a full fermentation and conditioning cycle prior to cold crashing or kegging your beer.
Yeast is responsible for creating and removing diacetyl at different stages of the fermentation process. Yeast creates diacetyl early in the fermentation process and breaks it down towards the end. If you did not pitch enough healthy yeast to complete the fermentation, placed your yeast in stasis, or destroyed your yeast before the end of fermentation, then you may end up with higher then desired levels of diacetyl.
If you happen to be fermenting a lager, a process known as a diacetyl rest (which requires a fermentation temperature increase) may also be helpful in reducing diacetyl in your beer.