首先安装epel,然后再安装yum加速
#centos7下执行以下命令
wget http://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
yum install -y epel-release-latest-.noarch.rpm
#centos6下执行以下命令
wget http://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm
rpm -ivh epel-release-latest-.noarch.rpm 也可以执行以下命令
yum install python-pip python-devel -y
yum install -y epel-release
#在完成epel的安装后一行以下命令
yum clean all
yum makecache
yum install -y yum-fastestmirror
yum whatprovides */lspci /* | head #查找lspci是通过哪个安装包来提供的
输出结果:pciutils-3.1.10-4.el6.x86_64 : PCI bus related utilities
yum install -y dstat blktrace fio tcpdump ltrace lsof iptraf-ng lshw cpuid numactl mdadm lsscsi sysbench mtr nload vnstat collectl iftop trafshow nethogs dmidecode man strace perf iotop atop hping3 systemtap nmon htop iperf bwm-ng glances net-tools sysstat mlocate
yum install -y usbutils pciutils util-linux-ng smartmontools httpd-tools
yum install -y pciutils #安装lspci
yum install -y usbutils #安装lsusb
yum install -y util-linux-ng #安装ionice,chcpu,renice,blockdev等
yum install -y smartmontools #smartctl
yum install -y httpd-tools #ab
仅下载包,不安装
yum install -y yum-plugin-downloadonly
yum install glusterfs-client --downloadonly --downloaddir=/tmp/ CentOS7下安装pip
yum -y install epel-release
yum -y install python-pip
yum clean all
pip install --upgrade pip
pip --version
看到输出结果就知道pip安装完成了。