i fairly new to java servlet.
Please forgive me if this question seems stupid.
I have add servlet mapping such as servlet class and url pattern using netbeans i
I see a Facelets page and I see a JSF specific , but I don't see the JSF FacesServlet being definied in web.xml, yet you're fiddling with other servlets.
Aren't you mixing the basic concepts/technologies? Admittedly, the JSP tutorial is missing in Java EE 6 tutorial, but to work with plain vanilla servlets, you'd usually use plain HTML or JSP instead of Facelets.
Anyway, to invoke a servlet by URL, you need to ensure that the URL matches the of the servlet as is been definied in the web.xml. You've definied your GreetingDukeServlet to listen on URLs matching /GreetingDukeServlet. So the URL has to be http://localhost:8080/HelloDuke2/GreetingDukeServlet instead.
If you actually want the URL to be http://localhost:8080/HelloDuke2/greeting instead, then you should change the to /greeting instead.