OPTIONS

Native MethodsΒΆ

Name Description
_isWindows() Returns true if the shell runs on a Windows system; false if a Unix or Linux system.
_rand() Returns a random number between 0 and 1.
_srand() For internal use.
cat() Returns the contents of the specified file.
cd() Changes the current working directory to the specified path.
copyDbpath() Copies a local dbPath. For internal use.
fuzzFile() For internal use to support testing.
getHostName() Returns the hostname of the system running the mongo shell.
getMemInfo() Returns a document that reports the amount of memory used by the shell.
hostname() Returns the hostname of the system running the shell.
listFiles() Returns an array of documents that give the name and size of each object in the directory.
load() Loads and runs a JavaScript file in the shell.
ls() Returns a list of the files in the current directory.
md5sumFile() The md5 hash of the specified file.
mkdir() Creates a directory at the specified path.
pwd() Returns the current directory.
quit() Exits the current shell session.
removeFile() Removes the specified file from the local file system.
resetDbpath() Removes a local dbPath. For internal use.
version() Returns the current version of the mongo shell instance.
←   connect() _isWindows()  →
ON THIS PAGE