Lesser known examples of perseverance with a successful ending The stories of Wiles, of Perelman, and of Zhang, are very well-known to illustrate that sometimes great results are achieved through particularly long perseverance.

What are lesser known-examples of that kind ?

These need not be epoch-making results like those mentioned, but, say, they required at least 6 or 7 years of dedicated effort (not necessarily by a single person, and also not necessarily a first-time paper i.e. a paper correcting a previously incomplete attempt also would qualify as a good answer). 
Edit: to clarify, I do not have in mind long endeavours by many people over centuries like Galois Theory, really just a particular theorem within the lifetime of their author(s).
P.s. if moderators could help make this question community-wiki, that would be great, thank you.
 A: The "Magic Wand Theorem" might qualify as a "lesser known" theorem, proven by Eskin and Mirzakhani in a research effort spanning two decades (1993–2013):

Alex Eskin said he first became interested in the ideas behind the
  magic wand theorem as a graduate student. "I actually got obsessed
  with this problem," Eskin said. "I had to work on other things because
  I was young, and you have to publish  to get hired. But I was always
  thinking about this problem."
  Still, years passed before he was able to make significant progress.
  "Eventually, I met Maryam Mirzakhani," Eskin said. "We had similar
  research interests, and we started collaborating for a while. And
  she's very much not interested in going after the low-hanging fruit.
  She wanted to work on the difficult problems. So, our projects got
  more and more ambitious."
  Still, they didn't immediately start plugging away at the problem that
  would help lead to Mirzakhani's Fields Medal and Eskin's Breakthrough
  Prize.
  "This was kind of the biggest problem in our whole area," he said.
  "She knew I was thinking about it, and I knew she was thinking about
  it. But we never talked about it. And this went on for a couple of
  years, and then we just decided to join forces."
  Eskin compared what took place over the next five years to a
  mountain-climbing expedition, noting that he's not the first
  mathematician to describe a theoretical research project this way.
  "For two years then, we were climbing it, making steady progress,"
  Eskin said. "And finally, we got to a place where we could see the
  top. But we hit a ravine, and we couldn't cross that ravine."
  "We were basically stuck for a year and a half," he said. "We were
  trying all kinds of ways to go at this and basically made absolutely
  no progress."
  At some point, though, they decided to stop trying to cross the
  ravine.
  "We found a way to climb the other side of the mountain," he said.
  Their new approach leaned heavily on earlier work by Israeli mathematician and
  2010 Fields Medal winner Elon Lindenstrauss.
  "Using this other work, going around the back, we couldn't reach the
  top either," Eskin said. "But we kind of found enough material that we
  could build a bridge over the ravine."
  That "material" was a series of smaller proofs, made while climbing
  that back route, that allowed the original route to become passable.
  "From there, it took us another two years to write it down and make
  sure it all worked," Eskin said.

source
A: One that comes to mind is Babai's spectacular algorithm for Graph Isomorphism. He chipped away at the problem for over 40 years (while doing much other work of great note). He started in 1977 (according to one popular article). 
In 1983 He and Luks came up with an algorithm with worst case run time $2^{O(\sqrt n \log n)}.$ That was the state of the art for over 30 years. 
In  November 2015, Babai announced an algorithm  with worst case running time $2^{O((\log n)^{c})}$
Like Wiles proof, it had an error which was later fixed. I don't know that it is universally accepted, but 
I think most in the field were pretty amazed by the result. Even though his plan of attack was known and he published results along the way, a result that good was thought out of reach for a decade, if at all. 
I didn't find a good quote by him but I've heard talks where he discusses the result and his wrong turns and breakthroughs over the years. There are many talks by Babai on the web, here is one. If it is like talks I've heard, he discusses (someplace in those 90 minutes)  the process. 
A: I'm not sure if you're insisting on examples in which a mathematician (or group of mathematicians) works single-mindedly on a single problem for many years and finally conquers the problem.  If so, then the following might not qualify.  But it might qualify if your conditions are not as stringent as that.  I quote from Ilse Fischer's response to being awarded the AMS Robbins Prize.

The idea of working on Robbins' last open conjecture on alternating sign matrices slowly manifested in my mind when I was writing a grant proposal about 10 years ago, when I identified it as an ultimate, albeit unrealistic, goal. In the beginning I hardly dared spend much time on it, but every now and then I discussed it with other combinatorialists. Roger Behrend and Matjaž Konvalinka were obviously among them, but I also had a particularly fruitful exchange with Arvind Ayyer back in 2012, which led us to several conjectures on the enumeration of extreme diagonally and antidiagonally symmetric alternating sign matrices of odd order. About three years later, Arvind, Roger, and I were able to prove these conjectures, and to some extent also this work paved the way for the eventual proof of Robbins' conjecture. I feel deeply honored and moved to receive, together with Matjaž and Roger, the David P. Robbins Prize.

