[MDEV-23327] Can't uninstall UDF if the implementation library file doesn't exist Created: 2020-07-29 Updated: 2021-04-19 Resolved: 2020-10-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | OTHER |
| Affects Version/s: | 10.1, 10.2, 10.3, 10.4, 10.5 |
| Fix Version/s: | 10.2.35, 10.3.26, 10.4.16, 10.5.7 |
| Type: | Bug | Priority: | Major |
| Reporter: | Hartmut Holzgraefe | Assignee: | Oleksandr Byelkin |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
When an installed UDF can't be loaded at startup as its .so file can't be found anymore,, the error log will contain warnings about not being able to load the function
but the function can't be removed with DROP FUNCTION:
It can only be removed by deleting the related row in the mysql.func table directly with DELETE FROM mysql.func WHERE name='...' It should be able to remove a function with DROP even if it couldn't initialize for whatever reason, including missing .so file |
| Comments |
| Comment by Oleksandr Byelkin [ 2020-07-29 ] |
|
There is minor security problem with UDF first we check presence of UDF and only then rights to delete |
| Comment by Oleksandr Byelkin [ 2020-07-29 ] |
|
Main problem with the case is that we remove UDF and SP with the same command. |
| Comment by Oleksandr Byelkin [ 2020-07-29 ] |
|
commit 2792940391a17b6784f3d4dea2285a14356205ae (HEAD Made cleanup of DROP (udf) FUNCTION procedure and also check of mysql.func (not only loaded udf). |
| Comment by Oleksandr Byelkin [ 2020-10-11 ] |
|
commit 5b86139118d8fe32b90caeaa4282edc2879cfcb5 (HEAD Made cleanup of DROP (udf) FUNCTION procedure and also check of mysql.func (not only loaded udf). |
| Comment by Sergei Golubchik [ 2020-10-18 ] |
|
ok to push |