无法在 Oracle Linux (RedHat) 上安装 Apache



我刚刚安装了Oracle Linux(我知道这是RedHat的某种颠覆),正如标题所说,当我尝试设置Apache时,我遇到了麻烦。

当我输入以下命令(以 root 身份登录)时:

yum install httpd

我得到这个回复:

Loading "Installonlyn" plugin
Setting up Install Process
Setting up repositories
No Repositories Available to Set Up
Reading repository metadata in from local files
Parsing package install arguments
Setting up repositories
No Repositories Available to Set Up
Reading repository metadata in from local files
No Match for argument: httpd
Nothing to do

更新:yum repolist 命令的输出:

[root@localhost suurp6der]# yum repolist
Loading "installonlyn" plugin
usage: yum [options] < grouplist, localinstall, groupinfo, localupdate, resolvedep, erase, deplist, groupremove, makecache, upgrade, provides, shell, install, whatprovides, groupinstall, update, groupupdate, info, search, check-update, list, remove, clean, grouperase >
options:
  -h, --help            show this help message and exit
  -t, --tolerant        be tolerant of errors
  -C                    run entirely from cache, don't update cache
  -c  [config file]     config file location
  -R  [minutes]         maximum command wait time
  -d  [debug level]     debugging output level
  -e  [error level]     error output level
  -y                    answer yes for all questions
  --version             show Yum version and exit
  --installroot=[path]  set install root
  --enablerepo=[repo]   enable one or more repositories (wildcards allowed)
  --disablerepo=[repo]  disable one or more repositories (wildcards allowed)
  -x [package], --exclude=[package]
                        exclude package(s) by name or glob
  --obsoletes           enable obsoletes processing during updates
  --noplugins           disable Yum plugins

我该如何解决这个问题?

谢谢。

因为这里清楚地提到"没有可供设置的存储库"首先在本地设置并删除存储库并在下面执行:

yum list | grep httpd

然后你得到 httpd-*

并安装 :

yum install httpd

最新更新