docs: route change requires client daemon reconnect

Document two lessons from the RTSP-camera-via-subnet-route diagnosis:

1. Existing NetBird clients don't automatically re-apply new route
   config; daemons stuck in old state need explicit restart per
   platform (launchctl kickstart / App reconnect / compose restart).
   Shows up as 'Networks: -' on status output and no entry in the
   system routing table.

2. Some iOS apps (notably certain RTSP players) don't use the system
   VPN route and bypass NetBird entirely even when route is
   correctly installed. Safari test distinguishes 'route broken'
   from 'app doesn't respect VPN'.
This commit is contained in:
2026-04-18 22:39:28 +08:00
parent eee0c10687
commit dadb455184
2 changed files with 36 additions and 0 deletions

View File

@@ -88,6 +88,8 @@ reopen fd 8: permission denied
| Mac `netbird status` 卡在 `Management: Disconnected, rpc error` | daemon 本身卡死,`netbird up`/`down` 救不回 | `sudo launchctl kickstart -k system/netbird`(服務名是 `netbird` 而非 `io.netbird.client`);見 [peer-deployment-ops.md](./peer-deployment-ops.md) | | Mac `netbird status` 卡在 `Management: Disconnected, rpc error` | daemon 本身卡死,`netbird up`/`down` 救不回 | `sudo launchctl kickstart -k system/netbird`(服務名是 `netbird` 而非 `io.netbird.client`);見 [peer-deployment-ops.md](./peer-deployment-ops.md) |
| LXC CT100 SSH root 密碼被擋(`Permission denied` | sshd_config 內有 `PermitRootLogin prohibit-password``yes` 先出現first-match-wins | 加 `/etc/ssh/sshd_config.d/99-allow-root.conf` 覆蓋socket activation 不需重啟 sshd | | LXC CT100 SSH root 密碼被擋(`Permission denied` | sshd_config 內有 `PermitRootLogin prohibit-password``yes` 先出現first-match-wins | 加 `/etc/ssh/sshd_config.d/99-allow-root.conf` 覆蓋socket activation 不需重啟 sshd |
| 新 peer `netbird status` 顯示 Connected 但互 ping 都不通 | 主機同時跑 Tailscale kernel-mode`iptables-legacy ts-input``100.64.0.0/10` 非 tailscale0 封包全 dropNetBird `100.71.0.0/16` 中彈 | `iptables-legacy -I INPUT 1 -i wt0 -j ACCEPT` + FORWARD 同理systemd 持久化;詳見 [peer-deployment-ops.md](./peer-deployment-ops.md) | | 新 peer `netbird status` 顯示 Connected 但互 ping 都不通 | 主機同時跑 Tailscale kernel-mode`iptables-legacy ts-input``100.64.0.0/10` 非 tailscale0 封包全 dropNetBird `100.71.0.0/16` 中彈 | `iptables-legacy -I INPUT 1 -i wt0 -j ACCEPT` + FORWARD 同理systemd 持久化;詳見 [peer-deployment-ops.md](./peer-deployment-ops.md) |
| 加 subnet route 後部分裝置拿不到路由(`Networks: -``Status: Connecting` | 既有 NetBird daemon 不會自動重新套用 route卡在舊 state | 各裝置重連 daemonmacOS `launchctl kickstart`、iOS App Disconnect→Connect、Docker `compose restart`;見 [network-routes.md](./network-routes.md) |
| iPhone RTSP app 連不到 LAN 攝影機Safari 打 HTTP 可以) | 某些 iOS app 不走系統 VPN 路由 | 換支援 VPN 的 appVLC 等),或改用 NetBird FQDN |
## 檔案位置 ## 檔案位置

View File

@@ -133,6 +133,40 @@ ping 192.168.42.40 # pve-03
## 排錯 ## 排錯
### 症狀route 建好、routing peer 運作正常,但舊客戶端連不到 LAN
**典型現象**
- `netbird status --detail` 顯示 routing peer 有 `Networks: 192.168.42.0/24`
- 但 client 本機 `netstat -rn | grep 192.168.42` 沒有這條 route
- 或「有些 peer 可以連、有些不行」
**原因**NetBird client 在 daemon 啟動時才建立完整 network map之後 route 政策變更會 push 到 client但**既有的連線狀態若卡住,沒辦法套用新 route**。
**修復(各平台)**
- **macOS**:
```bash
sudo launchctl kickstart -k system/netbird
```
- **iOS**: App 內 Disconnect → 等 5 秒 → Connect
- **Linux systemd**: `sudo systemctl restart netbird`
- **Docker 容器**: `docker compose -f /opt/netbird/docker-compose.yml restart`
**本部署的實例2026-04-18**subnet route 剛建好時測試通過,但 daemon 一直沒重啟的裝置iPhone、CT124後來出現 `Status: Connecting` 假象route 也沒進 routing table。全裝置 kickstart / reconnect 後恢復。
### iOS RTSP / 特定 app 不走 NetBird route
iPhone 上**某些 app** 不吃系統 VPN 路由(特別是直接用 socket API 的 RTSP 播放器),即使 NetBird route 設好也連不到。
**排查步驟:**
1. 在 iPhone Safari 打開 `http://<目標 LAN IP>/`
2. 如果能通 → NetBird route 正常,問題在那個 app 對 VPN 的支援
3. 如果不能通 → iPhone NetBird daemon 要重連(見上一節)
**常見解法**
- 換一個支援 VPN 的 RTSP appVLC 通常 OK
- 或讓 app 用 FQDN 而非 IP例如 `rtsp://192-168-42-150.netbird.selfhosted:554/stream1` 如果 NetBird DNS 有設)
### 路由表拿到但 ping 不通 ### 路由表拿到但 ping 不通
通常是**帶路人的 IP forwarding 沒開**。再檢查: 通常是**帶路人的 IP forwarding 沒開**。再檢查: