can't install using yum in RHEL 7.1

拟墨画扇 提交于 2019-12-08 07:26:00

问题


I got a RHEL 7.1 instance on amazon aws, now i am trying to install softwares using yum, but even very common softwares aren't available.

For example,

$ sudo yum install lynx

Loaded plugins: amazon-id, rhui-lb
No package lynx available.
Error: Nothing to do

I am new to linux and yum. What's to be done so I can install softwares easily using yum.

Should I be adding repos?

Here, I tried doing what's said here -> Top 5 Yum Repositories for CentOS/RHEL 7/6/5 and Fedora, and here -> Install RepoForge (RPMForge) Repository On RHEL, CentOS, Scientific Linux 7/6.x/5.x/4.x but to no use.

Appreciate any help.


回答1:


You first need to search whether the repo is present by using " yum search lynx"

Loaded plugins: amazon-id, rhui-lb ================================ Matched: lynx ================================================================= pinfo.x86_64 : An info file viewer

For example
"yum search httpd" shows

  1. httpd.x86_64 : Apache HTTP Server httpd-devel.x86_64 : Development interfaces for the Apache HTTP server httpd-manual.noarch : Documentation for the Apache HTTP server.
  2. httpd-tools.x86_64 : Tools for use with the Apache HTTP Server
  3. List item libmicrohttpd.i686 : Lightweight library for embedding a webserver in applications
  4. libmicrohttpd.x86_64 : Lightweight library for embedding a webserver in applications
  5. mod_auth_mellon.x86_64 : A SAML 2.0 authentication module for the Apache Httpd Server mod_dav_svn.x86_64 : Apache httpd module for Subversion server

then check the output it gives you. By taking the output data we need to install any softwares using yum.

Now use

  1. List item

    yum install "package name"




回答2:


Lynx is in optional repo. Check enabled repos with:

yum repolist all

Enable optional (using Oracle Linux as example):

sudo yum install yum-utils
sudo yum-config-manager --enable ol7_optional_latest

Lynx should be installed now without problems:

sudo yum install lynx


来源:https://stackoverflow.com/questions/30097627/cant-install-using-yum-in-rhel-7-1

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!