日期:2014-05-16  浏览次数:20585 次

redhat安装g++ 报错
如下提示:

[root@cs1 /]# yum install gcc gcc-g++
http://ftp.scientificlinux.org/linux/scientific/6.0/x86_64/os/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - ""
Trying other mirror.
http://ftp1.scientificlinux.org/linux/scientific/6.0/x86_64/os/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - ""
Trying other mirror.
http://ftp2.scientificlinux.org/linux/scientific/6.0/x86_64/os/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - ""
Trying other mirror.
ftp://ftp.scientificlinux.org/linux/scientific/6.0/x86_64/os/repodata/repomd.xml: [Errno 14] PYCURL ERROR 6 - ""
Trying other mirror.
Error: Cannot retrieve repository metadata (repomd.xml) for repository: sl. Please verify its path and try again
[root@cs1 /]# 

-----------------------------------
系统环境如下:
[root@cs1 /]# cat /proc/version
Linux version 2.6.32-131.6.1.el6.x86_64 (mockbuild@spacewalk.fnal.gov) (gcc version 4.4.5 20110214 (Red Hat 4.4.5-6) (GCC) ) #1 SMP Tue Jul 12 17:14:50 CDT 2011

咋办啊



------解决方案--------------------
yum clean

------解决方案--------------------
你用浏览器登录ftp://ftp.scientificlinux.org
正常否?

不正常换个镜像吧
------解决方案--------------------
找一份 同版本的 redhat镜像 ,,里面有个 Sever文件夹里面有大多常见的软件想用呢个直接找就行,,比如说g++在里面就有 还是rpm格式的额。。没有也没关系,,下载Centos安装包。。这个和redhat是一样的,,以后用什么直接找就行
------解决方案--------------------
yum 源的问题?
------解决方案--------------------
yum clear all

在试试看

或者是你的源有问题

可以屏蔽掉mirror ,直接使用url的方式,配置文件为 /etc/yum.conf, 具体路径自己查
------解决方案--------------------
redhat6还被官方支持吗?这个镜像还管用吗?为什么用redhat,而不用其他的发行版?
------解决方案--------------------
实在用yum install 不行了, 就下载g++源代码,在GNU官网上有
------解决方案--------------------
使用的是网络yum源,虚拟机没有连接外网
换本地yum源,或者让虚拟机连通外网
------解决方案--------------------
探讨

用的不是虚拟机,
但是在虚拟机上也试了,可以的。

------解决方案--------------------
源有问题,可是试掉删除一些,只保留一个
也可以挂镜像,自己搭建ftp作为源
还可以源码编译,lfs就是这样过来的

------解决方案--------------------
探讨
redhat6还被官方支持吗?这个镜像还管用吗?为什么用redhat,而不用其他的发行版?