# 使用 cockpit 網路設定 bond

```
cd /etc/network
cp interfaces interfacesbak
```

## nano /etc/network/interfaces

### 移除 rename4 與  rename5 的設定，以便 network-manager 管理

```
auto lo
iface lo inet loopback

iface eno1 inet manual

auto vmbr0
iface vmbr0 inet static
        address 120.115.3.32
        netmask 255.255.255.0
        gateway 120.115.3.253
        bridge_ports eno1
        bridge_stp off
        bridge_fd 0

iface eno2 inet manual

```

### service network-manager restart

### 進入cockpit管理

![](/files/-LunD9Fo2pM7xU9gNKje)

![](/files/-LunCHMCdJbKOjEYR5HX)

![](/files/-LunDWwmDn1uLXnIaP9c)

![](/files/-LunDs251_m0Uak1LUPb)

設定 pve 的 NAT vmbr1

```
auto vmbr1
#private sub network
iface vmbr1 inet static
        address  10.10.10.1
        netmask  255.255.255.0
        bridge_ports none
        bridge_stp off
        bridge_fd 0

        post-up echo 1 > /proc/sys/net/ipv4/ip_forward
        post-up   iptables -t nat -A POSTROUTING -s '10.10.10.0/24' -o bond0 -j MASQUERADE
        post-down iptables -t nat -D POSTROUTING -s '10.10.10.0/24' -o bond0 -j MASQUERADE

```

service networking restart


---

# Agent Instructions: 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:

```
GET https://kawsing.gitbook.io/opensystem/andoid-shou-ji/pomoxve/fu-lu/shi-yong-cockpit-wang-lu-she-ding-bond.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
