How can intelligent BASH auto-completion be enabled in RHEL6?

Solution Verified - Updated -


  • Red Hat Enterprise Linux 6


  • Fedora and many other Linux distros have enhanced BASH tab-completion, i.e., instead of just the traditional filename-completion, there is intelligent auto-completion of options & arguments for many commands (e.g., yum install ge<TABTAB> will give results of all the available packages whose names start with "ge"). How to enable this in RHEL6?


  • Currently, the simplest way to enable this is to install the unsupported bash-completion rpm from the 3rd-party EPEL repository.

  • For more details on BASH's Programmable Completion capabilities, see man bash, info bash, or google.

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.