I think to a degree we all experience similar things throughout our lives, including the difficulty overcoming it. The reasons why you do these things, in my opinion, is there are certain beliefs about yourself and the people around you that you developed during childhood that sometimes just replay and replay throughout your life, that if gone unchallanged will constantly cause you to repeat the same mistakes and life-situations over and over.
For me I hit this crisis situation, and I decided that that was it, I've had enough and I need to figure out why I keep doing these things. So I sat down with pen and paper and just wrote and wrote and wrote, about where I think this behaviour comes from, why I do it, where it's going to lead me, what exactly I'm thinking and how it makes me feel, and how rational it all was. I think I then just woke up, realised that certain thoughts and behaviours where completely pointless and time wasting, and I just completely shattered all of the irrational behaviour with just realising how incredibly pointless it all is, only serving to make me miserable.
Something changed that day, and although I had understood all the concepts of releasing denial and rationalising your beliefs my whole life, I put it mainly down to the fact that I sat there and wrote it all down on the piece of paper, with the intention of getting to the bottom of it no matter what.
So if I find myself doing any of these unwanted behaviours these days, I just think back to what I had written, and remind myself that I have already proven how pointless all of it is, and the behaviours just disappear.
I hope this makes sense