Could not install PHP PEAR

software development

#1

Hello.

I am using symfony on my local Windows fine and I tried installing symfony to my DreamHost environment.

But I could not install even pear package… I tried next command by reffering to http://wiki.dreamhost.com/index.php/PEAR


$ /usr/local/php5/bin/pear config-create $HOME .pearrc
Configuration (channel pear.php.net):

Auto-discover new Channels auto_discover
Default Channel default_channel pear.php.net
HTTP Proxy Server Address http_proxy
PEAR server [DEPRECATED] master_server
Default Channel Mirror preferred_mirror
Remote Configuration File remote_config
PEAR executables directory bin_dir /home/ishiro/pear
PEAR documentation directory doc_dir /home/ishiro/pear/docs
PHP extension directory ext_dir /home/ishiro/pear/ext
PEAR directory php_dir /home/ishiro/pear/php
PEAR Installer cache directory cache_dir /home/ishiro/pear/cache
PEAR data directory data_dir /home/ishiro/pear/data
PEAR Installer download download_dir
directory
PHP CLI/CGI binary php_bin
PEAR Installer temp directory temp_dir
PEAR test directory test_dir /home/ishiro/pear/tests
Cache TimeToLive cache_ttl
Preferred Package State preferred_state
Unix file mask umask
Debug Log Level verbose
PEAR password (for password
maintainers)
Signature Handling Program sig_bin
Signature Key Directory sig_keydir
Signature Key Id sig_keyid
Package Signature Type sig_type
PEAR username (for username
maintainers)
User Configuration File Filename /home/.matches/ishiro/tmp/.pearrc
System Configuration File Filename #no#system#config#
Successfully created default configuration file “/home/.matches/ishiro/tmp/.pearrc”

$ /usr/local/php5/bin/pear install --alldeps PEAR
downloading PEAR-1.5.1.tgz …

Notice: Undefined variable: php_errormsg in Downloader.php on line 1498
Could not download from “http://pear.php.net/get/PEAR-1.5.1.tgz”, cannot download "pear/PEAR"
Error: cannot download "pear/PEAR"
downloading XML_RPC-1.5.1.tgz …

Notice: Undefined variable: php_errormsg in Downloader.php on line 1498
Could not download from “http://pear.php.net/get/XML_RPC-1.5.1.tgz”, cannot download "pear/XML_RPC"
Error: cannot download “pear/XML_RPC”

Please tell me what’s wrong. Thank you for your advice in advance.

–ishiro


#2

I am having the same exact issue. Any ideas?


#3

I am a little closer. I used PHP4 to download and install it. then switched to PHP5. The error is that it can’t write to /tmp/pear/cache

so you need to use config_set download_dir and config_set temp_dir to adjust the paths.