[MCOL-4689] Spurious [135B blob data] being put into PrimPrim jounralctl records Created: 2021-04-21  Updated: 2021-05-03  Resolved: 2021-04-22

Status: Closed
Project: MariaDB ColumnStore
Component/s: PrimProc
Affects Version/s: 5.5.2, 6.1.1
Fix Version/s: 5.6.1

Type: Bug Priority: Major
Reporter: Alexander Barkov Assignee: Roman
Resolution: Fixed Votes: 0
Labels: None

Sprint: 2021-7

 Description   

Journalctl displays these weird records:

$ journalctl -u mcs-primproc
...
Mar 22 21:25:18 home env[83679]: [135B blob data]
Mar 22 21:25:55 home env[83679]: [135B blob data]
Mar 22 21:25:55 home env[83679]: [135B blob data]

Running journalctl with --all helps to reveal what's the problem:

$ journalctl --all -u mcs-primproc
...
Mar 22 21:25:18 home env[83679]: ^GCharacter set '#3000' is not a compiled character set and is not specified in the '/opt/mariadb-10.5-cs/share/charsets/Index.xml' file
Mar 22 21:25:18 home env[83679]: ^GCharacter set '#3000' is not a compiled character set and is not specified in the '/opt/mariadb-10.5-cs/share/charsets/Index.xml' file
Mar 22 21:25:55 home env[83679]: ^GCharacter set '#3000' is not a compiled character set and is not specified in the '/opt/mariadb-10.5-cs/share/charsets/Index.xml' file

Tracing the code revealed that this message is displayed by get_charset() function calls, which obviously gets and invalid charset ID as an argument.

Further tracing revealed that the wrong charset ID is set in storage/columnstore/columnstore/dbcon/mysql/ha_mcs_execplan.cpp in this functions:

SimpleColumn* getSmallestColumn(boost::shared_ptr<CalpontSystemCatalog> csc,
                                CalpontSystemCatalog::TableName& tn,
                                CalpontSystemCatalog::TableAliasName& tan,
                                TABLE* table,
                                gp_walk_info& gwi)
...
    tcn = csc->colName(oidlist[minWidthColOffset].objnum);
    SimpleColumn* sc = new SimpleColumn(tcn.schema, tcn.table, tcn.column, csc->sessionID());
    sc->tableAlias(tan.alias);
    sc->viewName(tan.view);
    sc->timeZone(gwi.thd->variables.time_zone->get_name()->ptr());
    sc->resultType(csc->colType(oidlist[minWidthColOffset].objnum));
    sc->charsetNumber(3000);
    return sc;
}

This looks wrong. It should set charset ID either from my_charset_bin, or from the corresponding Field object.

It seems the problem was introduced by MCOL-3536.


Generated at Thu Feb 08 02:52:14 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.