0

I am trying to install gcc compiler using the command:

yum install gcc

but I am getting the error as:

Loaded plugins: product-id, security, subscription-manager
Updating certificate-based repositories.
Setting up Install Process
No package gcc available.
Error: Nothing to do

How can I solve this? My original question from StackOverflow.

  • 2
    Which flavor & version of Linux are you running? – heavyd Aug 18 '15 at 14:16
  • Red Hat Enterprise Linux Server release 6.2 (Santiago) @heavyd – user3407271 Aug 18 '15 at 14:32
  • You may be experiencing a similar problem to this user: unix.stackexchange.com/questions/25562/… – MC10 Aug 18 '15 at 14:34
  • @MC10 thanks for your help. my vm is not registered in rhn.hence the issue. – user3407271 Aug 18 '15 at 17:10
1

RHEL / CentOS

yum install gcc should work. Try sudo yum install gcc.

If yum groupinstall "Development Tools" does not work, add sudo in front of it as well.

Check your repositories: yum repolist all

  • i ran the command and got the error as : Loaded plugins: product-id, security, subscription-manager Updating certificate-based repositories. Setting up Group Process Warning: Group Development Tools does not exist. No packages in any requested group available to install or update @MC10 please help – user3407271 Aug 18 '15 at 14:36
  • Check your repositories. Are you subscribed to a specific channel? – MC10 Aug 18 '15 at 14:41
  • @user3407271 What do you see if you run yum repolist all? Are your repositories enabled? – MC10 Aug 18 '15 at 15:19
  • the repositories status is showing disabled.so maybe i won't be able to download gcc i guess. – user3407271 Aug 18 '15 at 17:12
0

That's because it isn't finding a package named solely gcc. That is too broad. Do a yum search gcc to see all of the gcc packages, and the full package name. Then you'll be able to install the correct one. It'll probably be something like yum install gcc 4.x And as others said, don't forget to be in root or do `sudo. I've had this same thing happen to me a few times.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.