012、CentOS 安装tab命令补全
本文最后更新于 259 天前,其中的信息可能已经过时,如有错误请发送邮件到wuxianglongblog@163.com

CentOS 安装tab命令补全

  1. 安装epel 源

    yum -y install epel-release
  2. 加快yum速度

    yum -y install yum-plugin-fastestmirror
  3. 安装bash-completion

    yum -y install bash-completion
    yum -y install bash-completion-extras 
    # CentOS 7 再多安装一个
  4. 生效

    立即生效
    source /etc/profile.d/bash_completion.sh 
    或者退出终端重新登录

    安装过程

[root@centos7 ~]# rpm -ql bash-completion #j
package bash-completion is not installed
[root@centos7 ~]# 
[root@centos7 ~]# 
[root@centos7 ~]# yum install -y bash-completion
Loaded plugins: fastestmirror
Determining fastest mirrors
epel/x86_64/metalink                                                  | 6.1 kB  00:00:00     

 * base: mirrors.aliyun.com
 * epel: mirror.nyist.edu.cn
 * extras: mirrors.ustc.edu.cn
 * updates: mirrors.aliyun.com
   base                                                                  | 3.6 kB  00:00:00     
   epel                                                                  | 4.7 kB  00:00:00     
   extras                                                                | 2.9 kB  00:00:00     
   mysql-connectors-community                                            | 2.6 kB  00:00:00     
   mysql-tools-community                                                 | 2.6 kB  00:00:00     
   mysql57-community                                                     | 2.6 kB  00:00:00     
   nginx-mainline                                                        | 2.9 kB  00:00:00     
   nginx-stable                                                          | 2.9 kB  00:00:00     
   updates                                                               | 2.9 kB  00:00:00     
   (1/7): extras/7/x86_64/primary_db                                     | 250 kB  00:00:00     
   (2/7): epel/x86_64/updateinfo                                         | 1.0 MB  00:00:01     
   (3/7): epel/x86_64/primary_db                                         | 7.0 MB  00:00:02     
   (4/7): nginx-stable/7/x86_64/primary_db                               |  87 kB  00:00:01     
   (5/7): updates/7/x86_64/primary_db                                    |  25 MB  00:00:02     
   (6/7): nginx-mainline/7/x86_64/primary_db                             | 272 kB  00:00:04     
   epel/x86_64/group_gz           FAILED                                          
   https://mirrors.thzhost.com/epel/7/x86_64/repodata/645d6e0f00f5e7cdebd5d547c1a11506048edf6505cf30c01554e4255b2456ad-comps-Everything.x86_64.xml.gz: [Errno 12] Timeout on https://mirrors.thzhost.com/epel/7/x86_64/repodata/645d6e0f00f5e7cdebd5d547c1a11506048edf6505cf30c01554e4255b2456ad-comps-Everything.x86_64.xml.gz: (28, 'Operation too slow. Less than 1000 bytes/sec transferred the last 30 seconds')
   Trying other mirror.
   (7/7): epel/x86_64/group_gz                                           | 100 kB  00:00:00     
   Resolving Dependencies
   --> Running transaction check
   ---> Package bash-completion.noarch 1:2.1-8.el7 will be installed
   --> Finished Dependency Resolution

Dependencies Resolved

=============================================================================================

 Package                    Arch              Version                  Repository       Size
=============================================================================================

Installing:
 bash-completion            noarch            1:2.1-8.el7              base             87 k

Transaction Summary
=============================================================================================

Install  1 Package

Total download size: 87 k
Installed size: 263 k
Downloading packages:
bash-completion-2.1-8.el7.noarch.rpm                                  |  87 kB  00:00:00     
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : 1:bash-completion-2.1-8.el7.noarch                                        1/1 
  Verifying  : 1:bash-completion-2.1-8.el7.noarch                                        1/1 

Installed:
  bash-completion.noarch 1:2.1-8.el7                                                         

Complete!
[root@centos7 ~]# ls
ls        lsblk     lshw      lsipc     lslogins  lsmod     lspci     
lsattr    lscpu     lsinitrd  lslocks   lsmem     lsns      lsscsi    
[root@centos7 ~]# lv
lvchange     lvdisplay    lvmconf      lvmdump      lvmsadc      lvremove     lvs
lvconvert    lvextend     lvmconfig    lvmetad      lvmsar       lvrename     lvscan
lvcreate     lvm          lvmdiskscan  lvmpolld     lvreduce     lvresize     
[root@centos7 ~]# tc
tc        tcpdump   tcpslice  
[root@centos7 ~]# ss
ss           ssh-add      ssh-copy-id  sshd-keygen  ssh-keyscan  ssltap       
ssh          ssh-agent    sshd         ssh-keygen   sshpass      
[root@centos7 ~]# 
谨此笔记,记录过往。凭君阅览,如能收益,莫大奢望。
暂无评论

发送评论 编辑评论


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