Demo server error

root@ubuntu:/home/mender-server/integration-3.7.2# ./demo up
Starting the Mender demo environment…
Creating network “integration372_mender” with the default driver
Creating integration372_mender-mongo_1 …
Creating integration372_mender-nats_1 …
Creating integration372_mender-gui_1 …
Creating integration372_mender-nats_1
Creating integration372_minio_1 …
Creating integration372_mender-mongo_1
Creating integration372_minio_1
Creating integration372_mender-mongo_1 … done
Creating integration372_mender-deviceconnect_1 …
Creating integration372_mender-useradm_1 …
Creating integration372_mender-create-artifact-worker_1 …
Creating integration372_mender-iot-manager_1 …
Creating integration372_mender-workflows-worker_1 …
Creating integration372_mender-workflows-server_1 …
Creating integration372_mender-create-artifact-worker_1
Creating integration372_mender-useradm_1
Creating integration372_mender-deviceconnect_1
Creating integration372_mender-workflows-worker_1
Creating integration372_mender-inventory_1 …
Creating integration372_mender-deviceconfig_1 …
Creating integration372_mender-inventory_1
Creating integration372_mender-iot-manager_1
Creating integration372_mender-workflows-server_1
Creating integration372_mender-gui_1 … done
Creating integration372_mender-deployments_1 …
Creating integration372_mender-workflows-server_1 … done
Creating integration372_mender-device-auth_1 …
Creating integration372_mender-device-auth_1 … done
Creating integration372_mender-api-gateway_1 …
Creating integration372_mender-api-gateway_1 … done
Waiting for services to become ready…
Creating a new user…
time=“2024-03-07T07:31:59Z” level=info msg=“loading plan definitions from configuration” caller=“main.doMain.func1@main.go:145”
docker exec error: 137

mender-deployments_1 | failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-deployments:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }
mender-create-artifact-worker_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-workflows-worker_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-deviceconnect_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-iot-manager_1 | time=“2024-03-07T08:26:41Z” level=fatal msg=“failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }”
mender-workflows-server_1 | 2024/03/07 08:26:41 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-useradm_1 | failed to connect to db: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-useradm:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }
mender-gui_1 | 127.0.0.1 - - [07/Mar/2024:08:26:42 +0000] “GET /ui/ HTTP/1.1” 200 869 “-” “Wget”
mender-device-auth_1 | failed to connect to db: failed to verify mongodb connection: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-device-auth:27017, Type: Unknown }, ] }
mender-gui_1 | 127.0.0.1 - - [07/Mar/2024:08:26:50 +0000] “GET /ui/ HTTP/1.1” 200 869 “-” “Wget”
integration372_mender-deployments_1 exited with code 3

mender-workflows-worker_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-workflows-worker_1 | 2024/03/07 08:26:53 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-deviceconnect_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-deviceconnect_1 | 2024/03/07 08:26:53 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-create-artifact-worker_1 | 2024/03/07 08:26:40 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-create-artifact-worker_1 | 2024/03/07 08:26:53 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }
mender-useradm_1 | time=“2024-03-07T08:26:31Z” level=info msg=“loading plan definitions from configuration” caller=“main.doMain.func1@main.go:145”
mender-useradm_1 | time=“2024-03-07T08:26:31Z” level=info msg=“User Administration Service starting up” caller=“main.runServer@main.go:178”
mender-useradm_1 | failed to connect to db: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-useradm:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }
mender-useradm_1 | time=“2024-03-07T08:26:44Z” level=info msg=“loading plan definitions from configuration” caller=“main.doMain.func1@main.go:145”
mender-useradm_1 | time=“2024-03-07T08:26:44Z” level=info msg=“User Administration Service starting up” caller=“main.runServer@main.go:178”
mender-useradm_1 | failed to connect to db: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-useradm:27017, Type: Unknown }, ] }
mender-useradm_1 | time=“2024-03-07T08:26:56Z” level=info msg=“loading plan definitions from configuration” caller=“main.doMain.func1@main.go:145”
mender-useradm_1 | time=“2024-03-07T08:26:56Z” level=info msg=“User Administration Service starting up” caller=“main.runServer@main.go:178”
mender-workflows-server_1 | 2024/03/07 08:26:41 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-workflows-server_1 | 2024/03/07 08:26:54 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-iot-manager_1 | time=“2024-03-07T08:26:41Z” level=fatal msg=“failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }”
mender-iot-manager_1 | time=“2024-03-07T08:26:53Z” level=fatal msg=“failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }”
mender-device-auth_1 | failed to connect to db: failed to verify mongodb connection: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-device-auth:27017, Type: Unknown }, ] }
mender-device-auth_1 | failed to connect to db: failed to verify mongodb connection: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-device-auth:27017, Type: Unknown }, ] }
mender-gui_1 | 127.0.0.1 - - [07/Mar/2024:08:26:58 +0000] “GET /ui/ HTTP/1.1” 200 869 “-” “Wget”
mender-inventory_1 | time=“2024-03-07T08:27:02Z” level=error msg=“mongo: error pinging mongo ‘server selection error: server selection timeout, current topology: { Type: Unknown, Servers: [{ Addr: mongo-inventory:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }’” caller=“mongo.NewDataStoreMongo.func1@datastore_mongo.go:147”
mender-inventory_1 | failed to connect to db: failed to open mongo-driver session
mender-deviceconfig_1 | time=“2024-03-07T08:27:02Z” level=fatal msg=“mongo: error reaching mongo server: server selection error: server selection timeout, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown, Last error: dial tcp 172.22.0.3:27017: i/o timeout }, ] }” caller=“main.doMain@main.go:108”
integration372_mender-deviceconfig_1 exited with code 0
mender-deployments_1 | failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-deployments:27017, Type: Unknown }, ] }
mender-workflows-worker_1 | 2024/03/07 08:27:05 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-deviceconnect_1 | 2024/03/07 08:27:05 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-create-artifact-worker_1 | 2024/03/07 08:27:05 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-iot-manager_1 | time=“2024-03-07T08:27:05Z” level=fatal msg=“failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }”
mender-gui_1 | 127.0.0.1 - - [07/Mar/2024:08:27:06 +0000] “GET /ui/ HTTP/1.1” 200 869 “-” “Wget”
mender-useradm_1 | failed to connect to db: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-useradm:27017, Type: Unknown }, ] }
mender-workflows-server_1 | 2024/03/07 08:27:06 failed to connect to db: Error reaching mongo server: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mender-mongo:27017, Type: Unknown }, ] }
mender-device-auth_1 | failed to connect to db: failed to verify mongodb connection: server selection error: context deadline exceeded, current topology: { Type: Unknown, Servers: [{ Addr: mongo-device-auth:27017, Type: Unknown }, ] }

Hi @PrimeQH,

Can you maybe share a little bit more context? Which release of Ubuntu, running on which platform, specifically RAM? Plus, why running under root?

Greetz,
Josef

Hi @TheYoctoJester
I have the exact same error. Following the directions Evaluation with Docker Compose | Mender documentation on a Ubuntu 22.04 desktop via ssh (headless). System settings are intel Celeron (2 CPU threads), 16GB RAM.

Exact output

~/mender_server/integration-3.7.7$ ./demo up
Starting the Mender demo environment...
[+] Running 15/16
 ⠸ Network integration377_mender                             Created                                                                                                                                                                                                         5.3s 
 ✔ Container integration377-mender-nats-1                    Started                                                                                                                                                                                                         1.5s 
 ✔ Container integration377-mender-mongo-1                   Started                                                                                                                                                                                                         1.0s 
 ✔ Container integration377-minio-1                          Healthy                                                                                                                                                                                                         3.2s 
 ✔ Container integration377-mender-gui-1                     Started                                                                                                                                                                                                         1.0s 
 ✔ Container integration377-mender-deviceconfig-1            Started                                                                                                                                                                                                         3.0s 
 ✔ Container integration377-mender-workflows-server-1        Started                                                                                                                                                                                                         3.3s 
 ✔ Container integration377-mender-iot-manager-1             Started                                                                                                                                                                                                         2.9s 
 ✔ Container integration377-mender-inventory-1               Started                                                                                                                                                                                                         2.6s 
 ✔ Container integration377-mender-deployments-1             Started                                                                                                                                                                                                         4.1s 
 ✔ Container integration377-mender-useradm-1                 Started                                                                                                                                                                                                         2.6s 
 ✔ Container integration377-mender-workflows-worker-1        Started                                                                                                                                                                                                         3.7s 
 ✔ Container integration377-mender-deviceconnect-1           Started                                                                                                                                                                                                         3.7s 
 ✔ Container integration377-mender-create-artifact-worker-1  Started                                                                                                                                                                                                         3.4s 
 ✔ Container integration377-mender-device-auth-1             Started                                                                                                                                                                                                         4.3s 
 ✔ Container integration377-mender-api-gateway-1             Started                                                                                                                                                                                                         5.0s 
Waiting for services to become ready...
Creating a new user...
time="2024-11-09T03:02:22Z" level=info msg="loading plan definitions from configuration" caller="main.doMain.func1@main.go:145"
docker exec error:  137

There are a couple of examples of the demo failing due to cpu architecture support such as sse4_2 Unable to start on-premise demo server per "Getting Started" instructions - #23 by 0lmi

This exact issue doesn’t seem to be the case as output of cat /proc/info seems to show support for sse4_2 in flags:

cat /proc/cpuinfo
processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 156
model name	: Intel(R) Celeron(R) N4505 @ 2.00GHz
stepping	: 0
microcode	: 0x24000026
cpu MHz		: 800.082
cache size	: 4096 KB
physical id	: 0
siblings	: 2
core id		: 0
cpu cores	: 2
apicid		: 0
initial apicid	: 0
fpu		: yes
fpu_exception	: yes
cpuid level	: 27
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 ss ht tm pbe syscall nx rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg cx16 xtpr pdcm sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave rdrand lahf_lm 3dnowprefetch cpuid_fault epb cat_l2 cdp_l2 ssbd ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust smep erms rdt_a rdseed smap clflushopt clwb intel_pt sha_ni xsaveopt xsavec xgetbv1 xsaves split_lock_detect dtherm ida arat pln pts hwp hwp_notify hwp_act_window hwp_epp hwp_pkg_req vnmi umip waitpkg gfni rdpid movdiri movdir64b md_clear flush_l1d arch_capabilities
vmx flags	: vnmi preemption_timer posted_intr invvpid ept_x_only ept_ad flexpriority apicv tsc_offset vtpr mtf vapic ept vpid unrestricted_guest vapic_reg vid ple shadow_vmcs ept_mode_based_exec tsc_scaling usr_wait_pause
bugs		: apic_c1e spectre_v1 spectre_v2 spec_store_bypass swapgs srbds mmio_stale_data bhi
bogomips	: 3993.60
clflush size	: 64
cache_alignment	: 64
address sizes	: 39 bits physical, 48 bits virtual
power management:

processor	: 1
vendor_id	: GenuineIntel
cpu family	: 6
model		: 156
model name	: Intel(R) Celeron(R) N4505 @ 2.00GHz
stepping	: 0
microcode	: 0x24000026
cpu MHz		: 789.349
cache size	: 4096 KB
physical id	: 0
siblings	: 2
core id		: 1
cpu cores	: 2
apicid		: 2
initial apicid	: 2
fpu		: yes
fpu_exception	: yes
cpuid level	: 27
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 ss ht tm pbe syscall nx rdtscp lm constant_tsc art arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc cpuid aperfmperf tsc_known_freq pni pclmulqdq dtes64 monitor ds_cpl vmx est tm2 ssse3 sdbg cx16 xtpr pdcm sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave rdrand lahf_lm 3dnowprefetch cpuid_fault epb cat_l2 cdp_l2 ssbd ibrs ibpb stibp ibrs_enhanced tpr_shadow flexpriority ept vpid ept_ad fsgsbase tsc_adjust smep erms rdt_a rdseed smap clflushopt clwb intel_pt sha_ni xsaveopt xsavec xgetbv1 xsaves split_lock_detect dtherm ida arat pln pts hwp hwp_notify hwp_act_window hwp_epp hwp_pkg_req vnmi umip waitpkg gfni rdpid movdiri movdir64b md_clear flush_l1d arch_capabilities
vmx flags	: vnmi preemption_timer posted_intr invvpid ept_x_only ept_ad flexpriority apicv tsc_offset vtpr mtf vapic ept vpid unrestricted_guest vapic_reg vid ple shadow_vmcs ept_mode_based_exec tsc_scaling usr_wait_pause
bugs		: apic_c1e spectre_v1 spectre_v2 spec_store_bypass swapgs srbds mmio_stale_data bhi
bogomips	: 3993.60
clflush size	: 64
cache_alignment	: 64
address sizes	: 39 bits physical, 48 bits virtual
power management:


However following the instructions on a different machine corei9, the getting demo server works as per the documentation and generates a user.

Hello @petermilani80 :wave:

I believe MongoDB might be the issue; starting from version 5.0, MongoDB requires the AVX instruction set for x86_64. Although I would not recommend running software out of a support, the only workaround I think could make it work would be downgrading MongoDB (services.mender-mongo.image in docker-compose.yml) to 4.4. Please keep in mind that this version has been out of support since February this year and won’t receive any further updates.

2 Likes