* [Buildroot] MariaDB 11 for buildroot
@ 2025-08-25 15:32 Horst Noecker via buildroot
0 siblings, 0 replies; 5+ messages in thread
From: Horst Noecker via buildroot @ 2025-08-25 15:32 UTC (permalink / raw)
To: buildroot
[-- Attachment #1.1: Type: text/plain, Size: 2511 bytes --]
Dear Buildroot community,
I'm trying to build MariaDB 11.4.8 with Buildroot for Aarch64 for a
RasPi4 / Compute Module 4.
I've been doing this all the time by downloading the sources,
configuring it with cmake-gui, using the toolchain built by buildroot,
build it and put the binaries, libs, etc. into an overlay being then
packaged into the image by buildroot.
That worked fine for years - also with MariaDB 11.4.x. - but only for
Arm32 (ARMv7a, gnueabihf, etc. etc.). For Aarch64 the only version that
works is the latest 10.11.11.
I've also tried to adapt the mariadb-package from buildroot to have it
build inside by builtroot itself.
The build itself works for Arm32 and AArch64.
BUT: no matter what I do, when trying to start mariadbd (i.e. the
server) it gives a segmentation fault without any further hint (in the
log file it only states that it started and immediately stopped).
If anybody has any clue that would be awesome!
Kind regards,
Horst
--
bar
Horst Noecker
- Geschäftsführer -
Logo
CellOmation GmbH & Co. KG
www.cellomation.de <http://www.cellomation.de/>
- Stammsitz -
Staufenstr. 1
63128 Dietzenbach
Mobil: +49 160 5 30 26 48
Horst.Noecker@cellomation.de
HRA Nr.: 41648
USt-IdNr.: DE280920848
Gerichtsstand: Amtsgericht Offenbach
bar
Diese Information ist ausschliesslich fuer den Adressaten bestimmt und
kann vertraulich oder gesetzlich
geschuetzte Informationen enthalten. Wenn Sie nicht der
bestimmungsgemaesse Adressat sind, unterrichten
Sie bitte den Absender und vernichten Sie diese Mail. Anderen als dem
bestimmungsgemaessen Adressaten
ist es untersagt, diese E-Mail zu lesen, zu speichern, weiterzuleiten
oder ihren Inhalt auf welche Weise auch
immer zu verwenden. Wir verwenden aktuelle Virenschutzprogramme. Fuer
Schaeden, die dem Empfaenger
gleichwohl durch von uns zugesandte mit Viren befallene E-Mails
entstehen, schliessen wir jede Haftung aus.
The information contained in this email is intended only for its
addressee and may contain confidential and/or
privileged information. If the reader of this email is not the intended
recipient, you are hereby notified that
reading, saving, distribution or use of the content of this email in any
way is prohibited. If you have received
this email in error, please notify the sender and delete the email. We
use updated antivirus protection software
We do not accept any responsibility for damages caused anyhow by viruses
transmitted via email.
[-- Attachment #1.2.1: Type: text/html, Size: 4125 bytes --]
[-- Attachment #1.2.2: bar.jpg --]
[-- Type: image/jpeg, Size: 1646 bytes --]
[-- Attachment #1.2.3: CellOmationLogo.jpg --]
[-- Type: image/jpeg, Size: 23244 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] MariaDB 11 for buildroot
[not found] <mailman.73751.1756165330.2108631.buildroot@buildroot.org>
@ 2025-08-26 6:59 ` Andreas Ziegler
2025-08-26 7:23 ` Nicolas Cavallari
0 siblings, 1 reply; 5+ messages in thread
From: Andreas Ziegler @ 2025-08-26 6:59 UTC (permalink / raw)
To: Horst Noecker; +Cc: buildroot
Hi Horst,
On 2025-08-25 17:32, Horst Noecker wrote:
>
> Dear Buildroot community,
>
>
> I'm trying to build MariaDB 11.4.8 with Buildroot for Aarch64 for a
> RasPi4 / Compute Module 4.
>
> I've been doing this all the time by downloading the sources,
> configuring it with cmake-gui, using the toolchain built by buildroot,
> build it and put the binaries, libs, etc. into an overlay being then
> packaged into the image by buildroot.
>
> That worked fine for years - also with MariaDB 11.4.x. - but only for
> Arm32 (ARMv7a, gnueabihf, etc. etc.). For Aarch64 the only version that
> works is the latest 10.11.11.
>
> I've also tried to adapt the mariadb-package from buildroot to have it
> build inside by builtroot itself.
>
> The build itself works for Arm32 and AArch64.
>
> BUT: no matter what I do, when trying to start mariadbd (i.e. the
> server) it gives a segmentation fault without any further hint (in the
> log file it only states that it started and immediately stopped).
>
>
> If anybody has any clue that would be awesome!
>
Which standard library do you use? MariaDB is a C++ project and uClibc
does not fully implement thread local storage on Aarch64, which is used
by C++ exception handling. C code works, C++ code dies with SIGSEGV on
the first try/catch block. musl functions correctly and glibc should
work.
Kind regards,
Andreas
>
> Kind regards,
>
> Horst
<cut>
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] MariaDB 11 for buildroot
2025-08-26 6:59 ` Andreas Ziegler
@ 2025-08-26 7:23 ` Nicolas Cavallari
2025-08-27 15:54 ` Horst Noecker via buildroot
0 siblings, 1 reply; 5+ messages in thread
From: Nicolas Cavallari @ 2025-08-26 7:23 UTC (permalink / raw)
To: Andreas Ziegler, Horst Noecker; +Cc: buildroot
On 26/08/2025 08:59, Andreas Ziegler wrote:
> Hi Horst,
>
> On 2025-08-25 17:32, Horst Noecker wrote:
>>
>> Dear Buildroot community,
>>
>>
>> I'm trying to build MariaDB 11.4.8 with Buildroot for Aarch64 for a
>> RasPi4 / Compute Module 4.
>>
>> I've been doing this all the time by downloading the sources,
>> configuring it with cmake-gui, using the toolchain built by buildroot,
>> build it and put the binaries, libs, etc. into an overlay being then
>> packaged into the image by buildroot.
>>
>> That worked fine for years - also with MariaDB 11.4.x. - but only for
>> Arm32 (ARMv7a, gnueabihf, etc. etc.). For Aarch64 the only version that
>> works is the latest 10.11.11.
>>
>> I've also tried to adapt the mariadb-package from buildroot to have it
>> build inside by builtroot itself.
>>
>> The build itself works for Arm32 and AArch64.
>>
>> BUT: no matter what I do, when trying to start mariadbd (i.e. the
>> server) it gives a segmentation fault without any further hint (in the
>> log file it only states that it started and immediately stopped).
>>
>>
>> If anybody has any clue that would be awesome!
>>
>
> Which standard library do you use? MariaDB is a C++ project and uClibc
> does not fully implement thread local storage on Aarch64, which is used
> by C++ exception handling. C code works, C++ code dies with SIGSEGV on
> the first try/catch block. musl functions correctly and glibc should work.
It is more complicated than that IIRC: uclibc-ng implements thread local
storage, but GCC has optimizations that assumes that the thread local
storage implementation works like glibc. And unlike for other
architectures where the requirements are spelled out¹, what GCC expects
from the arm/aarch64 TLS implementation is not documented.
Also, errno in C uses thread local storage and C11 programs can also use
thread local storage, so C programs are not immune.
[1]: https://uclibc.org/docs/tls.pdf
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] MariaDB 11 for buildroot
2025-08-26 7:23 ` Nicolas Cavallari
@ 2025-08-27 15:54 ` Horst Noecker via buildroot
2025-08-29 13:43 ` Andreas Ziegler
0 siblings, 1 reply; 5+ messages in thread
From: Horst Noecker via buildroot @ 2025-08-27 15:54 UTC (permalink / raw)
To: Nicolas Cavallari, Andreas Ziegler; +Cc: buildroot
[-- Attachment #1.1: Type: text/plain, Size: 3801 bytes --]
Dear Andreas and Nicolas,
I'm using glibc.
Furthermore: Maria 10.11.11 and 11.4.8 work with arm32 - Maria 10.11.11
works with aarch64 and only Maria 11.4.8 (and 11.8.2 and 11.4.7) give a
sigsegv when trying to start.
Am 26.08.25 um 09:23 schrieb Nicolas Cavallari:
> On 26/08/2025 08:59, Andreas Ziegler wrote:
>> Hi Horst,
>>
>> On 2025-08-25 17:32, Horst Noecker wrote:
>>>
>>> Dear Buildroot community,
>>>
>>>
>>> I'm trying to build MariaDB 11.4.8 with Buildroot for Aarch64 for a
>>> RasPi4 / Compute Module 4.
>>>
>>> I've been doing this all the time by downloading the sources,
>>> configuring it with cmake-gui, using the toolchain built by buildroot,
>>> build it and put the binaries, libs, etc. into an overlay being then
>>> packaged into the image by buildroot.
>>>
>>> That worked fine for years - also with MariaDB 11.4.x. - but only for
>>> Arm32 (ARMv7a, gnueabihf, etc. etc.). For Aarch64 the only version that
>>> works is the latest 10.11.11.
>>>
>>> I've also tried to adapt the mariadb-package from buildroot to have it
>>> build inside by builtroot itself.
>>>
>>> The build itself works for Arm32 and AArch64.
>>>
>>> BUT: no matter what I do, when trying to start mariadbd (i.e. the
>>> server) it gives a segmentation fault without any further hint (in the
>>> log file it only states that it started and immediately stopped).
>>>
>>>
>>> If anybody has any clue that would be awesome!
>>>
>>
>> Which standard library do you use? MariaDB is a C++ project and
>> uClibc does not fully implement thread local storage on Aarch64,
>> which is used by C++ exception handling. C code works, C++ code dies
>> with SIGSEGV on the first try/catch block. musl functions correctly
>> and glibc should work.
>
> It is more complicated than that IIRC: uclibc-ng implements thread
> local storage, but GCC has optimizations that assumes that the thread
> local storage implementation works like glibc. And unlike for other
> architectures where the requirements are spelled out¹, what GCC
> expects from the arm/aarch64 TLS implementation is not documented.
>
> Also, errno in C uses thread local storage and C11 programs can also
> use thread local storage, so C programs are not immune.
>
> [1]: https://uclibc.org/docs/tls.pdf
>
--
bar
Horst Noecker
- Geschäftsführer -
Logo
CellOmation GmbH & Co. KG
www.cellomation.de <http://www.cellomation.de/>
- Stammsitz -
Staufenstr. 1
63128 Dietzenbach
Mobil: +49 160 5 30 26 48
Horst.Noecker@cellomation.de
HRA Nr.: 41648
USt-IdNr.: DE280920848
Gerichtsstand: Amtsgericht Offenbach
bar
Diese Information ist ausschliesslich fuer den Adressaten bestimmt und
kann vertraulich oder gesetzlich
geschuetzte Informationen enthalten. Wenn Sie nicht der
bestimmungsgemaesse Adressat sind, unterrichten
Sie bitte den Absender und vernichten Sie diese Mail. Anderen als dem
bestimmungsgemaessen Adressaten
ist es untersagt, diese E-Mail zu lesen, zu speichern, weiterzuleiten
oder ihren Inhalt auf welche Weise auch
immer zu verwenden. Wir verwenden aktuelle Virenschutzprogramme. Fuer
Schaeden, die dem Empfaenger
gleichwohl durch von uns zugesandte mit Viren befallene E-Mails
entstehen, schliessen wir jede Haftung aus.
The information contained in this email is intended only for its
addressee and may contain confidential and/or
privileged information. If the reader of this email is not the intended
recipient, you are hereby notified that
reading, saving, distribution or use of the content of this email in any
way is prohibited. If you have received
this email in error, please notify the sender and delete the email. We
use updated antivirus protection software
We do not accept any responsibility for damages caused anyhow by viruses
transmitted via email.
[-- Attachment #1.2.1: Type: text/html, Size: 6376 bytes --]
[-- Attachment #1.2.2: bar.jpg --]
[-- Type: image/jpeg, Size: 1646 bytes --]
[-- Attachment #1.2.3: CellOmationLogo.jpg --]
[-- Type: image/jpeg, Size: 23244 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] MariaDB 11 for buildroot
2025-08-27 15:54 ` Horst Noecker via buildroot
@ 2025-08-29 13:43 ` Andreas Ziegler
0 siblings, 0 replies; 5+ messages in thread
From: Andreas Ziegler @ 2025-08-29 13:43 UTC (permalink / raw)
To: Horst Noecker; +Cc: buildroot
Dear Horst, Nicolas, All,
I ran some tests using the 'stable' mariadb versions on a rather ancient
RPi 4 (Rev1.3). The daemon starts, but aborts due to missing
configurations and not enough space on the root filesystem. Log entries
for the versions were fairly consistent (example below).
The system is headless, rather bleeding-edge, and uses musl as standard
library ...
On 2025-08-27 15:54, Horst Noecker wrote:
> Dear Andreas and Nicolas,
>
>
> I'm using glibc.
>
> Furthermore: Maria 10.11.11 and 11.4.8 work with arm32 - Maria 10.11.11
> works with aarch64 and only Maria 11.4.8 (and 11.8.2 and 11.4.7) give a
> sigsegv when trying to start.
>
stable release smoke test results
10.11.14 OK
11.4.8 OK
11.8.3 OK
12.0.2 OK
Some patches were necessary for the build:
all: missing header file
11,12: try_run used in CMAKE_CROSSCOMPILING mode
remove COLUMNSTORE from host build (see also [1])
The interesting parts of the defconfig:
BR2_aarch64=y
BR2_cortex_a72=y
BR2_TOOLCHAIN_BUILDROOT_MUSL=y
BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_6_16=y
BR2_BINUTILS_VERSION_2_44_X=y
BR2_GCC_VERSION_15_X=y
BR2_TOOLCHAIN_BUILDROOT_CXX=y
# BR2_PIC_PIE is not set
BR2_SSP_NONE=y
BR2_RELRO_NONE=y
...
BR2_PACKAGE_MARIADB=y
BR2_PACKAGE_MARIADB_SERVER=y
Kernel: 6.17.0-rc3-rt1
Init system: Busybox w/ mdev
Start sequence:
[nabla]# /etc/init.d/S97mysqld start
Starting mysql ... FAIL
[nabla]# cat /tmp/mysql/mysqld.log
250829 11:42:07 mysqld_safe Starting mariadbd daemon with databases from
/var/lib/mysql
2025-08-29 11:42:07 0 [Note] Starting MariaDB 12.0.2-MariaDB source
revision aab83aecdca15738d114cf5a2f223f1d12e4e6bd server_uid
BwSs9p0iC7M6snGTru568oZhReU= as process 790
2025-08-29 11:42:07 0 [ERROR] mariadbd: File
'/var/lib/mysql/aria_log_control' not found (Errcode: 13 "Permission
denied")
2025-08-29 11:42:07 0 [ERROR] mariadbd: Got error 'Can't open file' when
trying to use aria control file '/var/lib/mysql/aria_log_control'
2025-08-29 11:42:07 0 [ERROR] Plugin 'Aria' registration as a STORAGE
ENGINE failed.
2025-08-29 11:42:07 0 [Note] InnoDB: The first data file './ibdata1' did
not exist. A new tablespace will be created!
2025-08-29 11:42:07 0 [Note] InnoDB: Compressed tables use zlib 1.3.1
2025-08-29 11:42:07 0 [Note] InnoDB: Number of transaction pools: 1
2025-08-29 11:42:07 0 [Note] InnoDB: Using ARMv8 crc32 instructions
2025-08-29 11:42:07 0 [Note] InnoDB: Using Linux native AIO
2025-08-29 11:42:07 0 [Note] InnoDB: innodb_buffer_pool_size_max=128m,
innodb_buffer_pool_size=128m
2025-08-29 11:42:07 0 [Note] InnoDB: Completed initialization of buffer
pool
2025-08-29 11:42:07 0 [Note] InnoDB: Setting file './ibdata1' size to
12.000MiB. Physically writing the file full; Please wait ...
2025-08-29 11:42:07 0 [Note] InnoDB: File './ibdata1' size is now
12.000MiB.
2025-08-29 11:42:07 0 [ERROR] InnoDB: preallocating 100663296 bytes for
file ./ib_logfile101 failed with error 28
2025-08-29 11:42:07 0 [ERROR] InnoDB: Cannot set log file
./ib_logfile101 size to 96.000MiB
2025-08-29 11:42:07 0 [ERROR] InnoDB: Database creation was aborted with
error Generic error. You may need to delete the ibdata1 file before
trying to start up again.
2025-08-29 11:42:07 0 [Note] InnoDB: Starting shutdown...
2025-08-29 11:42:07 0 [ERROR] Plugin 'InnoDB' registration as a STORAGE
ENGINE failed.
2025-08-29 11:42:07 0 [Note] Plugin 'FEEDBACK' is disabled.
2025-08-29 11:42:07 0 [Note] Plugin 'wsrep-provider' is disabled.
2025-08-29 11:42:07 0 [ERROR] Could not open mysql.plugin table: "Table
'mysql.plugin' doesn't exist". Some plugins may be not loaded
2025-08-29 11:42:07 0 [ERROR] Failed to initialize plugins.
2025-08-29 11:42:07 0 [ERROR] Aborting
250829 11:42:07 mysqld_safe mysqld from pid file /run/mysql/mysqld.pid
ended
I am not aware that CM4 has major differences to a standard Pi4. Do you
have any exotic packages in your configuration?
Kind regards,
Andreas
>
> Am 26.08.25 um 09:23 schrieb Nicolas Cavallari:
>> On 26/08/2025 08:59, Andreas Ziegler wrote:
>>> Hi Horst,
>>>
>>> On 2025-08-25 17:32, Horst Noecker wrote:
>>>>
>>>> Dear Buildroot community,
>>>>
>>>>
>>>> I'm trying to build MariaDB 11.4.8 with Buildroot for Aarch64 for a
>>>> RasPi4 / Compute Module 4.
>>>>
>>>> I've been doing this all the time by downloading the sources,
>>>> configuring it with cmake-gui, using the toolchain built by
>>>> buildroot,
>>>> build it and put the binaries, libs, etc. into an overlay being then
>>>> packaged into the image by buildroot.
>>>>
>>>> That worked fine for years - also with MariaDB 11.4.x. - but only
>>>> for
>>>> Arm32 (ARMv7a, gnueabihf, etc. etc.). For Aarch64 the only version
>>>> that
>>>> works is the latest 10.11.11.
>>>>
>>>> I've also tried to adapt the mariadb-package from buildroot to have
>>>> it
>>>> build inside by builtroot itself.
>>>>
>>>> The build itself works for Arm32 and AArch64.
>>>>
>>>> BUT: no matter what I do, when trying to start mariadbd (i.e. the
>>>> server) it gives a segmentation fault without any further hint (in
>>>> the
>>>> log file it only states that it started and immediately stopped).
>>>>
>>>>
>>>> If anybody has any clue that would be awesome!
>>>>
>>>
>>> Which standard library do you use? MariaDB is a C++ project and
>>> uClibc does not fully implement thread local storage on Aarch64,
>>> which is used by C++ exception handling. C code works, C++ code dies
>>> with SIGSEGV on the first try/catch block. musl functions correctly
>>> and glibc should work.
>>
>> It is more complicated than that IIRC: uclibc-ng implements thread
>> local storage, but GCC has optimizations that assumes that the thread
>> local storage implementation works like glibc. And unlike for other
>> architectures where the requirements are spelled out¹, what GCC
>> expects from the arm/aarch64 TLS implementation is not documented.
>>
>> Also, errno in C uses thread local storage and C11 programs can also
>> use thread local storage, so C programs are not immune.
>>
>> [1]: https://uclibc.org/docs/tls.pdf
[2]
https://patchwork.ozlabs.org/project/buildroot/patch/20250829111210.1669283-1-thomas.petazzoni@bootlin.com/
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-08-29 13:52 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-25 15:32 [Buildroot] MariaDB 11 for buildroot Horst Noecker via buildroot
[not found] <mailman.73751.1756165330.2108631.buildroot@buildroot.org>
2025-08-26 6:59 ` Andreas Ziegler
2025-08-26 7:23 ` Nicolas Cavallari
2025-08-27 15:54 ` Horst Noecker via buildroot
2025-08-29 13:43 ` Andreas Ziegler
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.