1

here's what I am trying to do on Coding Ground

sh-4.3$ pip install --target=. virtualenv
You are using pip version 7.1.0, however version 8.1.2 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Collecting virtualenv
  Downloading virtualenv-15.0.2-py2.py3-none-any.whl (1.8MB)
    100% |################################| 1.8MB 204kB/s
Installing collected packages: virtualenv
Successfully installed virtualenv
sh-4.3$ python virtualenv.py mine
New python executable in /home/cg/root/mine/bin/python
Installing setuptools, pip, wheel...done.
sh-4.3$ . mine/bin/activate
(mine) sh-4.3$ pip install numpy
Collecting numpy
  Downloading numpy-1.11.0-cp27-cp27mu-manylinux1_x86_64.whl (15.3MB)
    99% |############################### | 15.3MB 43.1MB/s eta 0:00:01Killed
(mine) sh-4.3$

Why does my trying of installation of numpy keep being killed? And how do i solve this problem?

Tin Tran
  • 6,194
  • 3
  • 19
  • 34

1 Answers1

4

A quick fix for this would be to add swap memory. Here's an Ubuntu example:

sudo mkdir /media/fasthdd
dd if=/dev/zero of=/media/fasthdd/swapfile.img bs=1024 count=1M
sudo mkswap /media/fasthdd/swapfile.img
sudo swapon /media/fasthdd/swapfile.img

Don't forget to turn it off if you don't need it.

Bit68
  • 1,446
  • 10
  • 25