Your vet would have stronger medications (like steroids, narcotic pain relievers), but for now, you could give him an aspirin. It might help relieve his discomfort somewhat. I recommend Ascriptin or Ecotrin. Do not give Advil/Motrin, or tylenol. Give him 1/2 of a regular strength (325mg) aspirin twice daily with food. Side effects include vomiting, diarrhea, loss of appetite, stomach ulcers. If your dog experiences any problems taking aspirin, discontinue it and discuss it with your vet.
If the aspirin does not help, you should ask your vet for other options to control his discomfort.