Skip to content
Back to skills

Server Maintenance

ASecurity

Server Maintenance

  • 33 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 5, 2026
testingbash

Security analysis

A100/100

Pro scans all 7 files and shows the line behind each finding

Scanned September 5, 2026

npx -y skills add dvcrn/openclaw-skills-marketplace --skill server-maintenance --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Server Maintenance?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Server Maintenance
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/dvcrn-server-maintenance/badge)](https://www.skillsdirectory.com/skills/dvcrn-server-maintenance)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: server-maintenance
description: "Server Maintenance"
---

# Server Maintenance Skill

## 描述
自动化服务器维护工具。检查磁盘使用率、清理缓存、优化系统资源。支持多服务器批量操作。

## 触发词
- 服务器维护
- 清理磁盘
- 检查磁盘
- server maintenance
- disk cleanup

## 功能

### 1. 磁盘检查
- 检查磁盘使用率
- 识别大文件和目录
- 分析缓存占用

### 2. 自动清理
- npm 缓存清理
- Playwright 旧版本清理
- 临时文件清理

### 3. 系统优化
- Swap 使用检查
- 内存占用分析
- 进程资源监控

### 4. 多服务器支持
- 支持本地和远程服务器
- SSH 批量操作
- 统一报告输出

## 使用方法

### 单服务器检查
```bash
bash ~/.openclaw/skills/server-maintenance/check.sh
```

### 多服务器批量维护
```bash
bash ~/.openclaw/skills/server-maintenance/maintain-all.sh
```

### 定时任务
在 OpenClaw 中设置 cron:
```json
{
  "schedule": "0 2 * * 0",
  "task": "server-maintenance"
}
```

## 配置

服务器列表在 `servers.json`:
```json
{
  "servers": [
    {
      "name": "硅谷",
      "host": "localhost",
      "type": "local"
    },
    {
      "name": "中央",
      "host": "43.163.225.27",
      "type": "ssh"
    },
    {
      "name": "东京",
      "host": "43.167.192.145",
      "type": "ssh"
    }
  ]
}
```

## 输出示例

```
=== 服务器维护报告 ===
时间:2026-03-03 10:08

| 服务器 | 清理前 | 清理后 | 释放空间 |
|--------|--------|--------|----------|
| 硅谷   | 79%    | 69%    | 4.7GB    |
| 中央   | 88%    | 78%    | 5.0GB    |
| 东京   | 71%    | 63%    | 4.0GB    |

总计释放:13.7GB
```

## 安全措施
- 只清理已知安全的缓存目录
- 不删除用户数据
- 操作前自动备份关键配置
- 支持 dry-run 模式

## 依赖
- bash
- ssh(远程服务器)
- du, df(磁盘工具)
- npm(缓存清理)

## 版本
v1.0.0 - 2026-03-03

Files in this skill

  • README.md1.8 KB
  • SKILL.md1.9 KB
  • check.sh1 KB
  • cleanup.sh1.4 KB
  • maintain-all.sh1001 B
  • package.json674 B
  • servers.json672 B

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…