{"id":800,"date":"2017-10-28T13:00:54","date_gmt":"2017-10-28T12:00:54","guid":{"rendered":"http:\/\/chewett.co.uk\/blog\/?p=800"},"modified":"2017-10-28T00:04:58","modified_gmt":"2017-10-27T23:04:58","slug":"exclude-fedora-packages-updating-dnf-yum","status":"publish","type":"post","link":"https:\/\/chewett.co.uk\/blog\/800\/exclude-fedora-packages-updating-dnf-yum\/","title":{"rendered":"Exclude Fedora packages from updating with dnf or yum"},"content":{"rendered":"<p>This post describes how to exclude specific packages from being updated with Fedora and dnf or yum<\/p>\n<p><!--more--><\/p>\n<h2>How to exclude packages from updating<\/h2>\n<p>To exclude a package\u00a0or set of packages you can use the command line flag <code>--exclude<\/code>\u00a0with dnf or yum.<\/p>\n<p>All command snippets will include the command for running with yum or dnf. dnf replaced yum as the default package management system as of Fedora 22 so if you are running this distribution or later you will want to use the dnf commands.<\/p>\n<p>The update command accepts a package name to exclude for updating. For example you can run the following commands with yum or dnf.<\/p>\n<pre>sudo dnf update --exclude=firefox\r\nsudo yum update --exclude=firefox<\/pre>\n<p>This command would look to update all packages on the system apart from <code>firefox<\/code>.\u00a0In addition to matching a specific package wildcards can be used.<\/p>\n<p>For example, if I want to update everything except kernel packages I can run:<\/p>\n<pre>sudo dnf update --exclude=kernel*\r\nsudo yum update --exclude=kernel*<\/pre>\n<p>Here all packages would be updated apart from those that begin with <code>kernel<\/code>.<\/p>\n<h2>Why you might want to exclude some packages<\/h2>\n<p>Using the exclude flag can come in handy in a number of situations. For example you may want to use this to only update specific packages on virtual machines.<\/p>\n<p>Many virtual machines will have specific kernel modules compiled to better handle virtualization. An example would be <a href=\"http:\/\/chewett.co.uk\/blog\/484\/virtualbox-guest-additions-fedora\/\">Virtualbox Guest Additions<\/a>. Here you have to compile a module for your specific kernel version. If you were to update the kernel the module would no longer work. This would then mean you would need to reinstall this module.<\/p>\n<p>Therefore it can be helpful in certain circumstances\u00a0when you know you don&#8217;t want to update a package to exclude it from the list.<\/p>\n<h2>A small warning&#8230;<\/h2>\n<p>There must be a small warning with excluding packages when updating your machine. By doing this you are explicitly stopping certain packages from updating. Before you do this you should check to see if the update you are missing is not an important security update.<\/p>\n<p>However excluding packages can be helpful when you know that an update will cause issues for your system.<\/p>\n<p>Hopefully this can help people who need to exclude certain packages from updates. However as noted above there needs to be a small amount of caution when doing so. Stopping certain packages from updating can prevent issues however there is always a chance of exposing yourself to others by not updating.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This post describes how to exclude specific packages from being updated with Fedora and dnf or yum<\/p>\n","protected":false},"author":1,"featured_media":802,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[5],"tags":[181,41,39,175,182],"class_list":["post-800","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-informational","tag-dnf","tag-fedora","tag-linux","tag-package-management","tag-yum"],"wppr_data":{"cwp_meta_box_check":"No"},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/10\/excluding_fedora_packages_from_updating.jpg?fit=800%2C800&ssl=1","jetpack_shortlink":"https:\/\/wp.me\/p2toWX-cU","jetpack_sharing_enabled":true,"jetpack-related-posts":[{"id":1830,"url":"https:\/\/chewett.co.uk\/blog\/1830\/installing-linode-longview-on-fedora-28\/","url_meta":{"origin":800,"position":0},"title":"Installing Linode Longview on Fedora 28","author":"Chewett","date":"December 29, 2018","format":false,"excerpt":"This post talks about how you can install Linode Longview on Fedora 28. Why doesn't the standard instructions work? It turns out that you cannot just install Linode Longview on Fedora 28 as it isn't a supported operating system. When running the automatic install script the following error will appear.\u2026","rel":"","context":"In &quot;Fixes&quot;","block_context":{"text":"Fixes","link":"https:\/\/chewett.co.uk\/blog\/category\/fixes\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/12\/installing_linode_longview.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/12\/installing_linode_longview.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/12\/installing_linode_longview.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/12\/installing_linode_longview.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":1321,"url":"https:\/\/chewett.co.uk\/blog\/1321\/how-to-install-the-official-mysql-community-server-on-fedora-28\/","url_meta":{"origin":800,"position":1},"title":"How to Install the official MySQL community server on Fedora 28","author":"Chewett","date":"July 25, 2018","format":false,"excerpt":"Today I talk about how you can install the official\u00a0MySQL community server on Fedora 28. Why you cant just use DNF to install mysql-server In the last couple versions of Fedora the default MySQL\u00a0distribution was changed to mariadb. While this is, for the most part, a drop in replacement this\u2026","rel":"","context":"In &quot;Informational&quot;","block_context":{"text":"Informational","link":"https:\/\/chewett.co.uk\/blog\/category\/informational\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/07\/installing_offical_mysql.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/07\/installing_offical_mysql.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/07\/installing_offical_mysql.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/07\/installing_offical_mysql.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":1306,"url":"https:\/\/chewett.co.uk\/blog\/1306\/showing-other-installable-versions-of-packages-on-fedora-28\/","url_meta":{"origin":800,"position":2},"title":"Showing other installable versions of packages on Fedora 28","author":"Chewett","date":"July 7, 2018","format":false,"excerpt":"Today I write about how you can list all installable versions of a package in Fedora. Why you might want to see different versions of a package While the latest version of a package is normally what you want to install there may be times when you want to install\u2026","rel":"","context":"In &quot;Informational&quot;","block_context":{"text":"Informational","link":"https:\/\/chewett.co.uk\/blog\/category\/informational\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/06\/showing_other_package_versions.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/06\/showing_other_package_versions.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/06\/showing_other_package_versions.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2018\/06\/showing_other_package_versions.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":484,"url":"https:\/\/chewett.co.uk\/blog\/484\/virtualbox-guest-additions-fedora\/","url_meta":{"origin":800,"position":3},"title":"Virtualbox Guest additions on Fedora","author":"Chewett","date":"July 26, 2017","format":false,"excerpt":"This post describes how to install virtualbox guest additions on a Fedora virtual machine. Virtualbox guest additions adds a couple of features to running Fedora on virtualbox. Some of the useful features are shared folders, mouse pointer support, shared clipboard and better video driver support. The primary reason I install\u2026","rel":"","context":"In &quot;Informational&quot;","block_context":{"text":"Informational","link":"https:\/\/chewett.co.uk\/blog\/category\/informational\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/fedora_on_virtualbox.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/fedora_on_virtualbox.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/fedora_on_virtualbox.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/fedora_on_virtualbox.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":2135,"url":"https:\/\/chewett.co.uk\/blog\/2135\/installing-the-sdl-2-dev-tools-on-fedora\/","url_meta":{"origin":800,"position":4},"title":"Installing the SDL 2 Dev tools on Fedora","author":"Chewett","date":"April 10, 2019","format":false,"excerpt":"This post quickly lists how you can install the SDL 2 dev tools on Fedora. Installing the SDL 2 Dev tools To develop a SDL 2 application and use the SDL 2 header files to compile C++ applications you will need to install the SDL 2 dev tools. To install\u2026","rel":"","context":"In &quot;Software&quot;","block_context":{"text":"Software","link":"https:\/\/chewett.co.uk\/blog\/category\/software\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2019\/04\/sd2_dev_tools.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2019\/04\/sd2_dev_tools.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2019\/04\/sd2_dev_tools.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2019\/04\/sd2_dev_tools.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":507,"url":"https:\/\/chewett.co.uk\/blog\/507\/fixing-black-screen-nvidia-graphics-card-fedora\/","url_meta":{"origin":800,"position":5},"title":"Fixing black screen with Nvidia graphics card on fedora","author":"Chewett","date":"July 29, 2017","format":false,"excerpt":"On my fedora system I found that after upgrading the kernel\u00a0the graphics drivers wouldnt work. My machine would boot into the operating\u00a0system perfectly fine but would have no image on the screen. This post describes how I fixed this issue. The symptoms of the black screen on Fedora Initially I\u2026","rel":"","context":"In &quot;Fixes&quot;","block_context":{"text":"Fixes","link":"https:\/\/chewett.co.uk\/blog\/category\/fixes\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/black_screen_fedora_nvidia.jpg?fit=800%2C800&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/black_screen_fedora_nvidia.jpg?fit=800%2C800&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/black_screen_fedora_nvidia.jpg?fit=800%2C800&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/chewett.co.uk\/blog\/wp-content\/uploads\/2017\/07\/black_screen_fedora_nvidia.jpg?fit=800%2C800&ssl=1&resize=700%2C400 2x"},"classes":[]}],"_links":{"self":[{"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/posts\/800","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/comments?post=800"}],"version-history":[{"count":2,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/posts\/800\/revisions"}],"predecessor-version":[{"id":808,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/posts\/800\/revisions\/808"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/media\/802"}],"wp:attachment":[{"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/media?parent=800"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/categories?post=800"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/chewett.co.uk\/blog\/wp-json\/wp\/v2\/tags?post=800"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}