简体   繁体   English

符号查找错误未定义符号:mysql_init

[英]Symbol lookup error undefined symbol: mysql_init

When I am trying the below perl scrip, I am getting the "perl:symbol lookup error". 当我尝试下面的perl脚本时,出现“ perl:symbol查找错误”。 It looks if I modify the PATH currently I could have resolve the issue. 它看起来是否可以在当前修改PATH的情况下解决问题。 But I am not sure what lib I should bring to the PATH. 但是我不确定应该把什么库带到PATH。 Please let me know how do I resolve this and feel free to share if you have any different solutions or workarounds to this issue. 如果您对此问题有其他解决方案或解决方法,请告诉我如何解决,并随时与大家分享。

[root@localhost]# ./create_defs.pl --user root --password amma --db=d1 --table=tbl1

**perl: symbol lookup error: /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi/auto/DBD/mysql/mysql.so: undefined symbol: mysql_init**

[root@localhost]# ll /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi/auto/DBD/mysql/mysql.so

-r-xr-xr-x 1 root root 333965 Sep 12 13:05 /usr/lib64/perl5/site_perl/5.8.8/x86_64-linux-thread-multi/auto/DBD/mysql/mysql.so

[root@localhost]# echo $PATH
/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/mysql/bin:/root/bin

From comment 来自评论

Here is the perl version in my server, so how do I resolve this issue? 这是服务器中的perl版本,那么如何解决此问题?

[root@localhost lib]# perl -v

This is perl, v5.8.8 built for x86_64-linux-thread-multi

From comment 来自评论

Thank you for responding. 感谢您的回应。 Following are the commands I used to do the installation 以下是我用来进行安装的命令

perl -MCPAN -e 'install Bundle::DBI'
perl -MCPAN -e 'install DBD::mysql'
perl -MCPAN -e 'install Bundle::DBD::mysql'
perl -MCPAN -e 'DBI' perl -MCPAN -e 'DBD::mysql'
perl -MCPAN -e 'install perl-DBD-MySQL'
install Bundle::Mysql

Following are the commands I used, can you please guide me how to clear all the perl module and do the reinstallation. 以下是我使用的命令,能否请您指导我如何清除所有perl模块并重新安装。

This isn't a standard Perl error message but reflects a problem with your perl installation. 这不是标准的Perl错误消息,但反映出您的Perl安装存在问题。

You have multiple different builds of perl that aren't playing nice. 您有多个不同版本的perl,表现不佳。

Without being able to delve into your system the best advice I can give is to remove perl completely and reinstall. 无法深入研究您的系统,我能提供的最佳建议是完全删除perl并重新安装。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 perl:符号查找错误:/usr/local/lib/perl/5.10.1/auto/DBD/mysql/mysql.so:未定义符号:mysql_init - perl: symbol lookup error: /usr/local/lib/perl/5.10.1/auto/DBD/mysql/mysql.so: undefined symbol: mysql_init imp:符号查找错误:未定义符号sldext - imp : symbol lookup error : undefined symbol sldext 符号查找错误:未定义的符号:_alloca - symbol lookup error: undefined symbol: _alloca 符号查找错误:未定义符号:FT_Get_Font_Format - symbol lookup error: undefined symbol: FT_Get_Font_Format 如何修复符号查找错误:群集环境中的未定义符号错误 - How to fix symbol lookup error: undefined symbol errors in a cluster environment 系统查找错误未定义符号SFML - system lookup error undefined symbol SFML 符号查找错误未定义符号,但似乎所有符号都存在 - Symbol lookup error undefined symbol, but all symbols seem to be present 符号查找错误:未定义的符号 atexit (linux/C) - Symbol lookup error: undefined symbol atexit (linux/C) 符号查找错误:/usr/local/lib/libsvn_subr-1.so.0:未定义的符号:apr_atomic_xchgptr - symbol lookup error: /usr/local/lib/libsvn_subr-1.so.0: undefined symbol: apr_atomic_xchgptr freshclam:符号查找错误:freshclam:未定义符号:print_version,版本 FRESHCLAM_PRIVATE - freshclam: symbol lookup error: freshclam: undefined symbol: print_version, version FRESHCLAM_PRIVATE
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM