我們最常用的 DBD::mysql 模塊,我發現是難住很多人的地方.因為安裝老是失敗,下面我介紹一下解決方法,比如我使用 cpanm 安裝,有時就出 /home/nue2501j/work/DBD-mysql-4.010/blib/arch/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL at /usr/lib/perl5/5.8.5/i386-linux-thread-multi/DynaLoader.pm line 230.
如下
1.
# cpanm DBD::mysql
出錯
# Tried to use 'DBD::mysql'. # Error: Can't load '/home/nue2501j/work/DBD-mysql-4.010/blib/arch/auto/DBD/mysql/mysql.so' for module DBD::mysql: /home/nue2501j/work/DBD-mysql-4.010/blib/arch/auto/DBD/mysql/mysql.so: undefined symbol: DBIc_TRACE_LEVEL at /usr/lib/perl5/5.8.5/i386-linux-thread-multi/DynaLoader.pm line 230. # at (eval 4) line 2 # Compilation failed in require at (eval 4) line 2. # BEGIN failed--compilation aborted at (eval 4) line 2. FAILED--Further testing stopped: Unable to load DBD::mysql make: *** [test_dynamic] Error 9
2. [代碼][SQL]代碼
解決方法
$ sudo perl -MCPAN -e shell cpan> install Bundle::DBD::mysql /usr/bin/make -- OK /usr/bin/make test -- OK /usr/bin/make install -- OK cpan> install DBD::mysql DBD::mysql is up to date.
以上所述就是本文的全部內容了,希望大家能夠喜歡。