2022-06-28 11:54 AM
I followed the steps to install the mongodb from the openSTLinux distribution.
when I run the mongodb from the terminal, it is crashing with the bus error.
root@stm32mp1:/usr/bin# mongod
Bus error (core dumped)
Appreciate your help..
Solved! Go to Solution.
2022-07-11 05:17 AM
@KMOHA.1
I confirm my initial guess after installing the mongodb package from the ecosystem-3.1:
root@stm32mp1:~# apt-cache policy mongodb
mongodb:
Installed: 4.2.2-r0
Candidate: 4.2.2-r0
Version table:
*** 4.2.2-r0 500
500 http://packages.openstlinux.st.com/3.1 dunfell/untested armhf Packages
100 /var/lib/dpkg/status
Before launching mongod:
root@stm32mp1:~# cat /proc/cpu/alignment
User: 0
System: 0 (0x0)
Skipped: 0
Half: 0
Word: 0
DWord: 0
Multi: 0
User faults: 2 (fixup)
Then after launching mongod:
root@stm32mp1:~# cat /proc/cpu/alignment
User: 1
System: 0 (0x0)
Skipped: 1
Half: 0
Word: 0
DWord: 0
Multi: 0
User faults: 2 (fixup)
The output of dmesg shows:
[ 211.231332] Alignment trap: not handling instruction f9660aef at [<016d8dca>]
[ 211.237169] 8<--- cut here ---
[ 211.240230] Unhandled fault: alignment exception (0x001) at 0xbeeb6aa8
[ 211.248709] pgd = f2925d3c
[ 211.249969] [beeb6aa8] *pgd=c58cc835, *pte=d9e1875f, *ppte=d9e18c7f
I think you should report a bug to the Mongod team.
Best regards,
--JM
2022-07-10 10:18 PM
Hi @KMOHA.1 ,
By steps do you means installing with apt-get from package repository or else ?
Can you specify OpenSTLinux version you use ?
Thanks
Olivier
2022-07-11 02:42 AM
Hi @KMOHA.1
Here, the «bus error» probably means unaligned data access.
By compiling the mongodb package with the compiler option «-Wcast-align=strict», I see a lot of conversion problems (see the attachment file extracted from the bitbake log.do_compile log). ARM devices are less tolerant than other architectures hence the crash.
Do you see anything related to an unaligned access in the /var/log/mongodb or other log files?
Best regards,
--JM
2022-07-11 05:17 AM
@KMOHA.1
I confirm my initial guess after installing the mongodb package from the ecosystem-3.1:
root@stm32mp1:~# apt-cache policy mongodb
mongodb:
Installed: 4.2.2-r0
Candidate: 4.2.2-r0
Version table:
*** 4.2.2-r0 500
500 http://packages.openstlinux.st.com/3.1 dunfell/untested armhf Packages
100 /var/lib/dpkg/status
Before launching mongod:
root@stm32mp1:~# cat /proc/cpu/alignment
User: 0
System: 0 (0x0)
Skipped: 0
Half: 0
Word: 0
DWord: 0
Multi: 0
User faults: 2 (fixup)
Then after launching mongod:
root@stm32mp1:~# cat /proc/cpu/alignment
User: 1
System: 0 (0x0)
Skipped: 1
Half: 0
Word: 0
DWord: 0
Multi: 0
User faults: 2 (fixup)
The output of dmesg shows:
[ 211.231332] Alignment trap: not handling instruction f9660aef at [<016d8dca>]
[ 211.237169] 8<--- cut here ---
[ 211.240230] Unhandled fault: alignment exception (0x001) at 0xbeeb6aa8
[ 211.248709] pgd = f2925d3c
[ 211.249969] [beeb6aa8] *pgd=c58cc835, *pte=d9e1875f, *ppte=d9e18c7f
I think you should report a bug to the Mongod team.
Best regards,
--JM
2022-07-11 06:56 AM
thanks Jean. I will check how we can report this to mongodb team.
2022-07-11 08:04 AM
For the record, same behavior with ecosystem-4.0.0:
mongodb:
Installed: 4.4.13-r0
Candidate: 4.4.13-r0
Version table:
*** 4.4.13-r0 500
500 http://packages.openstlinux.st.com/4.0 kirkstone/untested armhf Packages
100 /var/lib/dpkg/status