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've got a vps which runs solusVM. I'm now trying to install ruby 1.9.2 in it.

I'm following this guide:

After I run this command:

apt-get update
apt-get -y install build-essential zlib1g zlib1g-dev libxml2 libxml2-dev libxslt-dev

I got this error :

root@makserver:/usr/local/src/ruby-1.9.2-p0# apt-get -f install
Reading package lists... Done
Building dependency tree... Done
Correcting dependencies... Done
The following extra packages will be installed:
Suggested packages:
The following packages will be upgraded:
1 upgraded, 0 newly installed, 0 to remove and 80 not upgraded.
Need to get 0B/4252kB of archives.
After this operation, 4096B disk space will be freed.
Do you want to continue [Y/n]? y
debconf: apt-extracttemplates failed: Bad file descriptor
(Reading database ... 21594 files and directories currently installed.)
Preparing to replace libc6 2.11.1-0ubuntu7.2 (using .../libc6_2.11.1-0ubuntu7.8_amd64.deb) ...
open2: fork failed: Cannot allocate memory at /usr/share/perl5/Debconf/ line 59
dpkg: error processing /var/cache/apt/archives/libc6_2.11.1-0ubuntu7.8_amd64.deb (--unpack):
 subprocess new pre-installation script returned error exit status 12
Errors were encountered while processing:
E: Sub-process /usr/bin/dpkg returned an error code (1)

Can anybody tell me how I can correct this? Thanks.

share|improve this question
up vote 2 down vote accepted

There are typos in the guide you linked to.

Initial steps should be:

sudo apt-get update
sudo apt-get install build-essential zlib1g zlib1g-dev libxml2 libxml2-dev libxslt-dev
sudo apt-get install git-core
sudo apt-get install curl wget

I've also removed the -y flag, and prefixed the commands with sudo so you can (and probably should) run these with your regular (non-root) user.

I don't see the command you mention, apt-get -f install, anywhere on that page. Having to use that generally means something is already broken. You should probably start again from the beginning, making sure each step completes.

However, I don't think you need to do any of this.

Ubuntu's ruby1.9.1 package actually provides Ruby 1.9.2 .

If you look at the details in the output of `apt-cache show ruby1.9.1, you will find that the version provided in Ubuntu is actually 1.9.2.

It is listed as 1.9.1, because the Debian maintainer is meaning to describe the binary compatibility version (1.9.1), instead of the Ruby software version (1.9.2) .

See this Debian bug list entry for more information.

Here are a few snippets of the apt-cache show ruby1.9.1 output :

Package: ruby1.9.1
Filename: pool/universe/r/ruby1.9.1/ruby1.9.1_1.9.2.0-1_i386.deb
Description: Interpreter of object-oriented scripting language Ruby 1.9.2
 Ruby is the interpreted scripting language for quick and easy
 object-oriented programming. [...]
 This package provides version 1.9.2 series of Ruby, which is binary-compatible
 with the 1.9.1 branch.
share|improve this answer
You save me a lot of time, Thanks – mko Feb 19 '11 at 8:39

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.