The undead body is preserved by magic.
And that's the key. Treat magic as an almost-infinite resource easy to obtain but hard to replenish. Is a common setup in magic universes that "magic" is a consequence of the existence of living beigns. In other words, just imagine that "mana" is available in the whole world, but is more common or concentrated around places where life is more common as well, forests, big cities, etc...
On the other hand, living corpses uses magic for living; it could be a delicate ballance between living beigns spreading magic as they live and undead beighs consuming magic as long as they're living. 227
Create too many undead bodies and they wil deplete the magic of the zone quickly, and after that they will die (again) like my cell phone when it run out of battery. Or create just the right amount of undead bodies and they will consume the ambient magic at the same pace as it is replenished.
If the ratio of magic creation vs magic consumption is 1:1 (one living being spreads enough magic to sustain one unliving being) you tie the amount of undead bodies to the amount of living bodies so, if in some point of time the undead outnumber the living ones, they wouldn't last for long.
Life and death are tightly related. It's obvious that one cannot exist without the other.
Nature don't like undeads, but tolerate them.
It is not natural for a dead being to be alive, every cell in the body of the undead is craving for resting forever. Well, you can cheat nature using magic but, the longer you cheat mother nature, the more it costs.
If the magic cost per day follows the graphic below:
For each day of existence (x axis), the magic cost increases (y axis), so after 100 days of unliving, dayly cost is almost twice as the first day and 200 days after the cost is multiplied by 8.
No matter how powerful the Necromancer would be, there would be a moment where the magic costs exceeds Necromancers power and this body cannot be kept living anymore.
Maybe you can use both ideas at the same time! :) 227