yum指令之修复
折腾着搞 openvpn 网站服务器 yum指令 出了点问题
------------------------------------------------------------
[root@cloud ~]# yum
There was a problem importing one of the Python modules
required to run yum. The error leading to this problem was:
No module named yum
Please install a package which provides this module, or
verify that the module is installed correctly.
It's possible that the above module doesn't match the
current version of Python, which is:
2.6.6 (r266:84292, Feb 22 2013, 00:00:18)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-3)]
-----------------------------------------------------------
原因:
根据报错信息提示,yum 会用到 Python 的某些模块。当前模块安装错误 或者 Python 版本错误
当前错误是 Python 版本错误
解决:
1. 查看yum版本 rpm -qa |grep yum
查看python版本 whereis python
发现 python果然安装了两个版本2.6和2.7版本
2. 编辑 yum 使用的 python 版本
vi /usr/bin/yum
把#!/usr/bin/python改为#!/usr/bin/python2.6
最新文章
- Start Instance 操作详解 - 每天5分钟玩转 OpenStack(31)
- wps使用技巧
- [BS-15] Values of type 'NSInteger' should not be used as format arguments
- Sublime Text 3 乱码解决
- 关于Eclipse的编码配置和字体大小设置
- 2761: [JLOI2011]不重复数字(哈希表)
- Learning to Rank简介
- 禁止img图片拖动在新窗口打开
- time-based基于google key生成6位验证码(google authenticator)
- 浅析AngularJS自定义指令之嵌入(transclude)
- jQuery中【width(),innerWidth(),outerWidth()】
- MySQL5.7.19 服务挂掉 自动关闭 mysqld got exception 0xc000001d win 2008R2
- codevs1839洞穴勘测
- [转载][转]修改/proc目录下的参数优化网络性能
- iOS:面向对象的思想使用sqlite数据库
- iOS开发25个性能调优技巧
- C#中的Linq使用
- oracle中根据时间获取最新的一条数据
- 如何高性能的给 UIImageView 加个圆角?
- 第二章 你第首个Electron应用 | Electron in Action(中译)
热门文章
- Ubuntu下安装deb包命令
- P2463 [SDOI2008]Sandy的卡片[差分+串拼接后缀数组]
- 【C++】*p++ = *p不同环境下操作不同
- python反复执行某个命令
- Ubuntu 复制文件,修改文件名
- Spring框架中的@Import、@ImportResource注解
- 最小化安装linux CentOS-6.6后 部署fastdfs +下载地址 很干很干的干货
- java——构造方法重载
- CF-851B
- SpringBoot使用拦截器无效