[MDEV-23849] MyRocks/RocksDB ZLib compression does not work! Created: 2020-09-29  Updated: 2021-01-02

Status: Open
Project: MariaDB Server
Component/s: Storage Engine - RocksDB
Affects Version/s: 10.5.5
Fix Version/s: 10.5

Type: Bug Priority: Major
Reporter: Charalampos Michael Assignee: Sergei Petrunia
Resolution: Unresolved Votes: 0
Labels: None
Environment:

Windows



 Description   

Hello,
I try to enable ZLib compression but it either fails or it does not enable it.

Tried the following parameters on my.ini:

rocksdb-override-cf-options='cf1={compression=kZlib;bottommost_compression=kZlib;}'

and

rocksdb-override-cf-options='cf1={compression=kZlibCompression;bottommost_compression=kZlibComporession;}'

and

rocksdb-override-cf-options='cf1={compression=Zlib;bottommost_compression=Zlib;}'

and

rocksdb-override-cf-options='cf1={compression=ZlibCompression;bottommost_compression=ZlibComporession;}'

none of the above worked

Thank you



 Comments   
Comment by MG [ 2020-10-03 ]

Hello,

I just tried in 10.4.14 and used eg compression=kZlibCompression and it works there:

MariaDB [test2]> select @@version, SP.sst_name, SP.compression_algo
from   information_schema.rocksdb_sst_props SP,
       information_schema.rocksdb_ddl D,
       information_schema.rocksdb_index_file_map IFM
 where   D.table_schema='test2' and D.table_name='myrockst1'
   and   D.index_number= IFM.index_number
   and   IFM.sst_name=SP.sst_name\G
*************************** 1. row ***************************
+---------------------+------------+------------------+
| @@version           | sst_name   | compression_algo |
+---------------------+------------+------------------+
| 10.4.14-MariaDB-log | 000115.sst | Zlib             |
+---------------------+------------+------------------+
1 row in set (0.001 sec)

I learned the name as suggested by https://mariadb.com/kb/en/myrocks-and-data-compression/ looking in the /var/lib/mysql/#rocksdb/LOG for supported compression.

Comment by Charalampos Michael [ 2020-10-22 ]

As I see you're using a Linux build and i'm in Windows build of MariaDB.
So i guess it works on Linux and not on windows ?

Comment by MG [ 2020-10-23 ]

I tried it on Windows and it seemed to work:

MariaDB [test2]> select @@version, @@version_compile_os;
+----------------+----------------------+
| @@version      | @@version_compile_os |
+----------------+----------------------+
| 10.5.6-MariaDB | Win64                |
+----------------+----------------------+
1 row in set (0.000 sec)
 
MariaDB [test2]> select @@version, SP.sst_name, SP.compression_algo
from   information_schema.rocksdb_sst_props SP,
       information_schema.rocksdb_ddl D,
       information_schema.rocksdb_index_file_map IFM
 where   D.table_schema='test2' and D.table_name='myrockst1'
   and   D.index_number= IFM.index_number
   and   IFM.sst_name=SP.sst_name\G
*************************** 1. row ***************************
       @@version: 10.5.6-MariaDB
        sst_name: 000033.sst
compression_algo: Zlib
1 row in set (0.001 sec)

Generated at Thu Feb 08 09:25:31 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.