First Officer Ryan's mistake was torturing the prisoner. Then he lied about the situation when Enterprise responded to a distress call sent without his consent. He wanted to prove himself capable, but instead Shaka, when the walls fell.
Agreed. He handled himself poorly as well, but Archer didn't make it any better. Instead of trying to talk Ryan down, Archer just forced his hand by issuing that threat thus forcing the conflict he was supposedly trying to avoid.