I answered this question on the Supernatural Amino app, and thought it was relevant and pretty darn good (if I do say so myself), so I'm posting it here too. ☆☆☆☆☆ I think he tried, sorta, to do what was best for them, but he let his own selfish desire to avenge Mary get in the way of the new life he should've been building with the boys. It bothers me that he expected Dean to act like an adult but still treated him like a child (ie, not confiding in him... just giving orders without explaining his motivation for doing so), which is why Dean is so desperate for John's approval. People close to John (ie, Bobby) tried to tell him what he was doing, and he pushed them away, only isolating himself further, and increasing this self-perpetuating downward spiral of increasingly acute loneliness leading to a harsher attitude with the boys. The more strict he is with them, the more he cuts himself off not only from developing his relationship with the boys themselves, but also with his friends who recognize that this isn't a good way to raise your kids, which in turn only makes him lonelier and more desperate to find Azazel and therefore even more controlling with Sam and Dean. He wanted to be good to them. But at the same time, it was his own self that stopped that from happening.