Luke H. answered 04/18/19
521 MCAT | Test Strategy Specialist | 10+ yrs Teaching | Georgetown MS
Hey there,
The basic reason the these injections are painful is due to the irritative nature of intramuscular injections and the pursuant inflammatory cascade in the area. The "ache of the entire arm" is due to localized signaling effects down the length of the entire muscle into which the vaccine is injected.
Non-vaccine punctures are usually given subcutaneously (right under the skin) or intravenously (into the blood stream) and these bring about very different effects. Vaccines are delivered IM in order to ensure they are maximally effective.
Other IM injections cause the same pain, including intra-gluteal steroid and testosterone injections, among others. Here are some interesting papers about the factors involved so you can learn more:
https://www.clinicaltherapeutics.com/article/S0149-2918(09)00263-X/pdf