Ask Your Question
1

fedora 27: dnf autoremove wants to remove 1.2G of packages

asked 2017-11-18 04:27:59 -0600

antismap gravatar image

After upgrading from fedora 26 to fedora 27, I wanted to cleanup the not needed packages using

dnf autoremove

This seemed to be the equivalent of debian's

apt-get autoremove

Surprisingly, dnf wants to remove most of my installed packages ! How is that possible ?

$ sudo dnf autoremove
Last metadata expiration check: 3:23:29 ago on Sat 18 Nov 2017 07:48:21 AM CET.
Dependencies resolved.
===================================================================================================================================
 Package                                       Arch      Version                                  Repository                  Size
===================================================================================================================================
Removing:
 NetworkManager-openconnect                    x86_64    1.2.4-6.fc27                             @fedora                    1.9 M
 NetworkManager-openvpn                        x86_64    1:1.8.0-3.fc27                           @fedora                    949 k
 NetworkManager-openvpn-gnome                  x86_64    1:1.8.0-3.fc27                           @fedora                    360 k
 NetworkManager-pptp                           x86_64    1:1.2.4-4.fc27                           @fedora                    525 k
 NetworkManager-pptp-gnome                     x86_64    1:1.2.4-4.fc27                           @fedora                    143 k
 NetworkManager-vpnc                           x86_64    1:1.2.4-4.fc27                           @fedora                    557 k
 NetworkManager-vpnc-gnome                     x86_64    1:1.2.4-4.fc27                           @fedora                    155 k
 PackageKit-command-not-found                  x86_64    1.1.7-1.fc27                             @fedora                     43 k
 PackageKit-gstreamer-plugin                   x86_64    1.1.7-1.fc27                             @fedora                     19 k
 PackageKit-gtk3-module                        x86_64    1.1.7-1.fc27                             @fedora                     22 k
 PyQt4                                         x86_64    4.12.1-4.fc27                            @fedora                     15 M
 SDL_image                                     x86_64    1.2.12-17.fc27                           @fedora                     76 k
 SDL_mixer                                     x86_64    1.2.12-14.fc27                           @fedora                    210 k
 SDL_ttf                                       x86_64    2.0.11-11.fc27                           @fedora                     35 k
 adwaita-qt4                                   x86_64    1.0-3.fc27                               @fedora                    651 k
 alacarte                                      noarch    3.11.91-7.fc27                           @fedora                    369 k
 allegro                                       x86_64    4.4.2-18.fc27                            @fedora                    1.4 M
 allegro-devel                                 x86_64    4.4.2-18.fc27                            @fedora                    4.0 M
 aspell                                        x86_64    12:0.60.6.1-18.fc27                      @fedora                    3.0 M
 atmel-firmware                                noarch    1.3-17.fc27                              @fedora                    711 k
 attr                                          x86_64    2.4.47-21.fc27                           @fedora                    154 k
 audacity-freeworld                            x86_64    2.1.3-4.fc27                             @rpmfusion-free             22 M
 avahi-gobject                                 x86_64    0.7-3.fc27                               @fedora                     48 k
 avahi-ui-gtk3                                 x86_64    0.7-3.fc27                               @fedora                     51 k
 b43-fwcutter                                  x86_64    019-10.fc27                              @fedora                     46 k
 b43-openfwwf                                  noarch    5.2-16.fc27                              @fedora                     31 k
 baobab                                        x86_64    3.26.1-1.fc27                            @fedora                    1.3 M
 bash-completion                               noarch    1:2.6-2.fc27                             @fedora                    893 k
 blosc                                         x86_64    1.11.3-3.fc27                            @fedora                    103 k
 brasero-libs                                  x86_64    3.12.2-2.fc27                            @fedora                    938 k
 bridge-utils                                  x86_64    1.5-16.fc27                              @fedora                     55 k
 cheese                                        x86_64    2:3.26.0-1.fc27                          @fedora                    419 k
 chrome-gnome-shell                            x86_64    9-3.fc27                                 @fedora                     60 k
 cifs-utils                                    x86_64    6.7-5.fc27                               @updates                   168 k
 cl-asdf                                       noarch    20101028-12.fc27                         @fedora                    469 k
 clutter-gst2                                  x86_64    2.0.18-4.fc27                            @fedora                    199 k
 cmark-lib                                     x86_64    0.27.1-4.fc27                            @fedora                    288 k
 common-lisp-controller                        noarch    7.4-12.fc27                              @fedora                     26 k
 compat-lua-libs                               x86_64    5.1.5-9.fc27                             @fedora                    486 k
 compat-openssl10-pkcs11-helper                x86_64    1.22-3.fc27                              @fedora                    145 k
 compat-wxBase3-gtk2                           x86_64    3.0.2-32.fc27                            @fedora                    3.2 M
 compat-wxGTK3-gtk2                            x86_64    3.0.2-32.fc27                            @fedora                     19 M
 compat-wxGTK3-gtk2-gl                         x86_64    3.0.2-32.fc27                            @fedora                     90 k
 coolkey                                       x86_64    1.1.0-35.fc27                            @fedora                    289 k
 crda                                          x86_64    3.18_2016.02.08-4.fc27                   @fedora                     62 k
 cryptsetup                                    x86_64    1.7.5-3.fc27                             @fedora                    295 k
 cyrus-sasl-plain                              x86_64    2.1.26-34.fc27                           @fedora                     39 k
 dbus-python                                   x86_64    1 ...
