Results 1 to 9 of 9

Thread: Can't install ruby via yum

  1. #1
    Join Date
    Jan 2009
    Posts
    4

    Default Can't install ruby via yum

    I am new to vpslink and I trying out a Link-1 account using FC10. I have successfully installed a number of packages I want to play with via yum, but a few packages I want don't seem to be available in the yum repository -- mostly importantly ruby.

    "yum install ruby" tells me "No package ruby available". I don't see how this can be right - I looked up the list of packages available for FC10 on the web and clearly see that there is a ruby package, but when I run "yum list available | grep ruby" I see lots of ruby packages, but not the main one.

    Is the ruby package specifically filtered out for Link-1 accounts, or am I missing something here? How else should I go about getting ruby installed on my vps account?

    Thanks
    -scottwb

  2. #2
    Join Date
    Jul 2007
    Location
    127.0.0.1
    Posts
    392

    Default

    Quote Originally Posted by scottwb View Post
    "yum install ruby" tells me "No package ruby available". I don't see how this can be right - I looked up the list of packages available for FC10 on the web and clearly see that there is a ruby package, but when I run "yum list available | grep ruby" I see lots of ruby packages, but not the main one.

    Is the ruby package specifically filtered out for Link-1 accounts, or am I missing something here? How else should I go about getting ruby installed on my vps account?

    Thanks
    -scottwb
    Hey Scott,

    Welcome to VPS Link. I doubt the ruby packages are filtered out specifically for Link-1 accounts. Personally, I'm a Debian fanboy, but the job requires us to run Red-Hat based distros, so perhaps I can provide some assistance. Yum is terrible at package management and has frustrated me to no end..

    Anyway, can you run the following commands and append the output to a reply?

    Code:
    cat /etc/yum.conf
    Code:
    ls -lah /etc/yum.repos.d
    then, cat the contents of the files in /etc/yum.repos.d.

    In my case, it would be:
    Code:
    cat /etc/yum.repos.d/CentOS-Base.repo
    [... some output ...]
    Code:
    cat /etc/yum.repos.d/livna.repo
    [... some output ...]

    These files are very picky, and I'm not sure how they're setup/configured in VPS Link's templates.

    If you're not opposed to the idea, I *highly* recommend switching to Debian. Everyone that I've ever converted has thanked me later

  3. #3
    Join Date
    Jan 2009
    Posts
    4

    Default Re: Can't install ruby via yum

    Thanks for replying Guy. I'll take your Debian suggestion under advisement...I have been using Fedora/RedHat for a long long time, and it's really the only Linux distro I've used for real work, so of course I am a bit hesitant to switch just yet, but I am open to being convinced...

    I have dedicated hardware that I've been running FC5-9 on with no yum problems. I haven't done anything all that complicated with yum, but I don't really consider "yum install ruby" to be all that complex. I guess maybe I should try installing my own FC10 installation from DVD an a local machine and comparing the yum configs.

    Anyway, here's the output you requested. Thanks for the help on this.

    Code:
    [root@64978 ~]# cat /etc/yum.conf
    [main]
    cachedir=/var/cache/yum
    keepcache=0
    debuglevel=2
    logfile=/var/log/yum.log
    exactarch=1
    obsoletes=1
    gpgcheck=1
    plugins=1
    installonly_limit=3
    
    #  This is the default, if you make this bigger yum won't see if the metadata
    # is newer on the remote and so you'll "gain" the bandwidth of not having to
    # download the new metadata and "pay" for it by yum not having correct
    # information.
    #  It is esp. important, to have correct metadata, for distributions like
    # Fedora which don't keep old packages around. If you don't like this checking
    # interupting your command line usage, it's much better to have something
    # manually check the metadata once an hour (yum-updatesd will do this).
    # metadata_expire=90m
    
    # PUT YOUR REPOS HERE OR IN separate files named file.repo
    # in /etc/yum.repos.d
    Code:
    [root@64978 ~]# ls -lah /etc/yum.repos.d
    total 24K
    drwxr-xr-x  2 root root 4.0K 2008-11-25 19:06 .
    drwxr-xr-x 70 root root 4.0K 2009-01-18 22:24 ..
    -rw-r--r--  1 root root 1.9K 2008-11-25 19:06 fedora-rawhide.repo
    -rw-r--r--  1 root root  959 2008-11-25 19:06 fedora.repo
    -rw-r--r--  1 root root  977 2008-11-25 19:06 fedora-updates.repo
    -rw-r--r--  1 root root 1.1K 2008-11-25 19:06 fedora-updates-testing.repo
    [root@64978 ~]#
    The forum software won't let me post the contents of the *.repo files because it says I am not allowed to post URLs until I have made 15 posts, so I had to replace "://" with "___":

    Code:
    [root@64978 ~]# cat /etc/yum.repos.d/*.repo | sed 's/:\/\//___/g'
    # These packages are untested and still under development. This
    # repository is used for development of new releases.
    #
    # This repository can see significant daily turnover and major
    # functionality changes which cause unexpected problems with other
    # development packages. Please use these packages if you want to work
    # with the Fedora developers by testing these new development packages.
    #
    # fedora-test-list@redhat.com is available as a discussion forum for
    # testing and troubleshooting for development packages in conjunction
    # with new test releases.
    #
    # More information is available at http___fedoraproject.org/wiki/Testing 
    #
    # Reproducible and reportable issues should be filed at
    # http___bugzilla.redhat.com/.
    #
    # Product: Fedora
    # Version: rawhide
    
    [rawhide]
    name=Fedora - Rawhide - Developmental packages for the next Fedora release
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/development/i386/os/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=rawhide&arch=i386
    enabled=0
    gpgcheck=0
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386 file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$basearch
    
    [rawhide-debuginfo]
    name=Fedora - Rawhide - Debug
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/development/i386/debug/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=rawhide-debug&arch=i386
    enabled=0
    gpgcheck=0
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386 file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$basearch
    
    [rawhide-source]
    name=Fedora - Rawhide - Source
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/development/source/SRPMS/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=rawhide-source&arch=i386
    enabled=0
    gpgcheck=0
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386 file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$basearch
    
    [fedora]
    name=Fedora 10 - i386
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/releases/10/Everything/i386/os/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=fedora-10&arch=i386
    enabled=1
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    
    [fedora-debuginfo]
    name=Fedora 10 - i386 - Debug
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/releases/10/Everything/i386/debug/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=fedora-debug-10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    
    [fedora-source]
    name=Fedora 10 - Source
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/releases/10/Everything/source/SRPMS/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=fedora-source-10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    [updates]
    name=Fedora 10 - i386 - Updates
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/10/i386/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f10&arch=i386
    enabled=1
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    
    [updates-debuginfo]
    name=Fedora 10 - i386 - Updates - Debug
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/10/i386/debug/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-released-debug-f10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    
    [updates-source]
    name=Fedora 10 - Updates Source
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/10/SRPMS/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-released-source-f10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-i386
    [updates-testing]
    name=Fedora 10 - i386 - Test Updates
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/testing/10/i386/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-testing-f10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386
    
    [updates-testing-debuginfo]
    name=Fedora 10 - i386 - Test Updates Debug
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/testing/10/i386/debug/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-testing-debug-f10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386
    
    [updates-testing-source]
    name=Fedora 10 - Test Updates Source
    failovermethod=priority
    #baseurl=http___download.fedoraproject.org/pub/fedora/linux/updates/testing/10/SRPMS/
    mirrorlist=http___mirrors.fedoraproject.org/mirrorlist?repo=updates-testing-source-f10&arch=i386
    enabled=0
    gpgcheck=1
    gpgkey=file___/etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-test-i386
    [root@64978 ~]#

  4. #4
    Join Date
    Jul 2007
    Location
    127.0.0.1
    Posts
    392

    Default

    Quote Originally Posted by scottwb View Post
    Thanks for replying Guy. I'll take your Debian suggestion under advisement...I have been using Fedora/RedHat for a long long time, and it's really the only Linux distro I've used for real work, so of course I am a bit hesitant to switch just yet, but I am open to being convinced...

    I have dedicated hardware that I've been running FC5-9 on with no yum problems. I haven't done anything all that complicated with yum, but I don't really consider "yum install ruby" to be all that complex. I guess maybe I should try installing my own FC10 installation from DVD an a local machine and comparing the yum configs.

    Anyway, here's the output you requested. Thanks for the help on this.
    No problem. If you're comfortable with RedHat based distros, more power to you I just try and catch 'em early on when possible. Ok, anyway..

    What happens if you replace all the "enabled=0" entries with "enabled=1" then run yum update && yum install ruby ?

    If we don't catch each other this evening, I'll try and logon first thing in the AM. One of my colleagues is a RedHat zealot so perhaps I can prod him for some insight if the suggestion above doesn't work.

  5. #5
    Join Date
    Dec 2007
    Posts
    1,141

    Default

    The Link-1's memory allocation will prevent yum from operating as expected if you are using OpenVZ (hard memory limit). If you are using Xen (soft memory limit, swap allowed), there may be another issue preventing yum from working as expected.

    Please check your /proc/user_beancounters file if you are running under OpenVZ - if you note entries in the failcnt column, this is most likely a result of yum exceeding the memory allocation for your VPS.

  6. #6
    Join Date
    Jan 2009
    Posts
    4

    Default

    Thanks Guy! Setting all those "enabled=0" to "enabled=1" seems to do the trick.

    @DanL - I am using Xen, so I don't think it was a hard memory limit problem.

    Maybe I am missing something, but doesn't it seem like this points to vpslink installing a watered-down yum configuration by default?

    One other thing I should point out is that I did upgrade my account from Link-1 to Link-2 since my last post. Today, (a couple days after upgrading), I tried "yum install ruby" and it still did not work - then after editing the yum repository config files as Guy suggested above, now it works.

  7. #7
    Join Date
    Dec 2007
    Posts
    1,141

    Default

    Quote Originally Posted by scottwb View Post
    Thanks Guy! Setting all those "enabled=0" to "enabled=1" seems to do the trick.

    . . .

    Maybe I am missing something, but doesn't it seem like this points to vpslink installing a watered-down yum configuration by default?

    One other thing I should point out is that I did upgrade my account from Link-1 to Link-2 since my last post. Today, (a couple days after upgrading), I tried "yum install ruby" and it still did not work - then after editing the yum repository config files as Guy suggested above, now it works.
    Alright - I will pass this along to our template developers (or at least their reasoning with that choice).

  8. #8
    Join Date
    Jan 2009
    Posts
    4

    Default

    Thanks Dan. Since my current installation is just an experiment, I will probably ending up starting from scratch again soon, so it would be great to know if there is some rationale behind the default yum config, or if there are other suggested workarounds, etc...

    Thanks
    -scottwb

  9. #9
    Join Date
    Dec 2007
    Posts
    1,141

    Default

    Sorry for the wait. Our template developers suggested that the package was most likely in the "rawhide" repository.

    As the rawhide repository contains potentially-unstable code (the Fedora Project Wiki includes an FAQ: "Will rawhide destroy my data? It could. Don't trust it. The traditional phrasing is that rawhide 'eats babies.'") our template developers have left it disabled by default.

    Default enabled repositories:

    [fedora] enabled=1
    [updates] enabled=1

    Default disabled repositories:

    [rawhide] enabled=0
    [rawhide-debuginfo] enabled=0
    [rawhide-source] enabled=0
    [fedora-debuginfo] enabled=0
    [fedora-source] enabled=0
    [updates-debuginfo] enabled=0
    [updates-source] enabled=0
    [updates-testing] enabled=0
    [updates-testing-debuginfo] enabled=0
    [updates-testing-source] enabled=0

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •