[MDEV-28592] FreeBSD build does not include disk plugin Created: 2022-05-17  Updated: 2022-12-09  Resolved: 2022-08-31

Status: Closed
Project: MariaDB Server
Component/s: Platform FreeBSD, Plugins
Affects Version/s: 10.3, 10.4, 10.5, 10.6, 10.7, 10.8
Fix Version/s: 10.3.37, 10.4.27, 10.5.18, 10.6.10, 10.7.6, 10.8.5, 10.9.3, 10.10.2

Type: Bug Priority: Major
Reporter: Hartmut Holzgraefe Assignee: Daniel Black
Resolution: Fixed Votes: 1
Labels: None
Environment:

FreeBSD 13; datadir on ZFS volumes



 Description   

FreeBSD builds do not contain the disk.so plugin library in the plugins lib directory. If the plugin is being loaded by a .cnf config, this leads to

2022-05-15 20:40:18 0 [ERROR] mariadbd: Can't open shared library '/usr/local/lib/mysql/plugin/disks.so' (errno: 22, Cannot open "/usr/local/lib/mysql/plugin/disks.so")
2022-05-15 20:40:18 0 [ERROR] Couldn't load plugins from 'disks.so'.

on each startup



 Comments   
Comment by Elena Stepanova [ 2022-05-17 ]

I guess that's why:

10.3 3e564d468

$ cat plugin/disks/CMakeLists.txt 
IF("${CMAKE_SYSTEM}" MATCHES "Linux")
  INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/sql)
  MYSQL_ADD_PLUGIN(DISKS information_schema_disks.cc MODULE_ONLY RECOMPILE_FOR_EMBEDDED)
ENDIF()

Comment by Sergei Golubchik [ 2022-07-12 ]

FreeBSD doesn't have setmntent/getmntent that disks plugin uses. It would need an alternative BSD-specific implementation. likely based on getmntinfo().

Comment by Daniel Black [ 2022-08-01 ]

Also requires MDEV-27818 to be able to display zfs volumes.

Comment by Daniel Black [ 2022-08-01 ]

PR #2216

Confirmed as building the plugin on FreeBSD. I can't see it run the test in mtr.

Comment by Sergei Golubchik [ 2022-08-16 ]

review: https://github.com/MariaDB/server/pull/2216#issuecomment-1216828627

Generated at Thu Feb 08 10:01:55 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.