Your best to avoid problems with ids is not using the id
attribute if you don't need to specifically refer to it in the view (for example, an Ajax update over the component). Just let JSF assign its own-generated id, that way you avoid duplicates.
About the debugging, check the javax.faces.webapp.FacesServlet
class, which is the Servlet where JSF does its work. Here you'll be able to check each building and rendering process. However, don't obsess debugging your JSF implementation's internal classes, they are supposed to be tested, you should keep your own code in mind.
So my tip is: start debugging your own methods!