Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I tried to install ruby on my ubuntu 10.04 server edition

sudo apt-get install ruby

I get the following error

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
  ruby: Depends: ruby1.8 but it is not going to be installed
E: Broken packages
share|improve this question

I believe your problem is due to obsolete information your package manager has. I.e. it knows that ruby package depends on ruby1.8 package, but when it tries to install the latter, it can't find it in the repositories.

This is because Ruby in Lucid Lyx has been updated to version 1.9.1 since Lucid Lynx was released:

So you need to update the information used by the package manager:

sudo apt-get update

Then you can install ruby:

sudo apt-get install ruby

You'll get version 1.9.1

(also, consider applying security updates and bug fixes using sudo apt-get upgrade - at the moment your system is likely lacking 2 years worth of security updates)

share|improve this answer
Thanks for the reply. I tried installing ruby using aptitude instead of apt-get, and it works. I tried what you have said. i tried sudo apt-get upgrade and i see all are update to date. I have also updated by package-manager. I see something intresting. i see an update available for ruby version "". the current version i have is ruby "". and if i upgrade now it works. – Surya Chaitanya Feb 10 '12 at 4:14

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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