What is the best way to avoid obsessing over negative thoughts and the stress that follows?

Mindfulness. Try reading on " mindfulness" as there are many books. It is very helpful.
Doing something. When people get trapped inside their own head with all those negative gremlins running around in there, it's hard to get out. If one stands there and watches long enough one can't help but join them. That's getting into mental mischief. Get out of there & that means go do something asap. Nothing beats doing something to defeat constant obsessing on negative and painful thoughts.
CBT OR Medication. Ocd can be debilitating. Cognitive behavior therapy has found to be the best. In cbt, therapist uses teqnigues such as thought stoping, alternative thoughts and relaxation teqnigues to help patients. Classic antidepressant or Luvox (fluvoxamine) are very useful agents to alleviate symptoms. It is important to see professional because it is a treatable condition.
Get help. Sometimes obsessing over things is a sign that we really are bothered by something. Seeing a psychologist, counselor or therapist can help you figure it out and help develop ways to change. Especially if you find you can't go through your day like you normally would, you should see someone professional.
Try mindfulness. There are many books on "mindfulness" that will help you in dealing with stress without medication.
Negative thinking. This is a very distressing situation and you usually need help in your fight to get better. Discuss this with your doctor and find help. Learning to think positively to combat the negative thoughts help. Google negative thinking and look over the information you find. Meditation on positive thinking helps. Cds about positive thinking can help.