LAMP stacks for production use? Using PHP 5.4.x, Apache 2.4.x, MySQL 5.5.x


November 2018


4.4k time


Ok I thought I'd try installing the latest and greatest LAMP stack on my test server in preparation for using it in production. I decided to go with Ubuntu server 12.04, Apache (2.4.2), MySQL 5.5.24 and PHP 5.4.2 and use PHP-FPM/fast-cgi. I was then writing down the steps required into an epic list so I could replicate them easily when the time came to move to my production VPS.

  • Ubuntu server installed no problems.
  • I got Apache installed from source ok and it loaded the test page.
  • MySQL compiled from source and installed
    fine. But then failed to run and I couldn't fix the mysql.sock error so I gave up. Then I just did an apt-get install mysql-server
    which got me version 5.5.22 which is a few versions out of date but
    it runs properly so that's ok I suppose.
  • So next comes PHP, that compiles, tests and installs fine. Now the
    final step: linking it in with Apache. And you can guess that it
    failed. It didn't compile with the necessary module so now that won't work. 'Cannot load /usr/local/apache2/modules/
    into server: /usr/local/apache2/modules/ cannot open
    shared object file: No such file or directory'.

Have google'd all these errors and tried fixing but getting nowhere. So have given up on the manual install for now as it's wasted two evenings so far.

  1. Is there any decent LAMP stack that can be used in production?
  2. Should you use one in production or should you really be installing everything manually? How does everyone get around this issue?
  3. I know there's lots of LAMP stacks out there like XAMPP etc but they're never updated frequently and always a few versions behind. Why do they never keep them up to date?
  4. Even when it's in production, how do you keep the installs up to date?

Also I suppose I could do apt-get to install everything. I love the one liner install but even those versions that get downloaded are way behind. Apache 2.4 would be nice for the speed improvements and I'm assuming it's best practice to keep up to date with PHP so you get the security enhancements.

2 answers


все работает просто отлично для меня, следуйте этим Tuts: -of-MySQL-из-источника /



Я лично использую DEBiAN-тестирование, но я слышал, что хранилище dotdeb является хорошим выбором.