Pneumonia is an inflammatory condition of the lung affecting primarily the microscopic air sacs known as alveoli. It is usually caused by infection with viruses or bacteria and less commonly other microorganisms, certain drugs and other conditions such as autoimmune diseases.neumonia is due to infections caused primarily by bacteria or viruses and less commonly by fungi and parasites. Although there are more than 100 strains of infectious agents identified, only a few are responsible for the majority of the cases.