Definição
setParametersetParameteris an administrative command for modifying options normally set on the command line. You must issue thesetParametercommand against the admin database.
Compatibilidade
Esse comando está disponível em implantações hospedadas nos seguintes ambientes:
MongoDB Enterprise: a versão autogerenciada e baseada em assinatura do MongoDB
MongoDB Community: uma versão com código disponível, de uso gratuito e autogerenciada do MongoDB
Importante
This command is not supported in MongoDB Atlas clusters. For information on Atlas support for all commands, see Unsupported Commands.
Sintaxe
db.adminCommand( { setParameter: 1, <parameter>: <value> } )
Para obter os parâmetros disponíveis, incluindo exemplos, consulte Parâmetros de MongoDB Server para uma implementação autogerenciada.
Comportamento
Persistência
Commands issued by the admin command setParameter do not survive server restarts. For a persistent option use the --setParameter command line option or the setParameter configuration file setting.
Stable API
When using Stable API V1 with apiStrict set to true, you cannot use setParameter to modify server parameters.