dialog.so cannot be loaded with perl and python clients when plugin-dir is set on [client] section of my.cnf
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
MySQL Server |
Unknown
|
Unknown
|
|||
Percona Server moved to https://jira.percona.com/projects/PS |
Fix Released
|
Medium
|
Sergei Glushchenko | ||
5.1 |
Invalid
|
Undecided
|
Unassigned | ||
5.5 |
Fix Released
|
Medium
|
Sergei Glushchenko | ||
5.6 |
Fix Released
|
Medium
|
Sergei Glushchenko |
Bug Description
Assuming this is set on my.cnf:
[client]
plugin-
On Perl Client, with source code:
use DBI;
$dbh = DBI->connect(
or die "Connection Error: $DBI::errstr\n";
$sql = "select * from mysql.user";
$sth = $dbh->prepare(
$sth->execute
or die "SQL Error: $DBI::errstr\n";
while (@row = $sth->fetchrow_
print "@row\n";
}
This will error out as:
DBI connect(
Connection Error: Authentication plugin 'dialog' cannot be loaded: /dialog.so: cannot open shared object file: No such file or directory
However, if you copy dialog.so to parent directory(/), it will work.
On Python client, with source code:
import MySQLdb
db = MySQLdb.
This will error out as:
File "test.py", line 3, in <module>
db = MySQLdb.
File "/usr/lib64/
return Connection(*args, **kwargs)
File "/usr/lib64/
super(
_mysql_
If installation is based on RPM, say for CentOS 6, you can comment out plugin-dir in my.cnf file and authentication will work.
However, the issue is dialog.so won't be loaded if Percona Server is installed using the binary version and placing it on a custom directory.
Related branches
- Laurynas Biveinis (community): Approve
-
Diff: 23 lines (+3/-3)1 file modifiedPercona-Server/sql-common/client.c (+3/-3)
- Laurynas Biveinis (community): Approve
-
Diff: 23 lines (+3/-3)1 file modifiedPercona-Server/sql-common/client.c (+3/-3)
summary: |
- dialog.so cannot be loaded when plugin-dir is set in my.cnf [client] - section and using mysql_read_default_file and read_default_file options - to load default config respectively + dialog.so cannot be loaded with perl and python clients when plugin-dir + is set on [client] section of my.cnf |
Changed in percona-server: | |
status: | New → Confirmed |
tags: | added: i29131 |
tags: | added: upstream |
This is not a bug of pam plugin, but likely a bug of client library.