Bug 239732 - databases/mariadb103-server: Variable 'innodb_compression_algorithm' can't be set to the value of 'lz4'
Summary: databases/mariadb103-server: Variable 'innodb_compression_algorithm' can't be...
Status: New
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Many People
Assignee: Bernard Spil
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-08-09 06:25 UTC by TAO ZHOU
Modified: 2019-08-12 03:52 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (brnrd)


Attachments
Patch to support lz4 compression (763 bytes, patch)
2019-08-12 03:51 UTC, TAO ZHOU
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description TAO ZHOU 2019-08-09 06:25:21 UTC
lz4 support is missing event if I selected ticked it in poudriere options.
It also shows 'on' in `pkg info`.

```
mariadb103-server-10.3.16_1
Name           : mariadb103-server
Version        : 10.3.16_1
Installed on   : Fri Aug  9 15:17:15 2019 AEST
Origin         : databases/mariadb103-server
Architecture   : FreeBSD:11:amd64
Prefix         : /usr/local
Categories     : databases ipv6
Licenses       : GPLv2
Maintainer     : brnrd@FreeBSD.org
WWW            : https://mariadb.org/
Comment        : Multithreaded SQL database (server)
Options        :
	CONNECT_EXTRA  : on
	DOCS           : on
	GSSAPI_BASE    : off
	GSSAPI_HEIMDAL : on
	GSSAPI_MIT     : off
	GSSAPI_NONE    : off
	INNOBASE       : on
	LZ4            : on
	LZO            : off
	MROONGA        : off
	MSGPACK        : off
	OQGRAPH        : off
	ROCKSDB        : off
	SNAPPY         : off
	SPHINX         : on
	SPIDER         : on
	TOKUDB         : off
	WSREP          : on
	ZMQ            : off
	ZSTD           : off

```

I could see 'liblz4' from ldd output.
```
~ # ldd /usr/local/libexec/mysqld
/usr/local/libexec/mysqld:
	liblzma.so.5 => /usr/lib/liblzma.so.5 (0x80181b000)
	libbz2.so.4 => /usr/lib/libbz2.so.4 (0x801a44000)
	libz.so.6 => /lib/libz.so.6 (0x801c58000)
	libm.so.5 => /lib/libm.so.5 (0x801e70000)
	libexecinfo.so.1 => /usr/lib/libexecinfo.so.1 (0x80209d000)
	libwrap.so.6 => /usr/lib/libwrap.so.6 (0x8022a0000)
	libcrypt.so.5 => /lib/libcrypt.so.5 (0x8024a9000)
	libssl.so.11 => /usr/local/lib/libssl.so.11 (0x8026c8000)
	libcrypto.so.11 => /usr/local/lib/libcrypto.so.11 (0x802a00000)
	libc++.so.1 => /usr/lib/libc++.so.1 (0x802eec000)
	libcxxrt.so.1 => /lib/libcxxrt.so.1 (0x8031ba000)
	libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x8033d9000)
	libthr.so.3 => /lib/libthr.so.3 (0x8035e8000)
	libc.so.7 => /lib/libc.so.7 (0x803810000)
	libelf.so.2 => /lib/libelf.so.2 (0x803bcc000)
```

According to this link https://mariadb.com/kb/en/library/compression/+comments/2002, the CMakeCache.txt should contain

```
WITH_INNODB_LZ4:STRING=AUTO
HAVE_LZ4_H:INTERNAL=1
HAVE_LZ4_SHARED_LIB:INTERNAL=1
```
But when I looked at CMakeCache.txt in poudriere, it only had
```
WITH_INNODB_LZ4:BOOL=true
```
I think this might be the problem.
Comment 1 TAO ZHOU 2019-08-12 03:51:29 UTC
Created attachment 206463 [details]
Patch to support lz4 compression
Comment 2 TAO ZHOU 2019-08-12 03:52:26 UTC
I have successfully compiled mariadb with lz4 support with the above patch.