Constantly training units of peasants and sending them off to the frontier regions helps keep squalor down.
When you take an enemy province, exterminate the population and move in peasants from one of your large cities, when they get there, disband them inside the city and they become the new citizens.
This doesnt solve the problem, merely moves it to another city, but I find it to be a very usefull tactic at times.