I have had an MRI. It was a bit scary to me because it was not an open MRI. I had to lay down and then they pushed a button that put me into the middle of the MRI. Plus it is so damn loud. They gave me headphones to listen to music but the machine is louder than the music. They may also want to use contrast dye. I had headaches like you describe so I had to have it done. Turned out that my headaches were from anxiety and panic attacks.
You may have tension headaches. I had those for years and took Fioricet for it.
http://www.webmd.com/migraines-heada...sion-headaches and
http://en.wikipedia.org/wiki/Fioricet