The core of the answer here is that (to quote Jurassic Park) life always finds a way.
Even if the machines destroy every single unplugged human, what stopping similar rebellions from happening in the future? Something as simple as a mechanical failure could release one (or more) humans from the Matrix, who then again start a new rebellion.
This is why there's an endless cycle: the Machines have not found a perfect way to keep all humans in the Matrix at all times. And whenever any humans manage to escape (or be involuntarily freed from) the Matrix, the machines may have to fight a new rebellion.
Neo offers something different: an end to the repeating cycle of rebellions.
It's never really established what the machines' goals and purpose in life are; but I doubt they exist purely to farm humans, chase the runaways and deal with rebellions. Farming humans is simply what they do to get power, so that they can then do other things.
But why don't the Machines shut down the Matrix like they were already willing to do
Because a hard shutdown of the Matrix will also kill the humans (this is the equivalent of unjacking, which is what kills some of Morpheus' crew when Cypher unjacks them).
As humans are the prime source of power for the machines, they are unwilling to lose their power source. Neo and the Architect explicitly discuss this:
The Architect - Failure to comply with this process will result in a cataclysmic system crash killing everyone connected to the
matrix, which coupled with the extermination of Zion will ultimately result in the extinction of the entire human race.
Neo - You won't let it happen, you can't. You need human beings to survive.
The Architect - There are levels of survival we are prepared to accept. However, the relevant issue is whether or not you are ready to accept the responsibility for the death of every human being in this world.
Even if the machines would do it as a last resort ("levels of survival we are prepared to accept"), that doesn't mean that it's the preferred option. Neo offers the option of killing Smith without needing to reboot the Matrix and that is a much more preferable option to the machines.
The deal boils down to this: The machines do not destroy Zion, Neo kills agent Smith "cleanly". The Matrix does not need to be rebooted, which is beneficial to both humans and machines.
If your question is asking why the machines didn't welsh on the deal and still continued to destroy Zion after Neo held up his end - that's not really conclusively answerable. It makes for a bad plot resolution. Who says machines are able (or willing) to behave dishonorably? We see plenty of programs who learn empathy towards themselves or even humans, which means it's not impossible for them to honor a deal.
Keep in mind: the original human/machine war started when the humans reneged on their side of the deal. There was a truce whereby the machines were promised a safe sanctuary to live in, and the humans attacked them again without warning.
Now, the roles are reversed: the humans are asking the machines for a safe sanctuary to live in. Machines are likely not as needy for revenge, and therefore may be more willing to be better than the humans and thus choose to honor the deal instead of what the humans did to them in the past.
If anything, the machines are repeatedly shown to think themselves superior to humans. If they betrayed the truce just like the humans did, then they prove to themselves that they are no better.
@BladeWraith mentioned a very good example of this mentality at play, in the final conversation between the Oracle and Architect:
Oracle - I have your word?
Architect - What do you think i am? Human?
Thus suggesting that once the Machines agree to something they won't go back on it, and that they consider going back on your word a human (inferior) quality.