PHP

Setting up a LAMP (Apache, MySQL, PHP) development environment on Ubuntu 14.04 (Trusty) LTS for local Drupal/Wordpress development

This is how I normally set up my local Drupal development machines after a fresh Ubuntu 14.04 LTS (desktop/MATE edition) install.

1. Install required packages

From Terminal, execute the following command to update the repository information and to get the system up-to-date:

sudo apt-get update
sudo apt-get upgrade

Next, install some basic necessities:

[SOLVED][PHP PEAR] How to fix the error 'could not extract the package.xml file' and 'Download of "pecl/uploadprogress" succeeded, but it is not a valid package archive', when trying to install PECL uploadprogress using PHP PEAR on Ubuntu 14.04 Trusty

Setting up, upgrading and maintaining a clean and functional Drupal/PHP Development environment is an art, and quite a piece of cake for the skilled sysadmin. But the ever changing versions of OS packages and dependencies can bring up quite some unexpected challenges to a budding developer. Here is the solution to one such error that might eat your brains out.

Almost all usable versions of Drupal - 6, 7 and 8 - use PECL uploadprogress to show file upload progress.
And installing it on previous Ubuntu, PHP versions was as easy as running the following command:

Setting up a LAMP (Apache, MySQL, PHP) development environment on Ubuntu 13.04 (Raring) / 12.10 (Quantal) / 12.04 (Precise) for Drupal/Wordpress development

Setting up a LAMP (Apache, MySQL, PHP) development environment on Ubuntu 11.04 (Natty) / 11.10 (Oneiric) for Drupal/Wordpress development

 
Package Installation
From Terminal, execute the following command to install the required packages:

sudo apt-get install apache2 mysql-server mysql-client php5 libapache2-mod-php5 php5-gd php5-mysql php5-cli  php5-curl kcachegrind  php5-ffmpeg php5-mcrypt php5-imagick php5-xdebug phpmyadmin

Additional Configuration

1. To fix the Fully Qualified Domain Name issue for Apache

[SOLVED] Drupal - How to fix PHP Fatal error: Call to undefined function curl_init() on Ubuntu linux

One of the Drupal sites that we got to work with had this issue. The original server that the site was hosted on did not have any issue. But the issue showed up when it was transferred over to a new server.

This usually happens when you are missing the php5-curl library.

On Ubuntu, just run the following commands in your terminal to fix this:

sudo apt-get install php5-curl
sudo /etc/init.d/apache2 restart

If not on Ubuntu, check for the correct alternative to 'apt-get' for your distribution.

Setting up a LAMP (Apache, MySQL, PHP) development environment on Ubuntu 11.04 (Natty) / 11.10 (Oneiric) for Drupal/Wordpress development

Setting up a LAMP (Apache, MySQL, PHP) development environment on Ubuntu 11.04 (Natty) / 11.10 (Oneiric) for Drupal/Wordpress development

 
Package Installation
From Terminal, execute the following command to install the required packages:

sudo apt-get install apache2 mysql-server mysql-admin mysql-query-browser mysql-client mysql-navigator php5 libapache2-mod-php5 php5-gd php5-mysql php5-cli  php5-curl kcachegrind  php5-ffmpeg php5-mcrypt php5-imagick php5-xdebug phpmyadmin

Additional Configuration

1. To fix the Fully Qualified Domain Name issue for Apache

Services

Advantages

  • Excellent Programming Skills
  • Level 4 Administration Skills
  • Excellent Research Skills
  • Smooth Communication
  • Flexible Work Hours
  • Reliable Support

Services

  • System Administration

    • Operating Systems:
      • Linux - CentOS / Ubuntu / FreeBSD / Mandriva
      • UNIX
      • Windows
    • Web Servers:
      • Apache
      • nginx
      • lighthttpd
    • Databases:
      • MySQL
      • PostgreSQL
Subscribe to RSS - PHP