Install the pear module in PHP in centos and configure the virtual host to support the pear module.

Source: Internet
Author: User

Install the pear module in PHP in centos and configure the virtual host to support the pear module.
Wget http://pear.php.net/go-pear
PHP go-Pear

Prompt
Sorry! Your PHP version is too new (5.2.14) for this go-pear.
Download New Version

Wget http://pear.php.net/go-pear.phar
PHP go-pear.phar

Then prompt

1. Installation Base ($ prefix):/usr/local/PHP
2. temporary directory for processing:/tmp/pear/install
3. temporary directory for downloads:/tmp/pear/install
4. binaries Directory:/usr/local/PHP/bin
5. PHP code directory ($ php_dir):/usr/local/PHP/share/Pear
6. Documentation Directory:/usr/local/PHP/docs
7. Data Directory:/usr/local/PHP/Data
8. User-modifiable configuration files directory:/usr/local/PHP/cfg
9. Public Web files directory:/usr/local/PHP/WWW
10. Tests Directory:/usr/local/PHP/Tests
11. Name of configuration file:/usr/local/PHP/etc/pear. conf

1-11, 'all' or enter to continue:

Click "OK" to confirm the default installation.
Then prompt:

Wocould you like to alter PHP. ini? [Y/n]: Y

Update the php. ini configuration file.

/Usr/local/PHP/bin/pear channel-update pear.php.net
/Usr/local/PHP/bin/pear install html_template_sigma

You can add/usr/local/PHP/bin/to the PATH variable.

Pear install DB

 

Warning: include_once (): open_basedir restriction in effect. file (/usr/share

Restrict VM permissions? (Y/N): Enter "N" here without restriction on permissions. Otherwise, the "open_basedir restriction in effect" error will appear!

Modify the VM profile httpd-vhosts.conf as follows:

& Lt; directory/home/wwhttpd-vhosts.conf
W/default/> ^ m
Options + includes-indexes ^ m
Require all granted
AllowOverride all ^ m
Php_admin_value open_basedir/home/www/Default:/usr/share/pear:/usr/local/pear/share/pear:/tmp:/proc ^ m
</Directory> ^ m
</Virtualhost> ^ m
Include CONF/vhost/* ^ m

 

 

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.