{"id":13343,"date":"2019-04-01T21:41:11","date_gmt":"2019-04-01T21:41:11","guid":{"rendered":"http:\/\/www.appservgrid.com\/paw92\/?p=13343"},"modified":"2019-04-01T21:41:11","modified_gmt":"2019-04-01T21:41:11","slug":"how-to-enable-disable-and-install-yum-plug-ins","status":"publish","type":"post","link":"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/04\/01\/how-to-enable-disable-and-install-yum-plug-ins\/","title":{"rendered":"How to Enable, Disable and Install Yum Plug-ins"},"content":{"rendered":"<p><a href=\"https:\/\/www.tecmint.com\/20-linux-yum-yellowdog-updater-modified-commands-for-package-mangement\/\" target=\"_blank\" rel=\"noopener\">YUM<\/a>\u00a0plug-ins are small programs that extend and improve the overall performance of the package manager. A few of them are installed by default, while many are not. Yum always notify you which plug-ins, if any, are loaded and active whenever you run any yum command.<\/p>\n<p>In this short article, we will explain how to turn on or off and configure YUM package manager plug-ins in CentOS\/RHEL distributions.<\/p>\n<p>To see all active plug-ins, run a yum command on the terminal. From the output below, you can see that the\u00a0<strong>fastestmirror<\/strong>\u00a0plug-in is loaded.<\/p>\n<pre><strong># yum search nginx<\/strong>\r\n\r\nLoaded plugins: <strong>fastestmirror<\/strong>\r\nRepodata is over 2 weeks old. Install yum-cron? Or run: yum makecache fast\r\nDetermining fastest mirrors\r\n...\r\n<\/pre>\n<h3>Enabling YUM Plug-ins<\/h3>\n<p>To enable yum plug-ins, ensure that the directive\u00a0<code>plugins=1<\/code>\u00a0(<strong>1<\/strong>\u00a0meaning on) exists under the\u00a0<strong>[main]<\/strong>\u00a0section in the\u00a0<strong>\/etc\/yum.conf<\/strong>\u00a0file, as shown below.<\/p>\n<pre># vi \/etc\/yum.conf\r\n<\/pre>\n<div class=\"code-label\">Yum Configuration File<\/div>\n<pre>[main]\r\ncachedir=\/var\/cache\/yum\/$basearch\/$releasever\r\nkeepcache=0\r\ndebuglevel=2\r\nlogfile=\/var\/log\/yum.log\r\nexactarch=1\r\nobsoletes=1\r\ngpgcheck=1\r\n<code>plugins=1<\/code> installonly_limit=5<\/pre>\n<p>This is a general method of enabling yum plug-ins globally. As we will see later on, you can enable them individually in their receptive configuration files.<\/p>\n<h3>Disabling YUM Plug-ins<\/h3>\n<p>To disable yum plug-ins, simply change the value above to\u00a0<code>0<\/code>\u00a0(meaning off), which disables all plug-ins globally.<\/p>\n<pre><strong>plugins=0<\/strong>\t\r\n<\/pre>\n<p>At this stage, it is useful to note that:<\/p>\n<ul>\n<li>Since a few plug-ins (such as\u00a0<strong>product-id<\/strong>\u00a0and\u00a0<strong>subscription-manager<\/strong>) offer fundamental yum functionalities, it is not recommended to turn off all plug-ins especially globally.<\/li>\n<li>Secondly, disabling plug-ins globally is allowed as an easy way out, and this implies that you can use this provision when investigating a likely problem with yum.<\/li>\n<li>Configurations for various plug-ins are located in\u00a0<strong>\/etc\/yum\/pluginconf.d\/<\/strong>.<\/li>\n<li>Disabling plug-ins globally in\u00a0<strong>\/etc\/yum.conf<\/strong>\u00a0overrides settings in individual configuration files.<\/li>\n<li>And you can also disable a single or all yum plug-ins when running yum, as described later on.<\/li>\n<\/ul>\n<h3>Installing and Configuring Extra YUM Plug-ins<\/h3>\n<p>You can view a list of all yum plug-ins and their descriptions using this command.<\/p>\n<pre><strong># yum search yum-plugin<\/strong>\r\n\r\nLoaded plugins: fastestmirror\r\nRepodata is over 2 weeks old. Install yum-cron? Or run: yum makecache fast\r\nLoading mirror speeds from cached hostfile\r\n * base: mirror.sov.uk.goscomb.net\r\n * epel: www.mirrorservice.org\r\n * extras: mirror.sov.uk.goscomb.net\r\n * updates: mirror.sov.uk.goscomb.net\r\n========================================================================= N\/S matched: yum-plugin ==========================================================================\r\nPackageKit-yum-plugin.x86_64 : Tell PackageKit to check for updates when yum exits\r\nfusioninventory-agent-yum-plugin.noarch : Ask FusionInventory agent to send an inventory when yum exits\r\nkabi-yum-plugins.noarch : The CentOS Linux kernel ABI yum plugin\r\nyum-plugin-aliases.noarch : Yum plugin to enable aliases filters\r\nyum-plugin-auto-update-debug-info.noarch : Yum plugin to enable automatic updates to installed debuginfo packages\r\nyum-plugin-changelog.noarch : Yum plugin for viewing package changelogs before\/after updating\r\nyum-plugin-fastestmirror.noarch : Yum plugin which chooses fastest repository from a mirrorlist\r\nyum-plugin-filter-data.noarch : Yum plugin to list filter based on package data\r\nyum-plugin-fs-snapshot.noarch : Yum plugin to automatically snapshot your filesystems during updates\r\nyum-plugin-keys.noarch : Yum plugin to deal with signing keys\r\nyum-plugin-list-data.noarch : Yum plugin to list aggregate package data\r\nyum-plugin-local.noarch : Yum plugin to automatically manage a local repo. of downloaded packages\r\nyum-plugin-merge-conf.noarch : Yum plugin to merge configuration changes when installing packages\r\nyum-plugin-ovl.noarch : Yum plugin to work around overlayfs issues\r\nyum-plugin-post-transaction-actions.noarch : Yum plugin to run arbitrary commands when certain pkgs are acted on\r\nyum-plugin-priorities.noarch : plugin to give priorities to packages from different repos\r\nyum-plugin-protectbase.noarch : Yum plugin to protect packages from certain repositories.\r\nyum-plugin-ps.noarch : Yum plugin to look at processes, with respect to packages\r\nyum-plugin-remove-with-leaves.noarch : Yum plugin to remove dependencies which are no longer used because of a removal\r\nyum-plugin-rpm-warm-cache.noarch : Yum plugin to access the rpmdb files early to warm up access to the db\r\nyum-plugin-show-leaves.noarch : Yum plugin which shows newly installed leaf packages\r\nyum-plugin-tmprepo.noarch : Yum plugin to add temporary repositories\r\nyum-plugin-tsflags.noarch : Yum plugin to add tsflags by a commandline option\r\nyum-plugin-upgrade-helper.noarch : Yum plugin to help upgrades to the next distribution version\r\nyum-plugin-verify.noarch : Yum plugin to add verify command, and options\r\nyum-plugin-versionlock.noarch : Yum plugin to lock specified packages from being updated\r\n<\/pre>\n<p>To install a plug-in, use the same method for installing a package. For instance we will install the\u00a0<strong>changelog<\/strong>plug-in which is used to display package changelogs before\/after updating.<\/p>\n<pre># yum install yum-plugin-changelog \r\n<\/pre>\n<p>Once you have installed,\u00a0<strong>changelog<\/strong>\u00a0will be enabled by default, to confirm take look into its configuration file.<\/p>\n<pre># vi \/etc\/yum\/pluginconf.d\/changelog.conf\r\n<\/pre>\n<p>Now you can view the\u00a0<strong>changelog<\/strong>\u00a0for a package (<strong>httpd<\/strong>\u00a0in this case) like this.<\/p>\n<pre><strong># yum changelog httpd<\/strong>\r\n\r\nLoaded plugins: changelog, fastestmirror\r\nLoading mirror speeds from cached hostfile\r\n * base: mirrors.linode.com\r\n * epel: mirror.freethought-internet.co.uk\r\n * extras: mirrors.linode.com\r\n * updates: mirrors.linode.com\r\n\r\nListing all changelogs\r\n\r\n==================== Installed Packages ====================\r\nhttpd-2.4.6-45.el7.centos.4.x86_64       installed\r\n* Wed Apr 12 17:30:00 2017 CentOS Sources &lt;bugs@centos.org&gt; - 2.4.6-45.el7.centos.4\r\n- Remove index.html, add centos-noindex.tar.gz\r\n- change vstring\r\n- change symlink for poweredby.png\r\n- update welcome.conf with proper aliases\r\n...\r\n<\/pre>\n<h3>Disable YUM Plug-ins in Command Line<\/h3>\n<p>As stated before, we can also turn off one or more plug-ins while running a yum command by using these two important options.<\/p>\n<ul>\n<li><code>--noplugins<\/code>\u00a0\u2013 turns off all plug-ins<\/li>\n<li><code>--disableplugin=plugin_name<\/code>\u00a0\u2013 disables a single plug-ins<\/li>\n<\/ul>\n<p>You can disable all plug-ins as in this yum command.<\/p>\n<pre># yum search --noplugins yum-plugin\r\n<\/pre>\n<p>The next command disables the plug-in,\u00a0<strong>fastestmirror<\/strong>\u00a0while installing\u00a0<strong>httpd<\/strong>\u00a0package.<\/p>\n<pre><strong># yum install --disableplugin=fastestmirror httpd<\/strong>\r\n\r\nLoaded plugins: changelog\r\nResolving Dependencies\r\n--&gt; Running transaction check\r\n---&gt; Package httpd.x86_64 0:2.4.6-45.el7.centos.4 will be updated\r\n--&gt; Processing Dependency: httpd = 2.4.6-45.el7.centos.4 for package: 1:mod_ssl-2.4.6-45.el7.centos.4.x86_64\r\n---&gt; Package httpd.x86_64 0:2.4.6-67.el7.centos.6 will be an update\r\n...\r\n<\/pre>\n<p>That\u2019s it for now! you may also like to read these following YUM related articles.<\/p>\n<ol>\n<li><a href=\"https:\/\/www.tecmint.com\/view-yum-history-to-find-packages-info\/\" target=\"_blank\" rel=\"noopener\">How to Use \u2018Yum History\u2019 to Find Out Installed or Removed Packages Info<\/a><\/li>\n<li><a href=\"https:\/\/www.tecmint.com\/fix-yum-error-database-disk-image-is-malformed\/\" target=\"_blank\" rel=\"noopener\">How to Fix Yum Error: Database Disk Image is Malformed<\/a><\/li>\n<\/ol>\n<p>In this guide, we showed how to activate, configure or deactivate YUM package manager plug-ins in CentOS\/RHEL 7. Use the comment form below to ask any question or share your views about this article.<\/p>\n<p><a href=\"https:\/\/www.tecmint.com\/enable-disable-and-install-yum-plug-ins\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>YUM\u00a0plug-ins are small programs that extend and improve the overall performance of the package manager. A few of them are installed by default, while many are not. Yum always notify you which plug-ins, if any, are loaded and active whenever you run any yum command. In this short article, we will explain how to turn &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.appservgrid.com\/paw92\/index.php\/2019\/04\/01\/how-to-enable-disable-and-install-yum-plug-ins\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;How to Enable, Disable and Install Yum Plug-ins&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-13343","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13343","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/comments?post=13343"}],"version-history":[{"count":1,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13343\/revisions"}],"predecessor-version":[{"id":13344,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/posts\/13343\/revisions\/13344"}],"wp:attachment":[{"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/media?parent=13343"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/categories?post=13343"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.appservgrid.com\/paw92\/index.php\/wp-json\/wp\/v2\/tags?post=13343"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}