Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am running 10.10 version.

I install APC as

sudo apt-get install php-apc

It gets APC (3.1.3p1) installed. The latest one is 3.1.10 right now.

How can I update to latest one?

Thanks.

share|improve this question
add comment

2 Answers 2

up vote 2 down vote accepted

You need to

  1. wait for it to turn up in the official Ubuntu repository, or
  2. install PEAR and use PECL/PEAR to install APC but I don't know if that will work for you on Ubuntu

Assuming you have PEAR/PECL installed (and any other necessary dependencies), this should install APC from that repository, which may be at a higher version than the Ubuntu package. It also requires 'libpcre3-dev' to be installed in order to compile properly.

sudo apt-get install libpcre3-dev
sudo pecl install apc
share|improve this answer
1  
for reference, i just successfully installed via pecl. however, it also requires 'libpcre3-dev' to be installed, otherwise there will be error compling. cogo.wordpress.com/2010/07/19/… . after that, just execute sudo pecl install apc to install. –  gilzero May 14 '12 at 15:30
add comment

Since you are running a released version of ubuntu, you shouldn't expect newer upstream versions of software to be released for that version of ubuntu, only security patches to older versions. You can see here that 3.1.10 has been released for a newer release of ubuntu. You can try backporting that version.

To backport, first you need to add a deb-src line to sources.list that can download source packages for quantal.

deb-src http://us.archive.ubuntu.com/ubuntu/ quantal main universe 

Add only that line to sources.list, do not add a deb line, just deb-src. Then run apt-get update. Then apt-get build-dep php-apc ; apt-get install build-essential will install the packages needed for building php-apc, and apt-get source -b php-apc should download the source for apc, and build a new .deb in the current directory. If this works, you can install the deb with somethign like dpkg -i ./php-apc-$newversion.deb

However, if you go this route (or pretty much any other route which moves you away from the official ubuntu package for your release), you are on your own for security updates to this package. And because of this, you should question whether you really need the newer version, or of you just want it because 10 > 3.

share|improve this answer
1  
APC 3.1.3 is now nearly 3 years old. I don't see why one should not upgrade. Lots and lots of bugs were fixed even by the step from 3.1.3 to 3.1.4: Complete Changelog‌​. –  SebiF May 14 '12 at 14:09
1  
and lots of new not yet discovered bugs could have potentially been introduced. Or incompatibilities with other software could have been introduced. This is always the trade-off. –  stew May 14 '12 at 14:13
    
thanks, should I remove current apc first before attempt install newer? sudo apt-get remove php-apc –  gilzero May 14 '12 at 14:46
    
no need to remove first, this will upgrade. –  stew May 14 '12 at 14:49
add comment

Your Answer

 
discard

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.