Ask Your Question

How to remove kde without removing gnome and cinnamon, fedora 25?

asked 2017-04-18 12:01:15 +0000

andreibarbos gravatar image

Some while ago I installed KDE Plasma ("sudo dnf group install kde-desktop-environment") to give it a try, however I want now to uninstall it ("sudo dnf group remove kde-desktop-environment"). The problem is that when I issue the command to uninstall KDE it will uninstall also gnome and cinnamon. I found that there was a bug filed on bugzilla about a very similar scenario, i.e. https://bugzilla.redhat.com/show_bug.... , however the proposed solution of running "sudo dnf group install 'Fedora Workstation'" to mark the gnome packages as belonging to the 'Fedora Workstation' group does not work for me.

When I run the 'sudo dnf group list' command it tells me that both 'Fedora Workstation' and 'Cinnamon Desktop' groups are installed, as it can be observed in the first listing below. I am perplexed as to why then removing KDE would remove gnome and cinnamon as well.

As opposed to the bug on bugzilla, I started with a fresh install of fedora 22 some while ago which I progressively updated to each new version of fedora to bring me now at fedora 25. I don't know if this plays a part or not however.

After the result of running "sudo dnf group list", one can also find the list of packages that were installed when I ran the command "sudo dnf group install kde-desktop-environment" to install the KDE desktop and the list of packages that the command "sudo dnf group remove kde-desktop-environment" wants to remove.

My question is then how can I remove KDE without removing gnome and cinnamon? Or what can I do to mark the gnome/cinnamon packages as belonging to their respective group such that they won't be removed when I try to remove KDE?

-> result of "sudo dnf group list":

Available environment groups:

Fedora Custom Operating System
   Minimal Install
   Fedora Server Edition
   Fedora Cloud Server
   Xfce Desktop
   LXDE Desktop
   Hawaii Desktop
   LXQt Desktop
   MATE Desktop
   Sugar Desktop Environment
   Development and Creative Workstation
   Web Server
   Infrastructure Server
Installed environment groups:
   Fedora Workstation
   KDE Plasma Workspaces
   Cinnamon Desktop
   Basic Desktop
Installed groups:
   Administration Tools
   Hardware Support
   System Tools
Available groups:
   3D Printing
   Ansible node
   Audio Production
   Authoring and Publishing
   Books and Guides
   C Development Tools and Libraries
   Cloud Infrastructure
   Cloud Management Tools
   Container Management
   D Development Tools and Libraries
   Design Suite
   Development Tools
   Domain Membership
   Fedora Eclipse
   Educational Software
   Electronic Lab
   Engineering and Scientific
   FreeIPA Server
   Headless Management
   MATE Applications
   MATE Compiz
   Medical Applications
   Network Servers
   RPM Development Tools
   Security Lab
   Text-based Internet
   Window Managers
   Games and Entertainment
   Sound and Video

-> packages that were installed when I ran "sudo dnf group install kde-desktop-environment"

Transaction performed with:
    Upgraded      dnf-1.1.10-4.fc25.noarch @@commandline
    Upgraded      rpm-4.13.0-6.fc25.x86_64 @@commandline
Packages Altered:
    Install NetworkManager-l2tp-1.2.4-1.fc25.x86_64                    @updates
    Install NetworkManager-libreswan-1.2.4-1.fc25.x86_64               @fedora
    Install PackageKit-Qt5-0.9.5-6.fc24.x86_64                         @fedora
    Install adcli-0.8.0-2.fc24.x86_64                                  @fedora
    Install adobe-source-han-sans-tw-fonts-1.004-3.fc24.noarch         @fedora
    Install akregator-16.08 ...
edit retag flag offensive close merge delete

3 answers

Sort by ยป oldest newest most voted

answered 2017-04-18 15:56:01 +0000

genodeftest gravatar image

If you recently did that installation, dnf history might help you. Use dnf history list and dnf history info [some history ID] to find out which history ID your KDE installation had. Then run dnf history undo [some history ID] to undo that transaction. This might undo all package transactions since [some history ID]. See man dnf, section "history". There is also another option, dnf history rollback.

If that is not possible, try dnf remove kf5-\* plasma-\* kde\* sddm\* breeze\* followed by dnf autoremove. This might do the trick, or it might leave some packages, I don't know.

PS: the backslash (\) is used to make bash not interpret (expand) the asterisk (*), so that dnf can expand it.

edit flag offensive delete link more

answered 2017-04-18 15:37:08 +0000

florian gravatar image

updated 2017-04-18 15:38:54 +0000

You are pointing already to the bug report related to that issue.

The workaround described under https://bugzilla.redhat.com/show_bug.... should work

  1. sudo dnf group install "Fedora Workstation" (it will mark all packages from group 'Fedora Workstation' as installed)

  2. remove KDE by running sudo dnf remove @kde-desktop

edit flag offensive delete link more

answered 2017-04-19 04:47:41 +0000

gobigobi66 gravatar image

updated 2017-04-19 04:49:10 +0000

DNF is way too buggy to give operations like installing and removing DEs on a productive system. I would always recommend to do such stuff in a VM (using Gnome Boxes or `virt-manager1) or booting a Live Image.

Anything else will screw up the system, or at the very least require a lot of manual troubleshooting. To date, dnf is not even capable of talking to Gnome Software and perform a reliable dnf autoremove.

So, just be careful on what you test on productive systems.

edit flag offensive delete link more


The bug related to dnf autoremove has been fixed in last August, quite some time ago. And no, dnf itself is not buggy. It was PackageKit which was messing with dnf's database, but this issue is gone now.

In case dnf suggests to remove packages you still need, try dnf mark install or use dnf or rpm to search for unsatisfied dependencies.

genodeftest ( 2017-04-19 07:48:38 +0000 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]

Use your votes!

  • Use the 30 daily voting points that you get!
  • Up-vote well framed questions that provide enough information to enable people provide answers.
  • Thank your helpers by up-voting their comments and answers. If a question you asked has been answered, accept the best answer by clicking on the checkbox on the left side of the answer.
  • Down-voting might cost you karma, but you should consider doing so for incorrect or clearly detrimental questions and answers.

Question Tools

1 follower


Asked: 2017-04-18 12:01:15 +0000

Seen: 111 times

Last updated: Apr 19