You should use as many dice as possible while defending (so always 2, unless you have one army).  

This problem has no doubt been tackled by hundreds of probability students over the years, and it is not hard to Google and find a complete calculation.  A likely best source for your buck for this, and related questions, will be Ivars Peterson's MathTrek article here:

http://www.maa.org/mathland/mathtrek_7_14_03.html