turbot / steampipe

Zero-ETL, infinite possibilities. Live query APIs, code & more with SQL. No DB required.
https://steampipe.io
GNU Affero General Public License v3.0
6.67k stars 262 forks source link

[ARM64 OCI CloudShell] Initializing database... FAILED! #4253

Closed LaughingBubba closed 2 months ago

LaughingBubba commented 2 months ago

Describe the bug After a clean install of steampipe and steampipe plugin, running the default query example fails with the above error. This only occurs on ARM based shells. Works fine using the X86_64 version of the shell (with X86_64 version of the steampipe binary).

Steampipe version (steampipe -v) v0.22.2

To reproduce Below is from my ARM OCI CloudShell.

joseph_szi@cloudshell:~ (ap-melbourne-1)$ steampipe -v
Steampipe v0.22.2

joseph_szi@cloudshell:~ (ap-melbourne-1)$ export STEAMPIPE_LOG=trace

joseph_szi@cloudshell:~ (ap-melbourne-1)$ steampipe plugin install steampipe
Installed plugin: steampipe@latest v0.10.0
Documentation:    https://hub.steampipe.io/plugins/turbot/steampipe

joseph_szi@cloudshell:~ (ap-melbourne-1)$ steampipe query "select name from steampipe_registry_plugin;"
Error: Initializing database... FAILED!

joseph_szi@cloudshell:~ (ap-melbourne-1)$ whereis libssl.so.1.0.0
libssl.so.1.0: /usr/lib64/libssl.so.1.0.2k

joseph_szi@cloudshell:~ (ap-melbourne-1)$ lscpu
Architecture:          aarch64
Byte Order:            Little Endian
CPU(s):                2
On-line CPU(s) list:   0,1
Thread(s) per core:    1
Core(s) per socket:    2
Socket(s):             1
NUMA node(s):          1
Model:                 1
BogoMIPS:              50.00
L1d cache:             unknown size
L1i cache:             unknown size
L2 cache:              unknown size
NUMA node0 CPU(s):     0,1
Flags:                 fp asimd evtstrm aes pmull sha1 sha2 crc32 atomics fphp asimdhp cpuid asimdrdm lrcpc dcpop asimddp ssbs
joseph_szi@cloudshell:~ (ap-melbourne-1)$ 

Expected behavior A listing of the steampipe registry.

Additional context The logs indicate a problem is error while loading shared libraries: libssl.so.1.0.0: ELF load command alignment not page-aligned

Would be good to know if this is a problem with Oracles enterprise linux or the steampipe image.

steampipe-2024-04-24.log

pskrbasu commented 2 months ago

Hi @LaughingBubba Steampipe does work properly on Linux ARM systems.

Your error libssl.so.1.0.0: ELF load command alignment not page-aligned seems to me more like an OpenSSL library file issue. Can you make sure the file isn't corrupted? You can do this by reinstalling the OpenSSL package or the package that provides libssl.so.1.0.0 on your system.

After that can you try re-installing steampipe to see if that works?

Thanks

LaughingBubba commented 2 months ago

@pskrbasu OCI cloudshell is locked down, but thanks for confirming it works on ARM. Now its time to hassle my Oracle colleagues for a fix.