UBUNTU14 installation of the lamp environment and installation of YAF extension, ubuntu14yaf_php tutorial

Source: Internet
Author: User
Tags phpinfo

UBUNTU14 the installation of the lamp environment and the installation of the YAF extension, ubuntu14yaf


In the previous period, the lamp environment was installed under Ubuntu, recording the installation process for easy access later.

Install lamp Environment

① Installing Apache

sudo Install apache2

The system will pop up prompt, at this time need to enter the user's password to install, the following other installation operations need to enter the password, each time the same.

At this point, open the browser input localhost, the following interface shows that the installation was successful.

② Installing PHP

sudo Install PHP5

③ installing MySQL

sudo Install Mysql-server

At this point the lamp Environment installation is complete. The test is correct .

After the Apache installation is complete , The root directory is /var/www/html

CD  /var/www/htmlsudovi phpinfo.php

Input

 
  PHP phpinfo();? >

Then open the browser input localhost/phpinfo.php, the following page appears to indicate that the installation was successful.

Installing a PHP Development Package

Extensions can only be installed if a development package is installed

sudo Install Php5-dev

Install extensions for PHP

A) Install php-mysql

This installation comes with the system library and is installed directly.

sudo Install Php5-mysql

Restart Apache to load mysql support

sudo service  apache2 restart

b) Install YAF

Install yaf before installing pcre Library, otherwise installation YAF will error

sudo Install libpcre3 Libpcre3-dev

Download the latest yaf file

CD  /usr/local/src/sudowget https://github.com/laruence/php-yaf/ Archive/master.zip

    • Prevent the same name as the file you downloaded later, so change the name to differentiate.

Extract

sudo Unzip Yaf. Zip

After decompression as shown

CD php-yaf-mastersudo /usr/bin/phpize

Configuration

Compile

Compiling the installation

After completion, the yaf.so file is generated in the following directory

Modify The configuration of the php.ini, load the yaf

sudo VI

extended directory changed to survive So directory where the files are located

New

Restart Apache

sudo service apache2 restart

At this point, the refresh found yaf has been installed correctly

If you need additional installation steps that extend similar to YAF.

http://www.bkjia.com/PHPjc/1010335.html www.bkjia.com true http://www.bkjia.com/PHPjc/1010335.html techarticle UBUNTU14 the installation of the lamp environment and the installation of the YAF extension, ubuntu14yaf before the time in the installation of the lamp environment in Ubuntu, recording the installation process for easy access later. Install lamp environment ① ...

  • Related Article

    Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.