Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How can I exclude selected packages when I rum yum update command under FEDORA?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf

How can I exclude selected packages when I rum yum update command under FEDORAFEDORA <= 21?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf

How can I exclude selected packages when I rum yum update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), it can include characters such as *,

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

How can I exclude selected packages when I rum yum update command under FEDORA <= 21?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf

How can I exclude selected packages when I rum yum dnf update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), it can include characters such as *,

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

How can I exclude selected packages when I rum yum update command under FEDORA <= 21?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf

How can I exclude selected packages when I rum dnf update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), it can include characters such as *,specified by a name or a glob and separated by a comma

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

Changes in DNF 2

excludepkgs

Exclude packages of this repository, specified by a name or a glob and separated by a comma, from all operations. Can be disabled using --disableexcludes command line switch.

Source -> conf_ref

How can I exclude selected packages when I rum dnf update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), specified by a name or a glob and separated by a comma

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

Changes in DNF 2

excludepkgs

Exclude packages of this repository, specified by a name or a glob and separated by a comma, from all operations. Can be disabled using --disableexcludes command line switch.

Source -> conf_ref

How can I exclude selected packages when I rum yum update command under FEDORA <= 21?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf

How can I exclude selected packages when I rum dnf update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), specified by a name or a glob and separated by a comma

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

Changes in DNF 2

excludepkgs

Exclude packages of this repository, specified by a name or a glob and separated by a comma, from all operations. Can be disabled using --disableexcludes command line switch.

Source -> conf_ref

How can I exclude selected packages when I rum dnf update command under FEDORA >= 22?

With the Command Line

Until a fix is available you can block the offending package from updating by adding an option to the command, replace packagename with the name of the package(s), specified by a name or a glob and separated by a comma

sudo dnf upgrade --exclude=packagename

In Configuration Files

It is also possible to add the exclude option to the configuration file. If you use a gui update application this is the best option. You will need root permission to edit this file so use su - or prefix the command with sudo. Add exclude=packagename to /etc/dnf/dnf.conf.

Changes in DNF 2

excludepkgs

Exclude packages of this repository, specified by a name or a glob and separated by a comma, from all operations. Can be disabled using --disableexcludes command line switch.

Source -> conf_ref

How can I exclude selected packages when I rum yum update command under FEDORA <= 21?

Yum uses a configuration file at /etc/yum.conf. You need to place exclude directive to define list of packages to exclude from updates or installs. This should be a space separated list. Shell globs using wildcards * and ?) are allowed.

How do I exclude packaed1 and packed2 when I use "yum update"?

Open /etc/yum.conf file, enter:

nano /etc/yum.conf

Append the following line under [main] section, enter:

exclude=packed1* packed2*

At the end, it should look like as follows:

[main]
cachedir=/var/cache/yum/$basearch/$releasever
keepcache=0
debuglevel=2
logfile=/var/log/yum.log
exactarch=1
obsoletes=1
gpgcheck=1
plugins=1
installonly_limit=3

#  This is the default, if you make this bigger yum won't see if the metadata
# is newer on the remote and so you'll "gain" the bandwidth of not having to
# download the new metadata and "pay" for it by yum not having correct
# information.
#  It is esp. important, to have correct metadata, for distributions like
# Fedora which don't keep old packages around. If you don't like this checking
# interupting your command line usage, it's much better to have something
# manually check the metadata once an hour (yum-updatesd will do this).

# PUT YOUR REPOS HERE OR IN separate files named file.repo
# in /etc/yum.repos.d
exclude=packed1* packed2*

Save and close the file. You can now use the yum command as usual but certain package will not install.

How Do I Disable Excludes?

You can use the following syntax:

yum --disableexcludes=all update
yum --disableexcludes=main install packed1
yum --disableexcludes=repoid install packed1 packed2

Where,

all : Disable all excludes
main : Disable excludes defined in [main] in yum.conf
repoid : Disable excludes defined for given repo id

yum --exclude Command Line Option

Finally, you can skip yum command updates on command line itself using following syntax:

yum --exclude=package\* update
yum --exclude=packed1\* update
yum --exclude=packed2\* update
yum -x 'packed1*' -x 'packed2*' update

Note: The above syntax will exclude a specific package by name or glob from updates on all repositories.

Recommend readings:

For more information view the manual page on yum command using the following command:

$ man yum
$ man yum.conf