[root@localhost ~]# yum install g++
Loaded plugins: rhnplugin, security
This system is not registered with RHN.
RHN support will be disabled.
Setting up Install Process
No package g++ available.
Nothing to do
[root@localhost ~]# yum install g++
/usr/lib/python2.4/site-packages/yum/sqlitesack.py:26: DeprecationWarning: Non-ASCII character '\xc2' in file /usr/lib/python2.4/site-packages/yum/yumRepo.py on line 799, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details
import yumRepo
Traceback (most recent call last):
File "/usr/bin/yum", line 4, in ?
import yum
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 54, in ?
import transactioninfo
File "/usr/lib/python2.4/site-packages/yum/transactioninfo.py", line 31, in ?
from sqlitesack import YumAvailablePackageSqlite
File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 26, in ?
import yumRepo
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 799
remote = ¨/mnt/cdrom/Server¨ + '/' + relative
^
SyntaxError: invalid syntax
csg551342 于 2012-06-16 13:28:00发表:
[i=s] 本帖最后由 csg551342 于 2012-6-16 13:30 编辑 [/i]
没有注册到RHN ,是无法直接YUM。
可自己搭建下本地YUM源安装软件。
可参考以下方法:(Red Hat Enterprise Linux 5版本)
1、 将DVD光盘挂载到/media/cdrom中;
2、 编辑源配置文件/etc/yum.repos.d/rhel-debuginfo.repo :
[Cluster]
name=Red Hat Enterprise Linux $releasever - $basearch - Cluster
baseurl=file:///media/cdrom/Cluster
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[ClusterStorage]
name=Red Hat Enterprise Linux $releasever - $basearch - ClusterStorage
baseurl=file:///media/cdrom/ClusterStorage
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[Server]
name=Red Hat Enterprise Linux $releasever - $basearch - Server
baseurl=file:///media/cdrom/Server
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[VT]
name=Red Hat Enterprise Linux $releasever - $basearch - VT
baseurl=file:///media/cdrom/VT
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
村里DE小伙 于 2012-06-18 10:49:50发表:
[root@localhost audacious-2.4.0]# ./configure ./configure 报的错。
checking build system type... Invalid configuration `i686-pc-linux-': machine `i686-pc-linux' not recognized
configure: error: /bin/sh ./config.sub i686-pc-linux- failed
村里DE小伙 于 2012-06-18 10:45:00发表:
改过之后好象出现要定义编码
[root@localhost ~]# yum install g++
/usr/lib/python2.4/site-packages/yum/sqlitesack.py:26: DeprecationWarning: Non-ASCII character '\xc2' in file /usr/lib/python2.4/site-packages/yum/yumRepo.py on line 799, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details
import yumRepo
Traceback (most recent call last):
File "/usr/bin/yum", line 4, in ?
import yum
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 54, in ?
import transactioninfo
File "/usr/lib/python2.4/site-packages/yum/transactioninfo.py", line 31, in ?
from sqlitesack import YumAvailablePackageSqlite
File "/usr/lib/python2.4/site-packages/yum/sqlitesack.py", line 26, in ?
import yumRepo
File "/usr/lib/python2.4/site-packages/yum/yumRepo.py", line 799
remote = ¨/mnt/cdrom/Server¨ + '/' + relative
^
SyntaxError: invalid syntax
csg551342 于 2012-06-16 13:28:00发表:
[i=s] 本帖最后由 csg551342 于 2012-6-16 13:30 编辑 [/i]
没有注册到RHN ,是无法直接YUM。
可自己搭建下本地YUM源安装软件。
可参考以下方法:(Red Hat Enterprise Linux 5版本)
1、 将DVD光盘挂载到/media/cdrom中;
2、 编辑源配置文件/etc/yum.repos.d/rhel-debuginfo.repo :
[Cluster]
name=Red Hat Enterprise Linux $releasever - $basearch - Cluster
baseurl=file:///media/cdrom/Cluster
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[ClusterStorage]
name=Red Hat Enterprise Linux $releasever - $basearch - ClusterStorage
baseurl=file:///media/cdrom/ClusterStorage
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[Server]
name=Red Hat Enterprise Linux $releasever - $basearch - Server
baseurl=file:///media/cdrom/Server
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
[VT]
name=Red Hat Enterprise Linux $releasever - $basearch - VT
baseurl=file:///media/cdrom/VT
enabled=1
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
3、/usr/lib/python2.4/site-packages/yum/yumRepo.py第411行:
remote = url + '/' + relative
改为:
remote = “/media/cdrom/Server” + '/' + relative
4.再使用yum安装需要的软件即可。
HONWEA 于 2012-06-15 21:23:30发表:
This system is not registered with RHN. 木有注册不给yum !
HONWEA 于 2012-06-15 21:22:40发表:
上面不是写了吗!
村里DE小伙 于 2012-06-15 14:35:17发表:
:0w223dc不是吧,没人理我?
村里DE小伙 于 2012-06-15 14:13:46发表:
因为我是在安装tgz包时。/configure 出的问题。