If the noise is a ticking noise its likely in the valve train and not anything to be too
concerned about on an older car like yours. If its a knocking sound it could be a
bearing about to go which means its time to start car shopping. When the bearing
finally spins, your engine will stop dead without warning and you will be done.
Figure that out before spending money on other repairs as it might be time for a
new car. I believe there are separate codes for the two O2 sensors so it should be
easy to figure out which one it is. The upstream one requires a special socket to
get it off the car. Not sure about the downstream one, so if you don't have that
tool, you may need to get a shop to do it. Remember, its only an O2 sensor so
unless you have to pass a vehicle inspection you can just ignore it if you don't
want to spend the money on it. Mine ran that way for a couple of years without a
problem, and then after that unpleasant encounter with a Freightliner, it didn't
matter any more. But that's another story.