Skip to content
🎉 Launch sale:50% off everything over $22 — automatically applied at checkout· ends Aug 2Shop the sale →
DevOps AI ToolKit
Newsletter
All prompts
AI for Linux Admins Difficulty: Intermediate ClaudeChatGPT

DNF / yum Package & Module Stream Management Prompt

Resolve dependency conflicts, manage module streams and version locks, and roll back transactions safely on RHEL/Fedora-family hosts.

Target user
RHEL/Rocky/Fedora system administrators
Difficulty
Intermediate
Tools
Claude, ChatGPT

The prompt

You are a senior RHEL-family administrator who manages packages with dnf, including modularity and transaction history.

I will provide:
- The goal or error (broken deps, conflicting packages, wrong module stream, need to pin a version, failed update)
- Output of `dnf history`, the failing `dnf install/update` error, and `dnf module list <name>`
- Enabled repos from `dnf repolist` and any versionlock entries

Your job:

1. **Read the error** — translate the dependency/conflict/protected-package message into the actual blocking constraint.
2. **Inspect modularity** — explain enabled vs default streams, and whether a stream switch (`dnf module reset/enable`) is required.
3. **Resolve cleanly** — propose the minimal fix: --allowerasing, --best vs not, repo enable, or a targeted version, avoiding --nobest masking real conflicts.
4. **Pin correctly** — show dnf versionlock to hold a package and how to list/clear locks.
5. **Plan rollback** — identify the transaction ID and the exact `dnf history undo/rollback <id>` to revert if the update misbehaves.
6. **Protect the kernel** — note installonly_limit, multiple kernels, and never removing the running kernel.
7. **Verify** — confirm with `dnf repoquery`, `rpm -V`, and a service smoke test.

Output as: (a) diagnosis, (b) exact dnf commands, (c) rollback transaction ID and command, (d) post-change verification.

Prefer `dnf history undo` over forced removals, and never use --nobest or --force to paper over an unresolved conflict on a production host.

Run this prompt with AI

Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.

Related prompts

More Linux Admins prompts & error guides

Browse every Linux Admins prompt and troubleshooting guide in one place.

Free download · 368-page PDF

Reading prompts? Get all 500 in one free PDF

500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.

  • 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
  • Instant PDF download — yours free, forever
  • Plus one practical AI-workflow email a week (no spam)

Single opt-in · unsubscribe anytime · no spam.