This is very specialty dependent. In my specialty, most people are looking by the time they start their final year of training.
Many think that if you haven't been making connections and looking for a position even before the final year of training, you're already behind.