Thanks for choosing health care magic for posting your query.
I have gone through your question in detail and I can understand what you are going through.Pimples
on the scalp
can be responsible for the headache that you are describing. It is an infection of the scalp most probably a fungal infection
or a bacterial infection. The best way would be to get it examined by a doctor or take a photo and upload it to us to have a look at the pimples. You will certainly need a course of antibiotic such as cefexime initially.
Hope I am able to answer your concerns.
If you have any further query, I would be glad to help you.
In future if you wish to contact me directly, you can use the below mentioned link:
Wish you good health,
Dr. Srikanth Reddy M.D.