Remote system maintenance

From aiskillstore/marketplace · View interactive version

Remote system maintenance is an AI agent skill from the GitHub repository aiskillstore/marketplace. This skill should be used when performing maintenance or diagnostics on remote Linux systems. Triggers on "remote server", "Linux maintenance", "Ubuntu cleanup", "Debian", "disk space", "apt cleanup", "journal vacuum", "snap cleanup", "system diagnostics". Provides structured three-phase checklists

How to use this skill

Skill file

Remote System Maintenance

Purpose

Structured guidance for diagnosing and maintaining remote Linux systems through SSH/tmux sessions, with emphasis on Ubuntu/Debian platforms.

Applicable Scenarios

Three-Phase Approach

Phase 1: Initial Diagnostics

Capture baseline system state:

Phase 2: System Log Review

Examine system health indicators:

Phase 3: Package Assessment

Identify maintenance opportunities:

Ubuntu/Debian Cleanup Sequence

Execute these seven stages in order:

  1. Package Cache Refresh - apt update to sync package lists
  2. System Upgrades - apt upgrade for security and bug fixes
  3. Orphan Removal - apt autoremove to clean unused dependencies
  4. Cache Purging - apt clean to reclaim package cache space
  5. Journal Pruning - journalctl --vacuum-time=7d to limit log retention
  6. Snap Revision Cleanup - Remove disabled snap revisions (see below)
  7. Temporary Directory Assessment - Review /tmp and /var/tmp for cleanup opportunities

Snap Revision Cleanup Technique

Snap keeps old revisions by default. To identify and remove:

# List all disabled snap revisions
snap list --all | awk '/disabled/{print $1, $3}'

# Remove specific revision
snap remove <package-name> --revision=<revision-number>

Important: Requires explicit removal by revision number, not simple package uninstallation.

Documentation Requirements

All maintenance sessions must generate structured logs recording:

  1. System Identification
  1. Resource States
  1. Actions Taken
  1. Follow-up Recommendations

Expected Results

Real-world recovery examples:

Time Commitment

Typical maintenance session: 15-30 minutes including diagnostics, cleanup, and documentation.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.