When a country builds up its army in preparation for an attack to secure its borders, this is an example of when it takes a defensive position.
When you are over-sensitive about your mother-in-law's criticisms of your housekeeping skills and you are constantly ready to say "I clean fine!" this is an example of a time when you are defensive.
A defensive weapons system; defensive behavior.
Defensive driving; defensive medicine.