CentOS最小化安装后没有wget的解决办法

准备学Python了,今天虚拟机装了个Centos,以前都是自己选包的,因为只用到Python,就选了个mini安装,好吧,结果各种坑啊。

准备更换下yum源然后更新下python到2.7,Centos6.4自带的是2.6.6,竟然没有wget,好吧,那就yum install wget,竟然提示没有可用的源。

什么鬼?更新一下先,

#yum update

#yum -y install wget

还是不行,看来是yum源里就没有wget,不科学嘛!手动换源!个人比较习惯用阿里云的yum源,下载后,winscp上传至/etc/yum.repos.d/,注意备份下原文件(这只是个好习惯而已,原来难的源连wget都没,真心没啥好保留的),重新执行!

#yum  clean  all 
#yum -y install  wget

OK,大功告成!

顺手再更新下,# yum update && yum upgrade,

Complete!
已加载插件:fastestmirror
设置升级进程
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
Loading mirror speeds from cached hostfile
 * base: mirrors.aliyun.com
 * extras: mirrors.aliyun.com
 * updates: mirrors.aliyun.com

可以看到yum源已经更换成阿里云的了。

python的升级过程就不写了,百度大把,提醒下自己和各位,生产环境下的Centos安装,最好是自己选包,适合自己的才是最好的!