(more)
edit retag flag offensive close merge delete

2 Answers

Sort by » oldest newest most voted
1

answered 2017-11-18 14:33:07 -0600

villykruse gravatar image

updated 2017-11-19 06:52:49 -0600

dnf autoremove looks at all packages which are not required by other packages, then it tests a flag saying if this package has been user installed, that is, not just been pulled in by a dependency. This has been shown to be rather unreliable, especially when packages have been installed by Gnome Software, or PackageKit. They are trying to fix that for quite some time.

What you can do is

dnf mark install \*

which will mark each installed package as user installed, and the autoremove would then not remove anything.

Also, install python3-dnf-plugin-leaves and python3-dnf-plugin-show-leaves so you can run

dnf leaves

to get a list of packages you might consider removing. The leaves are packages not required by any other packages.

edit flag offensive delete link more

Comments

Okay, thank you. For installing the leaves command i did that :

sudo dnf install 'dnf-command(leaves)'

I think the packages that you mentioned are not for fedora 27.

antismap gravatar imageantismap ( 2017-11-19 05:51:59 -0600 )edit

Typo, should be python3-dnf-plugin-leaves and python3-dnf-plugin-show-leaves

sudo dnf install 'dnf-command(leaves)' also works,

villykruse gravatar imagevillykruse ( 2017-11-19 06:51:26 -0600 )edit
0

answered 2018-12-05 10:34:50 -0600

simmon gravatar image

updated 2018-12-14 21:30:03 -0600

autoremove make a some trouble...and erase essential program... In the worst case, it can't be back your system..... yes...do not usually....option -y.... also, yum option....-y

it's has make a trouble...all relation program or basis of system file remove. so, use rpm -qa| "you want to check remove program" like this; (example)

 # rpm -qa|grep cyrus
 cyrus-sasl-gssapi-2.1.27-0.3rc7.fc29.x86_64
 cyrus-sasl-plain-2.1.27-0.3rc7.fc29.x86_64
 cyrus-sasl-2.1.27-0.3rc7.fc29.x86_64
 cyrus-sasl-lib-2.1.27-0.3rc7.fc29.x86_64
 cyrus-sasl-devel-2.1.27-0.3rc7.fc29.x86_64

you can see...many install program...you can remove that make some trouble program or check like a program befor remove program...do not use "-y" option;

 # rpm -e cyrus-sasl-gssapi-2.1.27-0.3rc7.fc29.x86_64
 # dnf remove "you want to remove program"

maybe ...some trouble cache...or rpm db problem.

# dnf clean all

written by simmon

edit flag offensive delete link more

Your Answer

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

Add Answer

Question Tools

1 follower

Stats

Asked: 2017-11-18 04:27:59 -0600

Seen: 1,033 times

Last updated: Dec 14