← All commands
Topic hub Package Management
Windows Linux Package Management

Windows msiexec /x equivalent in Linux

Removes software installed through the distribution package manager.

Windows msiexec /x
Linux equivalents
Debian/Ubuntu apt
sudo apt remove PACKAGE
Fedora dnf
sudo dnf remove PACKAGE
Arch pacman
sudo pacman -Rns PACKAGE

Overview

What this command does

Removes software installed through the distribution package manager.

Migration tip: Use the same package manager that installed the software. Package names may differ from the application name shown in menus.

Practical tasks

Common use cases

Uninstall a package

Removes software installed through the distribution package manager.

sudo apt remove package

Remove a Debian package

sudo pacman -Rns package

Remove an Arch package and unneeded dependencies

sudo dnf remove package

Remove a Fedora package

Ready to run

Copyable Linux commands

Review paths, device names, package names and permissions before running any command.

sudo apt remove package
sudo pacman -Rns package
sudo dnf remove package

Walkthrough

Examples with explanations

sudo apt remove package # uninstall on Debian or Ubuntu
sudo pacman -Rns package # uninstall on Arch and clean dependencies
sudo dnf remove package # uninstall on Fedora

Reference

Common options and variations

Command or optionUse
sudo apt remove packageRemove a Debian package
sudo pacman -Rns packageRemove an Arch package and unneeded dependencies
sudo dnf remove packageRemove a Fedora package

Distro differences

Debian/Ubuntu vs Fedora vs Arch

This workflow changes mostly by Linux distribution package manager: Debian/Ubuntu uses apt, Fedora uses dnf, and Arch uses pacman.

DistributionPackage manager / baseEquivalent commandDifference to notice
Debian/Ubuntu apt sudo apt remove PACKAGE Use apt purge PACKAGE for package config removal too.
Fedora dnf sudo dnf remove PACKAGE Removes RPM packages from the system.
Arch pacman sudo pacman -Rns PACKAGE Removes package plus now-unused dependencies.

Important

What to watch out for

Dependency-cleanup options can remove additional packages. Review the package manager transaction before confirming.

Keep learning

Related Package Management commands