---
title: "用yum 安装 gnuplot-py"
author: "stephen80"
date: "2010-07-09T15:35:37Z"
tags: []
categories: ["操作系统"]
slug: "yum-gnuplot-py"
draft: false
lastmod: "2010-07-09T15:52:42Z"
id: 709214
url: "https://stephen80.iteye.com/blog/709214"
---

1. 如果 python 升级了， yum 不能用， 会报 No module named yum .
   把 /usr/bin/yum 脚本第一行 #! /usr/bin/python 改到旧版本
2. 运行 yum search gnuplot 报错
    no access to //var/log/yumcache 
   yum 需要 sudo 运行
3. 如果某个 repo 错误，会引起其他 repo 也不对
4. 拷贝了一个好的 repo , rhel4
   
name=Dag RPM Repository for RHEL4
baseurl=http://ftp.riken.jp/Linux/dag/redhat/el4/en/$basearch/dag/
enabled=1
gpgcheck=1
gpgkey=http://ftp.riken.jp/Linux/dag/packages/RPM-GPG-KEY.dag.txt

5. sudo yum install gnuplot-py
   
找到 python 的安装路径。
python
import sys
pring sys.path