The amount of time to completion is a function of the institution AND the program's requirements. If the program requires the completion of a thesis (where you are collecting data on a research question), then it might take longer than 2 years as the data collection process may take much longer than expected. This is but one example of a variable that can impact completion time.
What's more important to your long term career success is finding a graduate program that is aligned with what you want to do in the discipline of psychology! Finding that "best fit" will require effort on your part by researching the programs "out there" and asking questions of the faculty at the various schools that look interesting to you after doing the research on the programs. Ask the faculty at a school the "average completion time" for both thesis and non-thesis track programs. Ask about the percentage of students who fail to graduate after say 3 years. Don't forget to say "thanks" for the answers to the questions you have posed to strangers...Gratitude is a virtue that must be cultivated for success.
A master's degree in psychology usually does take 2 to 3 years to complete. However, there are some programs that allow you to complete the program sooner. For instance, I completed my master's degree in one year. It all depends on which school you attend.