feat: 添加开设实例过多导致节点异常时的处理方式

This commit is contained in:
spiritlhl
2025-10-24 12:27:59 +00:00
parent e72981b4ef
commit fcaa2b5795
5 changed files with 51 additions and 4 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 152 KiB

View File

@@ -68,4 +68,27 @@ Execute
docker volume rm oneclickvirt-data oneclickvirt-storage oneclickvirt-config
```
to delete
to delete
## Excessive Instance Creation Causes Node Abnormalities
A prominent symptom is extremely slow operation execution, with commands taking several minutes to complete.
This commonly occurs when a node has poor I/O performance and is over-allocated with SWAP memory.
For example, in an LXD environment, executing ```lxc list``` may result in an error:
```shell
internal error, please report: running “lxd.lxc” failed: cannot create transient scope: DBus error “org.freedesktop.DBus.Error.TimedOut”: [Failed to activate service org.freedesktop.systemd1: timed out (service_start_timeout=25000ms)]
```
The root cause is setting too many instances while the provider imposes strict I/O restrictions.
![](./images/iofailed.png)
At this point, only one solution remains: force-reboot the node server.
Immediately after reboot, log into SSH and use the corresponding script to clear swap usage, then delete some instances to free resources.
Since containers take time to restart individually after reboot, this window may not delete many instances, but each reboot clears some.
Ultimately, when limiting instance counts, carefully assess node performance. Avoid overloading weaker nodes or those with strict constraints.

Binary file not shown.

After

Width:  |  Height:  |  Size: 152 KiB

View File

@@ -58,7 +58,7 @@ https://github.com/oneclickvirt/oneclickvirt/pkgs/container/oneclickvirt
所有镜像均支持 `linux/amd64` 和 `linux/arm64` 架构。
##### 全新环境下部署
##### 全新部署
使用已构建好的```amd64```或```arm64```镜像,会自动根据当前系统架构下载对应版本:
@@ -91,7 +91,7 @@ docker run -d \
以上的方式仅限于新安装
##### 旧环境下仅升级前后端
##### 旧环境下仅升级
先备份配置文件到当前路径下:
@@ -125,7 +125,7 @@ docker pull spiritlhl/oneclickvirt:latest
docker cp config.yaml oneclickvirt:/app/config.yaml
```
##### 旧环境下新部署
##### 旧环境下新部署
这将完全删除原有数据再部署,不仅需要删除容器还得删除对应的挂载点:

View File

@@ -69,3 +69,27 @@ docker volume rm oneclickvirt-data oneclickvirt-storage oneclickvirt-config
```
进行删除
## 开设实例过多导致节点异常
一个显著的现象是执行操作极其缓慢,甚至几分钟都执行不完毕一个命令
一般常见于节点的IO比较差此时又开了很多SWAP超配内存
比如lxd环境下执行```lxc list```会报错
```shell
internal error, please report: running “lxd.lxc” failed: cannot create transient scope: DBus error “org.freedesktop.DBus.Error.TimedOut”: [Failed to activate service org.freedesktop.systemd1: timed out (service_start_timeout=25000ms)]
```
原因就是设置的实例数量太多了商家又高度限制IO
![](./images/iofailed.png)
此时只有一种方法,重启节点服务器,强制重启
重启后立即登录SSH使用对应的脚本删除swap的使用然后删除一些实例释放资源
由于重启后容器虚拟机需要一段时间一个个自动重启,打这个时间差可能删不了多少,但每次重启都能删一些
最终还是需要在限制实例数量的时候,慎重考虑节点的性能,较弱或者限制较多的节点,建议不要开设过多实例