Hello, if the roller ball has completely failed, then you will need to either replace it, or replace its contacts. However, it is also likely that the contacts are just very dirty.
Taking the roller ball out of the phone is actually quite simple. Using your fingernail, a plastic pry tool, a spudger, or something similar, pry up the silver ring surrounding the trackball. Be sure to pry from all sides evenly to ensure that the ring doesn't break. Once the silver ring is off, simply lift out the trackball assembly.
You may notice that the sensor wheels are totally gummed up. Using a bit of rubbing alcohol on a Q-tip or a rag, clean all the gunk off of the wheels. Do the same thing for the contacts in the phone.
Good luck, and let us know how it works out.