Cellists: How do you "unlock" your right thumb?

I've been playing the cello for 5 years now, but I've been experiencing pain in my right hand for the past few months (my left hand hurts as well, but not as much)-I think this is because my first cello teacher was so focused on getting me through as many pieces as possible she did not pay much attention to my bow hold (my current teacher is now trying to get me unlearn my problematic bow hold and learn the correct way).

Anyway, after much investigation on the internet, I realized that the reason why my left hand hurts is because I grip the bow too tightly. I get that you should not need to place any force onto the bow as the strings will support the weight of the bow, but I can't seem to "unlock" my thumb-its stuck in place when I play. (This might have to do with me worrying that unlocking my thumb will cause the bow to fall-I tried to unlock my thumb once and that happened.)

Does anyone have any advice/tips/ for alleviating this pain and unlocking the thumb? Thanks. (My teacher says that she does not know why my hand hurts.)