麻辣堂|资源主站|开发论坛|在线手册
首页 Apache Linux Java MySQL 注册帮助 
PHP项目开发组是PHP开发资源网于2007组年建成立的项目开发团队,目前核心开发成员有27人, 项目协作成员8名.下设7个开发组,主要承接大/中型网站项目开发任务。

    由于开发任务较多,人员比较紧张,现面向社会招聘全职或者兼职开发人员,不管你是在校大学生,还是全职开发人员,以及SOHO都可以联系本站,我们可以长期合作,并为您带来丰厚的报酬。
  您现在的位置:PHP开发资源网 > 麻辣堂 > 详细资料
待解决
perl DBI DBD::MYSQL安装全过程(原创)--贡献于热忠cgi的村友
悬赏分:20 - 2007年08月15日

WINDOWNS下安装:

DBI-MYSQL下载
http://www.mysql.com/downloads/contrib.html
安装过程:用ppm
ppm> install DBI
ppm> install DBD-MySQL

unix下安装:
perl安装的默认路径:
/usr/local/apache/cgi-bin/
无须配置perl即可运行,必有语句:
#!/usr/bin/perl
print "content-type:text/html","\n\n";

安装DBI
shell> perl -MCPAN -e shell
cpan> install DBI
cpan> install DBD::mysql

The DBD::mysql installation runs a number of tests. These tests require being able to connect to the local MySQL server as the anonymous user with no password. If you have removed anonymous accounts or assigned them passwords, the tests fail. You can use force install DBD::mysql to ignore the failed tests.

DBI requires the Data:umper module. It may be installed; if not, you should install it before installing DBI.

It is also possible to download the module distributions in the form of compressed tar archives and build the modules manually. For example, to unpack and build a DBI distribution, use a procedure such as this:

Unpack the distribution into the current directory:

shell> gunzip < DBI-VERSION.tar.gz | tar xvf -

This command creates a directory named DBI-VERSION.

Change location into the top-level directory of the unpacked distribution:

shell> cd DBI-VERSION


Build the distribution and compile everything:

shell> perl Makefile.PL
shell> make
shell> make test
shell> make install


The make test command is important because it verifies that the module is working. Note that when you run that command during the DBD::mysql installation to exercise the interface code, the MySQL server must be running or the test fails.

或者直接用port安装:
shell >cd /usr/ports/databases/p5-DBI/
shell >make install
shell >/usr/ports/databases/p5-DBD-mysql/
shell >make install

由于mysql5和以前版本的算法不同,所以
update mysql.user set password = old_password('newpwd')
where host = 'localhost' and user = 'root';
然后flush priviledges;

提问者:chao008   08-15 17:05
答复
路过。。。顺便帮顶:)
回答者:玉米づ冰冻可乐 - 瓦岗村民 8-22 09:10
我也来回答:
不管你有没有帮助我们,瓦岗寨8万村民将感谢你。。。。。

为防止灌水,您需要计算一道数学题: 答案:
54 + 28 = ? 请将计算结果填在上面

 
[]
©2007 PhpRes.COM