Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to get tab-completion working in Yum in CentOS 6 (so I can do something like yum install firefo<TAB> and get back firefox), and I have found many tutorials which say to simply do yum install bash-completion, but when I do this, I get this back:

Loaded plugins: fastestmirror, refresh-packagekit
Loading mirror speeds from cached hostfile
 * base: mirror.anl.gov
 * extras: yum.singlehop.com
 * updates: mirror.ubiquityservers.com
Setting up Install Process
No package bash-completion available.
Error: Nothing to do

I am new to CentOS/Yum so I am lost- is there some repository I should add?

share|improve this question
up vote 12 down vote accepted

CentOS needs to have EPEL Yum repository enabled in order to install bash-completion package.

See https://fedoraproject.org/wiki/EPEL for details.

share|improve this answer
  1. Download the bash-completion RPM

    wget http://www.caliban.org/files/redhat/RPMS/noarch/bash-completion-20060301-1.noarch.rpm

  2. Install the RPM

    rpm -ivh bash-completion-20060301-1.noarch.rpm

  3. Execute the command

    . /etc/bash_completion

  4. Now you can try the autocompletion

    yum ins — [TAB][TAB]

Edit: for Centos 6, you can grab this RPM

share|improve this answer

There is only one command you have to get bash-completion:

yum install epel-release.noarch bash-completion.noarch
share|improve this answer
thanks! this is all I needed – cwd Sep 16 '15 at 2:30
Concisely perfect! – 1111161171159459134 Jul 12 at 14:36

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.