0

Hi I am trying to install APC via pecl in mediatemple DV server, but i am getting this error. Can someone help?

[root@klph-jyj2 ~]# mkdir -p /root/chroot /root/tmp
[root@klph-jyj2 ~]# mount --bind / /root/chroot
[root@klph-jyj2 ~]# mount --bind /root/tmp /root/chroot/tmp
[root@klph-jyj2 ~]# chroot /root/chroot
[root@klph-jyj2 /]# pecl install apc
downloading APC-3.1.13.tgz ...
Starting to download APC-3.1.13.tgz (Unknown size)
....done: 3,582 bytes
Could not get contents of package "/tmp/pear/download/APC-3.1.13.tgz". Invalid tgz file.
Download of "pecl/apc" succeeded, but it is not a valid package archive
Error: cannot download "pecl/APC"
Download failed
install failed

install failed

FlatLander
  • 1,717
  • 15
  • 21

1 Answers1

0

Googling for the error message, I find several results that indicate a bug in Ubuntu.

Apparently there are some workarounds, the easiest being the installation of an uncompressed version:

pecl install -Z apc
lxg
  • 12,375
  • 12
  • 51
  • 73
  • By the way, you should try installing APC from the distribution, there should be a package `php-apc`. Unless you're using PHP 5.5+, then switch to APCU + opcache. – lxg Aug 31 '14 at 21:16
  • Did you try installing the uncompressed archive? – lxg Sep 01 '14 at 06:52