Whether working with 13 year old 8th graders bent on proving themselves or 17 year old 12th graders who are counting down the days awaiting release, a teacher must be prepared to take control of a classroom and maintain that control in every situation. While there are many opinions on the subject (don't smile until Xmas) the key to successful classroom management is awareness. That includes being aware of school policy and procedure in dealing with disruptive students as well as being able to recognize a genuine miscreant from a habitual wise guy just trying to get under your skin. Meeting with other teachers as well as parent involvement will help separate the mostly good from the always trouble.
Being aware to leave personal feelings out of it and being aware of when to back off and try something else or get help are vital to success. However, like any other aspect of teaching, managing the classroom is a learned skill that will include its own successes and failures on the way to settling on your own best practice.