I remember having this and the last few weeks of pregnancy it was the most difficult for me. It wasn't constipation or anything, I'm not sure what it is. My guess is that it's the muscles and it's probably putting more strain on them as your baby gets bigger and you are straining to push as well. If it's worrying you, I would speak to your doctor about it.
It happened to me a 7wks pregnant. Not sure if its the same thing. I also had abit of light spotting, I spoke 2 my MW and she said its normal if your straining, but I would advise seeking medical advise just to be sure.