1:打开终端输入如下命令:
sudo gedit /etc/bash.bashrc
2:将下面代码注释取消
# enable bash completion in interactive shells
#if ! shopt -oq posix; then
# if [ -f /usr/share/bash-completion/bash_completion ]; then
# . /usr/share/bash-completion/bash_completion
# elif [ -f /etc/bash_completion ]; then
# . /etc/bash_completion
# fi
#fi
3:重启ubuntu
sudo reboot