Mine lasted 15 years. They created a remake of it around 7 years ago, but I didn't buy one because my original was still working. The original never actually stopped working, it just started looking and feeling very worn and dingy. I'd buy another if they released another remake.
I lucked out and bought three (original) MX518 on clearance at a Target after they were being phased out in favor of the (inferior) original G5 laser mouse. I gave two away as gifts, but the spare lasted me many years. Technically it never stopped working, but I wanted to try out the newer models and their nicer cables and teflon sliders. When the remade version came out, I bought one and when I realized how much better it was than my Tron-like Logitech mouse they has been pushing, I bought a second one so that I could hopefully go decades until I needed to worry about this. That backup new MX518 is still in the box, so my plan has been a complete success.
I envy your foresight. I didn't know back then that every product on the market was going to continually get worse for the rest of our lives.
Edit: I replaced the MX518 with the Logitech G700S (I think that's what it is anyways) and that one is still working great too. So I guess any of the slightly older Logitech mice are still very good.
The original purchase was just luck as they were 90% off. I would have bought 10 if I could at that price. I'm a bit of a peripheral snob, so when I find something I like, I lean into it probably too much.