> For the complete documentation index, see [llms.txt](https://docs.mongoing.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mongoing.com/guan-li/configuration-and-maintenance.md).

# 配置和维护

本节介绍常规管理操作，包括更新MongoDB部署的配置。

* [运行时数据库配置](https://docs.mongodb.com/v4.2/administration/configuration/)

  概述了常见的MongoDB配置和常见用例的最佳实践配置的示例。
* [升级至MongoDB的最新版本](https://docs.mongodb.com/v4.2/tutorial/upgrade-revision/)

  介绍在不同版本之间升级MongoDB部署的基本过程。
* [管理mongod进程](https://docs.mongodb.com/v4.2/tutorial/manage-mongodb-processes/)

  启动、配置和管理运行 [mongod](https://docs.mongodb.com/v4.2/reference/program/mongod/#bin.mongod) 进程。
* [终止运行操作](https://docs.mongodb.com/v4.2/tutorial/terminate-running-operations/)

  使用[`db.killOp()`](https://docs.mongodb.com/v4.2/reference/method/db.killOp/#db.killOp)和[`maxTimeMS()`](https://docs.mongodb.com/v4.2/reference/method/cursor.maxTimeMS/#cursor.maxTimeMS)停止正在进行的MongoDB客户端操作。
* [轮转日志文件](https://docs.mongodb.com/v4.2/tutorial/rotate-log-files/)

  归档当前日志文件并启动新的日志文件。

## 附：

运行时数据库配置：<https://docs.mongodb.com/v4.2/administration/configuration/>

升级至MongoDB的最新版本：<https://docs.mongodb.com/v4.2/tutorial/upgrade-revision/>

管理mongod进程：<https://docs.mongodb.com/v4.2/tutorial/manage-mongodb-processes/>

终止运行操作：<https://docs.mongodb.com/v4.2/tutorial/terminate-running-operations/>

轮转日志文件：<https://docs.mongodb.com/v4.2/tutorial/rotate-log-files/>

原文链接：<https://docs.mongodb.com/v4.2/administration/configuration-and-maintenance/#configuration-and-maintenance>

译者：孔令升

校对：徐扬


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.mongoing.com/guan-li/configuration-and-maintenance.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
