How to install old version of mongodb? This started happening today for absolutely no reason. Worked perfectly last week. I didn't touch the machine.

I have an issue described here and need to downgrade in order to be able to upgrade. Currently I'm not able to enter the shell as it exits with error #4 

need to upgrade database admin with pdfile version 4.22, new version: 4.5

If I run it with --upgrade I get:

ERROR: error: exception cloning object in admin.system.users system.users entry must have either a 'pwd' field or a 'userSource' field, but not both obj:{ _id: "nod$
exception in initAndListen: 2 system.users entry must have either a 'pwd' field or a 'userSource' field, but not both, terminating


I'm trying sudo apt-get install mongodb-10gen=2.2.10but it doesn't work.

Can anyone direct me to a command I can use to install version 2.2.10?
You have to add the repo list 

sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10  
echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list
sudo apt-get update


Then re-run  sudo apt-get install mongodb=2.2.7

That should work. The repo list file was the differentiating step which you've missed