BS 6353 said:
Is it continous 2 years at a strech or total duration of 2 years in a period of 5 years.
Total of 730 days you have to be in Canada or actually on the PR renewal form, they ask you how many days you were outside Canada which could be maximum 1095 (3 years total). It can be separate periods, doesn't have to be all together.
The only exceptions are if you are accompanying a Canadian citizen spouse, you are a child accompanying a Canadian citizen parent, you were working for a Canadian company that transferred you to another country or your spouse is a PR and was working for a Canadian company that transferred them to another country.
This is not just for the first 5 years that you are PR or separate for each PR card period, it's any rolling 5 year period. They can question your PR status any time you come to Canada, even though your PR card is still valid.
See http://www.cic.gc.ca/english/information/applications/guides/5445EA.asp for residency requirements.