There's no way to fix an Xbox "for good," because no electronic device lasts forever. Everything wears out or eventually breaks at some point.
What you can do is extend its life: keep it well ventilated to prevent overheating, avoid moving it while a disc is spinning, and handle it gently. But if you're after a permanent fix, the honest answer is that hardware has a lifespan, and maintenance helps more than any one-time repair.