Depending on where the pain is located the problem could be bike fit around saddle height vs. stem height or saddle vs stem length or many other variables.
I once encountered shoulder pain on a long tour. The problem turned out to be the handlebar had shifted off center during airline box packing. Once the bar was centered equally the pain went away.