简体   繁体   English

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

[英]Unable to install Apache on Oracle Linux (RedHat)

I just installed the Oracle Linux (which I understand is some kind of a subversion of RedHat) and as the title says, I have troubles when I try to set up the Apache. 我刚刚安装了Oracle Linux(据了解,它是RedHat的一种变体),正如标题所述,尝试安装Apache时遇到了麻烦。

When I type this command (logged in as root): 当我键入以下命令(以root用户身份登录)时:

yum install httpd

I get this response: 我得到这个回应:

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

UPDATE: Output for the yum repolist command: 更新: 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

How could I fix this problem? 我该如何解决这个问题?

Thank you. 谢谢。

Because here mention clearly "No Repositories Available to Set Up" First setup local and remove repository and execute below comman : 因为这里明确提到“没有可用的存储库”,所以首先在本地安装并删除存储库,然后在comman下面执行:

yum list | grep httpd

Then you get httpd-* 然后你得到httpd- *

and install : 并安装:

yum install httpd

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM