Docker Community Forums

Share and learn in the Docker community.

Mongo:latest does not start on missing sse4_2

Good evening,

I’m using Docker Desktop on Windows as well as Docker on Debian and Ubuntu.
Up to last week I was running a MongoDB-server (version 4.4.6) with success on all my machines (1x Windows, 1x Debian, 1x Ubuntu).
Now I tried to switch to mongo:latest which was successful on the Windows-machine and the Debian-machine but not on the Ubuntu-machine - it exits/restarts every some seconds with status 132.
After checking with Google it seems that my older Ubuntu-notebook is missing sse4_2-support as seen on the following (partial - only for one of the two cores) output of cat /proc/cpuinfo

processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 23
model name      : Intel(R) Core(TM)2 Duo CPU     P8600  @ 2.40GHz
stepping        : 10
microcode       : 0xa0b
cpu MHz         : 985.009
cache size      : 3072 KB
physical id     : 0
siblings        : 2
core id         : 0
cpu cores       : 2
apicid          : 0
initial apicid  : 0
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ht tm pbe syscall nx lm constant_tsc arch_perfmon pebs bts nopl cpuid aperfmperf pni dtes64 monitor ds_cpl vmx smx est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm pti tpr_shadow vnmi flexpriority dtherm ida
bugs            : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf mds swapgs itlb_multihit
bogomips        : 4788.27
clflush size    : 64
cache_alignment : 64
address sizes   : 36 bits physical, 48 bits virtual
power management:

I am using the following docker-compose.yml

version: '3.1'
services:
  mongo:
    image: mongo:latest
    restart: unless-stopped
    ports:
      - 27017:27017
    environment:
      MONGO_INITDB_ROOT_USERNAME: ***
      MONGO_INITDB_ROOT_PASSWORD: ***
    network_mode: bridge
    volumes:
      - data:/data/db
volumes:
  data:

Yeah, I know that I should not use :latest-images - but IMHO it is OK in a test-environment - that is what test-environments are for :-).
So I have to buy a new Notebook for testing when every other docker-image in use (nginx, php:7.4-fpm, redis, mysql, mariadb, node:current-alpine, memcached, postgres, …) is starting flawless?
Or is it something the creators of the official mongodb-docker-image can do?

Thank you and best regards
Matthias

So you found some explanation stating that this is the cause? Details, please?

Did you also see Mongo 5.0.0 crashes on Debian but 4.4.6 works fine · Issue #485 · docker-library/mongo · GitHub? If that matches your problem, and if you found other resources saying it’s related to missing sse4_2-support, then maybe comment about that (with references) at that GitHub issue?

Why do you think the problem is related to that? It’s just that today :latest will be some 5.x version; using a specific 5.x version should give you the very same problem.

Good morning,

You are absolutely right - the problem is not related to :latest but to the 5.x-version.
“Do not run :latest-images in productive environments - use specific versions that you have tested successful on your test-servers” was one mantra I have learned in a training to avoid incompatibilities or other problems that might arise with using the :latest version on productive systems.

What made me think that the will-not-start-with-code-132 relates to the older CPU (Core2Duo P8600) in my Ubuntu-test-notebook (in comparison to a Core i5-4310m in the Windows-notebook and a AMD Ryzen Threadripper 1920X 12-Core in the Debian-box) are the following two links (among others)

What I have tried was using gdb:

root@5f09ddb07e92:/# gdb /usr/bin/mongod
GNU gdb (Ubuntu 9.2-0ubuntu1~20.04) 9.2
Copyright (C) 2020 Free Software Foundation, Inc.
[...]
Reading symbols from /usr/bin/mongod...
(No debugging symbols found in /usr/bin/mongod)
(gdb) run
Starting program: /usr/bin/mongod
warning: Error disabling address space randomization: Operation not permitted
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".

Program received signal SIGILL, Illegal instruction.
0x0000564f3ca21cda in tcmalloc::SizeMap::Init() ()
(gdb)

But now I don’t know how to proceed further…

Thanks - I haven’t found this yet. Now I have added a comment with my suspicions to that thread.

1 Like