Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

First time in my life I have something like this:

root@peklan:~# aptitude install git-core
No packages will be installed, upgraded, or removed.
0 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B of archives. After unpacking 0 B will be used.
FATAL -> Failed to fork.   

can somebody explain how to get rid of this message?

share|improve this question
Because it is already installed? Not sure about the fork error though. What happens if you use apt-get? – Zoredache Jun 25 '12 at 0:22
ok so question then what's that message about? – holms Jun 25 '12 at 0:24

2 Answers 2

up vote 10 down vote accepted

that error message generally means aptitude or apt-get ran out of memory.

some suggestions:

  • if it's a VM, try increasing the RAM allocated to it. if it's a physical machine, try upgrading RAM.

    • if you've got some big memory hungry programs running (e.g. iceweasel, chromium, openoffice) then try killing them. in fact, if you're logged in with X, try logging out and running your upgrade from a text console or over an ssh session.
  • if you've got lots of deb and deb-src entries in your sources.list file(s), then try commenting out most of them, running 'apt-get update', and 'apt-get install git-core'.

(definitely comment out all the deb-src entries unless you frequently rebuild debian source packages for some reason - most people don't.)

  • i'm not sure if it will help (probably won't), but you might also want to look at the Cache-Limit setting. see the man page for apt.conf for details, but in short add something like the following to /etc/apt/apt.conf or to a new text file in /etc/apt/apt.conf.d:

    APT { Cache-Limit "56777216";} };

share|improve this answer
I added a note to the bottom of the known bug concerning apt xapian indexing, which may automatically be happening at the end of the aptitude operation, reference Ubuntu bug 363695 – maxpolk Jan 5 '13 at 16:12
I'm running a VPS with a fixed memory, stopping nginx, mysql and php before the upgrade worked, wrote it as a one line to make it return services back on as fast as possible. – Mohammad AbuShady Mar 4 '14 at 12:38

You can also add swap memory before you attempt to install the package.

You can add 512Mb swap by executing:

curl -sSL | bash
share|improve this answer
This is downloading and executing some shell script. Could you explain what this does on your machine? – Akkumulator Sep 11 at 17:26
@Akkumulator it is a public configuration that activate swap – Tk421 Sep 13 at 7:45
Yea, but it also does a bunch of other stuff, like cp /tmp/manageacloud/ /tmp/manageacloud/vcs/ and apt-get install -q git. Not sure if that's what I want if I only want a swapfile. – Akkumulator Sep 13 at 8:28
@Akkumulator this is a generic template to implement many different configurations. This one is very simple and you can copy/paste if you prefer. is the script that contains the code to activate swap. I agree that the generic script if it is not using git it should not install it. Anyway, it is not harmful. Use whatever is better for you. I will open a request to optimize the generic template. – Tk421 Sep 13 at 8:52

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.