After I have started Mongo using mongod.exe on a Windows 7 machine, I tried to start the mongo shell that failed with the error:
Failed to connect to
I got the same error and fixed it with:
1) mkdir c:\data
mkdir c:\data
2) cd data
cd data
3) mongod -dbpath .
mongod -dbpath .
4) Now in another command window I was able to connect from my client using the mongo command.
mongo