Cavitary tuberculosis primarily affects the upper lobes of the lungs, leading to the formation of cavities due to the progression and reactivation of Mycobacterium tuberculosis. The disease is highly contagious and presents with symptoms such as cough, night sweats, and weight loss, with a diagnosis typically confirmed through physical examinations and imaging techniques. Classification of cavities can be based on size, with significant implications for disease transmission and management.