'Pneumonia' really just indicates fluid in the lungs. The difficulties depend upon what is cause that fluid to be there. Viral pneumonia can last for weeks and weeks with no medical cure, only body maintenance, usually requiring hospitalization, and be life-threatening, where as bacterial pneumonia usually just requires a course of Amoxicillin 500mg twice a day for (depending on the current thinking) between 7-10 days, feeling much better by the 4th-5th day. 'Walking Pneumonia' often doesn't have either a bacterial or viral cause, but still creating the same fluid build-up in the lungs.
That said, one of the best 'preventative measures' is a glass of Bombay Sapphire... I'm protecting myself right now!