How to install YAF extensions on Ubuntu PHP instance

Source: Internet
Author: User
The following small series for you to share a piece of Ubuntu installed Yaf extension method, with a good reference value, I hope to be helpful to everyone. Let's take a look at it with a little knitting.

First, download

YAF Extension Download Address

Http://pecl.php.net/package/yaf

Select the package you want to download

wget Http://pecl.PHP.net/get/yaf-2.3.5.tgztar zxvf YAF-2.3.5.TGZCD yaf-2.3.5

Second, installation

#whereis phpize/data/yaf-2.3.5#/usr/bin/phpize#whereis php-configphp-config:/usr/bin/php-config/usr/share/man/ man1/php-config.1.gz/data/yaf-2.3.5#./configure--with-php-config=/usr/bin/php-config/data/yaf-2.3.5# Make & & Make Install

Workaround:

The last command may have an error: compilation terminated. Make: * [Yaf_router.lo] Error 1

sudo apt-get install libpcre3 libpcre3-dev OpenSSL Libssl-dev

Execute the last command again.

If everything goes well, it should be like this:

You can also perform the following make test

There is also the possibility of such an error: Cp:cannot create regular file '/usr/lib/php5/20121212/#INST @13121# ':P Ermission denied

This is not enough permissions, the current user is not root, you can switch to root via Su, enter the root password can be reset: sudo passwd root

Add in php.ini:

Extension=yaf.so

If you don't know where php.ini is, you can see phpinfo.

Finally, restart the server

Above this Ubuntu installs the Yaf extension the method is small to share to everybody's whole content, hoped can give everybody a reference, also hoped that everybody supports the PHP Chinese net.

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.