# LibreNMS 修改設備IP

<span style="color: rgb(0, 0, 0);">**<span data-copy-service-computed-style="font-family: Arial, sans-serif, "Noto Color Emoji"; font-size: 16px; font-weight: 400; margin: 0px; text-decoration: none; border-bottom: 0px rgb(10, 10, 10);" data-subtree="aimfl,mfl">在 LibreNMS 中更改已纳管設備的 IP 地址（同時保留歷史繪圖與設定），最正規的做法是使用內建的 </span><span class="rQesXe MPyX">`renamehost.php`</span> 工具能完美保留 RRD 歷史圖表**</span>

```
cd /opt/librenms

./renamehost.php old_ip new_ip
```

<span style="color: rgb(0, 0, 0);">**更改的設備Snmp若有監聽指定IP記得修改**</span>

`/etc/snmp/snmpd.conf`

```
agentAddress udp:new_ip:161
```