mongodb / v3.6 / reference / reference-method-getHostName.html

getHostName()

getHostName ( )
Returns: The hostname of the system running the mongo shell process.