performance-tuning

performance-tuning is a skill for Claude Code, Codex from BagelHole/DevOps-Security-Agent-Skills. It costs 28 tokens per session (3,355 once invoked), scanned B, original, MIT.

A guide to measuring and tuning Linux performance across the CPU, memory, storage, network, and kernel settings.

In plain words
What is it for?
Use it to investigate bottlenecks, benchmark servers, tune workloads for production or load tests, and adjust Linux settings for containers, virtual machines, or physical hosts.
Why use it?
It helps identify the actual source of slowdowns or resource exhaustion before changing system settings, and provides a way to compare results afterward.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to investigate bottlenecks, benchmark servers, tune workloads for production or load tests, and adjust Linux settings for containers, virtual machines, or physical hosts.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/bagelhole/devops-security-agent-skills/performance-tuning
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add BagelHole/DevOps-Security-Agent-Skills --skill performance-tuning
Clone the repo
git clone --depth 1 https://github.com/BagelHole/DevOps-Security-Agent-Skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for performance-tuning

README.md
[![agentmods](https://agentmods.dev/badge/skills/bagelhole/devops-security-agent-skills/performance-tuning/github.svg)](https://agentmods.dev/skills/bagelhole/devops-security-agent-skills/performance-tuning)
Your own site
<a href="https://agentmods.dev/skills/bagelhole/devops-security-agent-skills/performance-tuning"><img src="https://agentmods.dev/badge/skills/bagelhole/devops-security-agent-skills/performance-tuning/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for performance-tuning

Your own site · 80×15
<a href="https://agentmods.dev/skills/bagelhole/devops-security-agent-skills/performance-tuning"><img src="https://agentmods.dev/badge/skills/bagelhole/devops-security-agent-skills/performance-tuning.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,355 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 3 findings, up to medium

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • medium Privilege Escalation · line 25
    Commands invoke sudo or root privileges. Verify this elevated access is necessary and justified.
    Fix: Avoid sudo/root unless strictly required. Prefer least-privilege patterns. If elevation is needed, document the justification and scope.
  • medium Rogue Agent · line 207
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
  • medium Rogue Agent · line 248
    Skill establishes unauthorized persistence across sessions via cron jobs, startup scripts, or state files. Session persistence allows an attacker to maintain access beyond the current interaction.
    Fix: Remove any persistence mechanisms (cron jobs, startup scripts, state files). Skills should not maintain state across sessions without explicit user consent.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00028 $0.03355
Opus 5 $0.00014 $0.01677
Sonnet 5 $0.00006 $0.00671
Haiku 4.5 $0.00003 $0.00335

Measured 9d ago against content hash 309ec0bfdd9f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade B, and why

performance-tuning scanned grade B with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

- Root or sudo access on the target system
infrastructure/servers/performance-tuning/SKILL.md · 366 lines

How it starts

The opening of the file, as written. The whole thing — 366 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Performance Tuning

Optimize Linux system performance through kernel parameter tuning, I/O scheduler selection, memory management, CPU governor configuration, and benchmarking. Covers methodology, real sysctl settings, and tool-based validation.

When to Use

  • Server experiencing high latency, throughput bottlenecks, or resource exhaustion
  • Preparing infrastructure for high-traffic events or load tests
  • Tuning a database server, web server, or application host for production
  • Diagnosing whether a bottleneck is CPU, memory, disk I/O, or network
  • Establishing baseline performance metrics before and after changes
  • Configuring kernel parameters for containers, VMs, or bare-metal hosts

Prerequisites

  • Root or sudo access on the target system
  • sysstat package installed (provides sar, iostat, mpstat)
  • linux-tools or perf package for CPU profiling
  • Benchmarking tools: fio (disk), sysbench (CPU/memory), iperf3 (network)
  • Baseline metrics collected before making any changes

Performance Analysis Methodology

Always follow this order:

  1. Collect baseline -- measure current performance with tools
  2. Identify bottleneck -- determine if CPU, memory, I/O, or network
  3. Change one parameter -- apply a single tuning change
  4. Measure impact -- re-run the same benchmark
  5. Document -- record the change and its effect
  6. Iterate or revert -- keep the change if beneficial, revert if not

System Monitoring Tools

# CPU and process monitoring
top                              # Interactive process viewer
htop                             # Enhanced interactive viewer
mpstat -P ALL 2                  # Per-CPU utilization every 2 seconds
pidstat -u 2                     # Per-process CPU usage

# Memory monitoring
free -h                          # Memory summary
vmstat 2                         # Virtual memory stats every 2 seconds
# Columns: r=runnable, b=blocked, si/so=swap in/out, bi/bo=block I/O

# Disk I/O monitoring
iostat -xz 2                     # Extended disk stats every 2 seconds
# Key columns: %util, await (latency), r/s, w/s
iotop -oP                        # Show processes doing I/O

# Network monitoring
sar -n DEV 2                     # Network interface stats
ss -s                            # Socket summary
nstat                            # Network counters

# CPU profiling (requires perf)
perf top                         # Real-time function-level CPU profiling
perf stat -a sleep 10            # System-wide counters for 10 seconds
perf record -g -a sleep 30       # Record 30 seconds of call stacks
perf report                      # Analyze recorded data

# One-liner: check all major resources
echo "=== CPU ===" && mpstat 1 1 && echo "=== MEM ===" && free -h && echo "=== DISK ===" && iostat -x 1 1 && echo "=== NET ===" && ss -s

Read the full file on GitHub · 366 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 366 lines · 28 tokens per session scan B 309ec0bfdd9f

Subscribe to this mod's changes

performance-tuning is a skill published in the GitHub repository BagelHole/DevOps-Security-Agent-Skills (1,084 stars, last pushed 3mo ago), licensed MIT. It adds 28 tokens to every session and 3,355 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it B with 1 finding (asks for root). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

implementing-aws-config-rules-for-compliance

Implementing AWS Config rules for continuous compliance monitoring of AWS resources, deploying managed and custom rules aligned to CIS and PCI DSS frameworks, configuring automatic remediation with SSM Automation, and aggregating compliance data across accounts.

adriannoes/awesome-agentic-ai · 53 tokens

ec2

AWS EC2 virtual machine management — instances, security groups, key pairs, AMIs, EBS volumes, Auto Scaling Groups, Spot Instances, Session Manager, placement groups, and instance lifecycle automation. Trigger on ANY of these, even when EC2 isn't named explicitly: - Launching or provisioning: "spin up a server"…

itsmostafa/aws-agent-skills · 320 tokens

eventbridge

AWS EventBridge serverless event bus for event-driven architectures. Use when creating rules, configuring event patterns, setting up scheduled events, integrating with SaaS, or building cross-account event routing.

itsmostafa/aws-agent-skills · 41 tokens

s3

AWS S3 object storage for bucket management, object operations, and access control. Use when creating buckets, uploading files, configuring lifecycle policies, setting up static websites, managing permissions, or implementing cross-region replication.

itsmostafa/aws-agent-skills · 45 tokens

sqs

AWS SQS message queue service for decoupled architectures. Use when creating queues, configuring dead-letter queues, managing visibility timeouts, implementing FIFO ordering, or integrating with Lambda.

itsmostafa/aws-agent-skills · 39 tokens

iam

AWS Identity and Access Management for users, roles, policies, and permissions. Use when creating IAM policies, configuring cross-account access, setting up service roles, troubleshooting permission errors, or managing access control.

itsmostafa/aws-agent-skills · 42 tokens