> For the complete documentation index, see [llms.txt](https://docs.verge.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.verge.io/knowledge-base/zh/networking/adjusting-bgp-timers.md).

# 调整 BGP 定时器

BGP（边界网关协议）保持计时器对于维持路由器之间稳定的 BGP 会话至关重要。本文件将指导您将 BGP 保持定时器配置为：保活间隔 5 秒，保持时间 15 秒。

## 前提条件

1. **BGP 基本配置**：您应已设置好基本的 BGP 配置。
2. **FRR 配置基础知识**：熟悉 FRR 配置命令和流程。

## 配置步骤

### 第 1 步：设置 BGP

1. 创建一个新的外部网络。
2. 将其 IP 地址类型设置为 BGP/OSPF。
3. 设置 ASN（自治系统编号）。
4. 定义 IP 地址和网络地址。
5. 如果这是 VLAN，请配置二层 ID。
6. 选择一个接口网络。

### 第 2 步：打开 BGP 网络

1. 打开您创建的网络。
2. 选择 **路由器** ，位于左侧菜单中。
3. 打开您在创建网络时定义的 ASN。
4. 选择 **新建** ，位于左侧菜单中。
5. 选择 **计时器** ，位于命令菜单中。
6. 在 **参数**下，输入 `bgp x y` 其中 `x` 是保活间隔，而 `y` 是保持时间。例如， `bgp 5 15`.
7. 选择 **提交**。这将使您返回到路由器页面。
8. 返回 BGP 网络。最近的更改要生效，需要重启。点击 **重启** 以应用更改。

### 第 3 步：验证设置

1. 返回您配置的 BGP 网络。
2. 选择 **网络诊断** ，位于左侧菜单中。
3. 选择 **FRRRouting BGP/OSPF** ，从查询下拉菜单中。
4. 运行默认命令 `show running-config`.
5. 第 2 步中修改的设置现在应显示在运行配置中。

有关其他值和变量的更多信息，请参阅 [FRR 文档](https://docs.frrouting.org/en/latest/basic.html).


---

# 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.verge.io/knowledge-base/zh/networking/adjusting-bgp-timers.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.
