Anaerobic describes any species of bacteria that can survive in an oxygen-deprived environment; some anaerobes even find oxygen toxic. Anaerobic bacteria is distinguished from aerobic bacteria which needs oxygen to survive. Well-drained soils therefore favor the growth of aerobic bacteria while anaerobic bacteria lives inside soil aggregates in overly moist, poorly-drained soils.
One of the important functions of bacteria in soil is to convert nitrogen gas from the air into nitrates and nitrites, forms that plants can use for their nutritional value since plants cannot absorb nitrogen gas. But anaerobic bacteria performs the same function in reverse, namely converting nitrates and nitrites back into gaseous nitrogen form. For this reason, many soil-borne anaerobic bacteria are also known as "denitrifiers."
Denitrifiying is an important function in a soil ecosystem, but anaerobic bacteria can also have some negative consequences in soil, particularly if you plan to grow plants there. Anaerobic bacteria produces toxins that can damage plant root structures. Poor root growth means that plants will be more susceptible to diseases that attack the plant from the roots up.
The presence of a large concentration of anaerobic bacteria in a compost pile can be problematic as well, and these problems highlight why you should ensure that your compost pile has sufficient oxygen content. Anerobic bacteria in compost produces organic acids and amines that produce a form of nitrogen that plants cannot use and that can sometimes be toxic to plants. Additionally, anaerobes produce compounds such as hydrogen sulfide, cadaverine and putrescine that give your compost pile a foul, offensive odor.