You may have a significant buildup of mineral deposits in the tank. This can act like an insulator, preventing the thermostat from getting an accurate reading of the water. At 10-years, the thermostat might be getting cranky, too, and replacment of it might help. But, at 10-years, you could have another 10-years out of it, or it could fail tomorrow. Is this gas, electric, or other?