DNF5-HISTORY(8)
π DNF5-HISTORY(8) π
okay bestie, welcome to dnf5-history, aka the History Command of the dnf5 manual. this is the little time machine for your package transactions and i'm literally obsessed with it π°οΈβ¨
β¨ NAME β¨
dnf5-history β the History Command, no cap.
πΈ SYNOPSIS πΈ
dnf5 history <subcommand> [options] [<transaction-spec>]
π¦ DESCRIPTION π¦
so like, the history command in DNF5 lets you peek at what went down in all your past transactions, and it also serves up several operations you can do on them β undoing, redoing, the whole glow-up routine π
.
β οΈ real talk: for these commands to work with your transactions, it's assumed that those transactions were committed while using the history_record configuration option. if they weren't... girl, they're not in the record, periodt.
for more tea about <transaction-spec>, go check dnf5-specs(7), Patterns specification <#transaction-spec-label>. π«Ά
π SUBCOMMANDS π
listβ List info about recorded transactions in the system. if you don't hand it a<transaction-spec>, it just uses all transactions. the whole archive, bestie.infoβ Print details about specific transactions. if no<transaction-spec>is specified, it uses the last transaction. (the most recent main character π)undoβ Revert all actions from the specified transaction. Exactly one transaction must be specified by<transaction-spec>. one. not two. don't be greedy πredoβ Repeat the specified transaction. it automatically uses--ignore-extrasand--ignore-installed. and unlike the rest of the history commands, it overrides reasons for transaction packages that are already installed. super useful for finishing interrupted transactions (we've all been there π). Exactly one transaction must be specified by<transaction-spec>.rollbackβ Undo all transactions performed after the specified transaction. yep, everything after. Exactly one transaction must be specified by<transaction-spec>.storeβ Store the transaction into a directory. if no<transaction-spec>is specified, it uses the last transaction.
π OPTIONS FOR LIST AND INFO π
--reverseβ Reverse the order of transactions in the output. flip it and reverse it π--contains-pkgs=PACKAGE_NAME,...β Show only transactions containing packages with specified names. this is a list option, and globs are supported β¨--jsonβ Request JSON output format for machine-readable results. Available forlistandinfosubcommands only. (sorry other subcommands, this one's not for you π)
π₯ OPTIONS FOR UNDO, ROLLBACK AND REDO π₯
--skip-unavailableβ Allow skipping packages actions that are not possible perform.--offlineβ Store the transaction to be performed offline. See offline command<#offline-command-ref-label>,dnf5-offline(8).--transientβ Applicable only on bootc (bootable containers) systems. Perform transactions using a transient overlay which will be lost on the next reboot. See also the persistence<#persistence-options-label>configuration option. (gone by next reboot, it's giving vanishing act π«₯)--store=PATHβ Store the current transaction in a directory at the specified PATH instead of running it. The stored transaction can be performed by the replay command<#replay-command-ref-label>,dnf5-replay(8). Note that repository ids in the stored transaction are mangled to@stored_transaction(repo_id)β this is required because during replaying the stored repositories are recreated and they might collide with already present repositories (this doesn't apply to the special@Systemrepository).
π OPTIONS FOR UNDO AND ROLLBACK π
--ignore-extrasβ Don't consider extra packages pulled into the transaction as errors. They will still be reported as warnings. (not mad, just disappointed π₯²)--ignore-installedβ Don't consider mismatches between installed and stored transaction packages as errors. They will still be reported as warnings. Using this option can result in an empty transaction. For install actions skip already installed packages. For upgrade actions skip groups or environments that are not installed. For remove actions skip not installed packages/groups/environments.
β EXAMPLES β
dnf5 history listβ List all transactions, where the most recent transaction is printed first.dnf5 history info 4β Show detailed info about the fourth transaction.dnf5 history info lastβ Show detailed info about the last transaction.dnf5 history info last-1β Show detailed info about the second to last transaction.dnf5 history list 4..8β List transactions with id in 4 to 8 range.dnf5 history undo lastβ Undo the last transaction.dnf5 history undo 4 --ignore-extrasβ Undo the fourth transaction ignoring extra packages pulled into the reverting transaction.dnf5 history list --jsonβ List all transactions in JSON format for programmatic processing.dnf5 history info last --jsonβ Show detailed info about the last transaction in JSON format with complete package details.
π JSON OUTPUT π
dnf5 history list --json
The command returns a JSON array, each element describing one transaction. Each transaction object contains the following fields:
id(integer) - Transaction ID.command_line(string) - Command line that initiated the transaction.start_time(integer) - Transaction start time, UNIX time.end_time(integer) - Transaction end time, UNIX time.user_id(integer) - User ID who initiated the transaction.status(string) - Transaction status, typically"Ok".releasever(string) - System release version when transaction occurred.altered_count(integer) - Number of packages altered in the transaction.
dnf5 history info --json
The command returns a JSON array, each element describing one transaction. Each transaction object contains the following fields:
id(integer) - Transaction ID.start_time(integer) - Transaction start time, UNIX time.end_time(integer) - Transaction end time, UNIX time.rpmdb_version_begin(string) - RPM database version before the transaction.rpmdb_version_end(string) - RPM database version after the transaction.user_id(integer) - User ID who initiated the transaction.user_name(string) - User name and details who initiated the transaction.status(string) - Transaction status, typically"Ok".releasever(string) - System release version when transaction occurred.description(string) - Command line that initiated the transaction.comment(string) - User comment for the transaction (usually empty).packages(array) - List of packages altered in the transaction. Each package object contains:nevra(string) - Packagename-epoch:version-release.architecture.action(string) - Action performed (Install,Remove,Upgrade, etc.).reason(string) - Reason for the action (User,Dependency, etc.).repository(string) - Repository from which the package came.
groups(array) - List of package groups altered (only present if groups were modified).environments(array) - List of package environments altered (only present if environments were modified).
For empty results, both commands return []. (empty array, empty vibe, but still valid π)
π§ SEE ALSO π§
dnf5-specs(7), Patterns specification <#specs-misc-ref-label>
π Author
See AUTHORS.md in dnf5 source distribution.
π Copyright
Contributors to the dnf5 project.
and that's the whole page, bestie!! this one's from the dnf5 manual, dated Sep 24, 2026, filed under DNF5-HISTORY(8) β go forth and undo your mistakes (package-wise, at least) πβ¨ππ¦
π¦ where this page comes from
- fedora 44: dnf5 5.4.6.0-1.fc44 Β· GPL-2.0-or-later
- fedora 44: dnf5 5.4.6.0-1.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms