<VirtualHost 1.2.3.4:80> #写你的服务器IP
$ pear channel-discover pear.chiaraquartet.net
$ pear install chiara/Chiara_PEAR_Server-0.18.7
Copying DB_DataObject config file to "C:/php5/pear/data/Chiara_PEAR_Server/data/DBDataObject/pear.ini"
updating database to add deprecated package support
Table 'pear.packages' doesn't exist
/www/mysql/bin/mysql pear -uroot -ppwd < /www/php/lib/php/data/Chiara_PEAR_Server/data/pearserver.sql
1-6, 'all', 'abort', or Enter to continue: 6
Channel Name (server uri like pear.php.net) [] : pear.phpeye.com
2. Mysql Username (must have create permision) : pear
4. Database Host : localhost
5. Channel Administrator Handle (package.xml user tag) : haohappy
6. Channel Name (server uri like pear.php.net) : pear.phpeye.com
Copying DB_DataObject config file to
1-3, 'all', 'abort', or Enter to continue:
1-6, 'all', 'abort', or Enter to continue: 4
temporary path to save uploaded releases in [] : /websites/pear/upload
2. Path to document root of web server for pear.phpeye.com : /websites/pear
3. name of frontend.php HTML admin frontend file : frontend.php
4. temporary path to save uploaded releases in : /websites/pear/upload
5. port clients should connect to (443 is SSL, 80 is regular HTTP) : 80
6. protocol clients should use to connect (http or https) : http
执行结果:
adding channel to local registry
Successfully created /websites/pear/frontend.php
Successfully created /websites/pear/pear_server.css
Enabling REST for channel pear.phpeye.com
Adding REST 1.0 and REST 1.1 to channel.xml
Saving Categories REST
Saving All Maintainers REST
Saving Maintainer REST
Maintainer haohappy
Saving Package REST
Saving Category Package REST
Install scripts complete
来管理你的PEAR频道。你可以创建类库的分类,创建类库,上传一个打包好的发布版本等等。

其他PHP程序员如何使用你的频道中的PEAR包呢?
首先要获取你的频道信息:
$ pear channel-discover pear.phpeye.com
$ pear install HappyBear
至于如何制作一个合乎规范的PEAR包,Haohappy下次另外撰文介绍。