BemiHQ / BemiDB

Postgres read replica optimized for analytics
https://bemidb.com
GNU Affero General Public License v3.0
1.1k stars 21 forks source link

Immediate crash after running bemidb start, Mac OSX Sonoma 14.2, M2 Max #1

Closed georgeashworth closed 2 weeks ago

georgeashworth commented 3 weeks ago

Tried to install and run today after seeing post on HN, got this crash.

I am very curious about BemiDB, (I am literally the "average user" you described in your post, I work at a startup and have a PG read replica for analytics that is running too slow)

➜ curl -sSL https://raw.githubusercontent.com/BemiHQ/BemiDB/refs/heads/main/scripts/install.sh | bash
➜ ./bemidb start
dyld[94522]: Library not loaded: /nix/store/gd2wv2206pw1n6ddi2siy4y6vdrq2b6g-libcxx-11.1.0/lib/libc++.1.0.dylib
  Referenced from: <no uuid> /Users/g/bemidb
  Reason: tried: '/nix/store/gd2wv2206pw1n6ddi2siy4y6vdrq2b6g-libcxx-11.1.0/lib/libc++.1.0.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/nix/store/gd2wv2206pw1n6ddi2siy4y6vdrq2b6g-libcxx-11.1.0/lib/libc++.1.0.dylib' (no such file), '/nix/store/gd2wv2206pw1n6ddi2siy4y6vdrq2b6g-libcxx-11.1.0/lib/libc++.1.0.dylib' (no such file), '/usr/local/lib/libc++.1.0.dylib' (no such file), '/usr/lib/libc++.1.0.dylib' (no such file, not in dyld cache)
zsh: abort      ./bemidb start
rileygelwicks commented 3 weeks ago

same issue on 15.1 M1 Pro

arjunlol commented 3 weeks ago

Thanks for opening this issue. We're taking a look!

meetmauro commented 3 weeks ago

you can bypass this by doing:

install_name_tool -change /nix/store/gd2wv2206pw1n6ddi2siy4y6vdrq2b6g-libcxx-11.1.0/lib/libc++.1.0.dylib /opt/homebrew/Cellar/llvm/18.1.7/lib/c++/libc++.1.0.dylib ./bemidb

just make sure you have installed llvm, xcode and the second path is the correct one

exAspArk commented 2 weeks ago

Thank you for submitting this issue and leaving your comments!

This should be resolved now if you re-download BemiDB https://github.com/BemiHQ/BemiDB#quickstart

TL;DR

whygee-dev commented 2 weeks ago

Facing a similar error using 0.2.0

dyld[8208]: Library not loaded: /nix/store/alpyb4jjlfmajljzv567p31xa309axb6-libcxxabi-11.1.0/lib/libc++abi.1.dylib
  Referenced from: <no uuid> /usr/local/lib/libc++.1.0.dylib
  Reason: tried: '/nix/store/alpyb4jjlfmajljzv567p31xa309axb6-libcxxabi-11.1.0/lib/libc++abi.1.dylib' (no such file), '/System/Volumes/Preboot/Cryptexes/OS/nix/store/alpyb4jjlfmajljzv567p31xa309axb6-libcxxabi-11.1.0/lib/libc++abi.1.dylib' (no such file), '/nix/store/alpyb4jjlfmajljzv567p31xa309axb6-libcxxabi-11.1.0/lib/libc++abi.1.dylib' (no such file), '/usr/local/lib/libc++abi.1.dylib' (no such file), '/usr/lib/libc++abi.1.dylib' (no such file, not in dyld cache)
exAspArk commented 2 weeks ago

Got it, thank you. Would you be able to install the latest v0.3.1 and try again?

> ./bemidb version
BemiDB version: 0.3.1
whygee-dev commented 2 weeks ago

@exAspArk seems to work thank you

A different issue, I'll prolly create another issue when I have some time, is that sync is not using quotes for tables, leading to failure for tables having uppercase characters

[INFO] Syncing public.User...
panic: ERROR: relation "public.user" does not exist (SQLSTATE 42P01)
exAspArk commented 2 weeks ago

@whygee-dev — thank you!

tables having uppercase characters

This should also be fixed in the latest version 🙏