|
我的linux版本是RHEL 6.0,想用iso镜像制作本地yum源,用google找到了方法。我按照网页http://www.cnblogs.com/chinacloud/archive/2011/03/18/1988257.html上介绍的步骤一步一步操作,前五步都顺利完成了,可到第6步测试时出现了问题,错误如下所示:
----------------------------------------------------------------------------------------------
[root@localhost repo]# vi /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# system-config-packages
bash: system-config-packages: command not found
[root@localhost repo]# source /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# system-config-packages
bash: system-config-packages: command not found
[root@localhost repo]# yum info lrzsz
Loaded plugins: refresh-packagekit, rhnplugin
Config Error: File contains no section headers.
file: file://///etc/yum.repos.d/rhel6.repo, line: 2
'name=rhel6server\n'
[root@localhost repo]# vi /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# source /etc/yum.repos.d/rhel6.repo
bash: [Server]: command not found
[root@localhost repo]# vi /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# source /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# yum info lrzsz
Loaded plugins: refresh-packagekit, rhnplugin
Config Error: File contains no section headers.
file: file://///etc/yum.repos.d/rhel6.repo, line: 2
'name=rhel6server\n'
[root@localhost repo]# yum install lrzsz
Loaded plugins: refresh-packagekit, rhnplugin
Config Error: File contains no section headers.
file: file://///etc/yum.repos.d/rhel6.repo, line: 2
'name=rhel6server\n'
[root@localhost repo]# vim /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# source /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# yum install lrzsz
Loaded plugins: refresh-packagekit, rhnplugin
Config Error: File contains no section headers.
file: file://///etc/yum.repos.d/rhel6.repo, line: 3
'name=rhel6\n'
[root@localhost repo]# vim /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# source /etc/yum.repos.d/rhel6.repo
[root@localhost repo]# yum install lrzsz
Loaded plugins: refresh-packagekit, rhnplugin
Config Error: File contains no section headers.
file: file://///etc/yum.repos.d/rhel6.repo, line: 3
'name=Rhel6\n'
--------------------------------------------------------------------------------------------
从系统提示来看,主要是编辑repo文件时name那行似乎不能这么写,可是怎么写才是对的呢?请高手不吝赐教!非常感谢!!
我把网页用pdf保存了,请见附件。 |
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?注册
×
|