-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
loadmodule Failed #16
Comments
Hi @LHM69
I haven't met this problem before. It seems that your system doesn't have zlib installed. You can try installing zlib. Then restart Redis server to load redis-protobuf. If it still doesn't work, you can recompile protobuf and redis-protobuf after installing zlib. redis-protobuf doesn't need zlib, however, protobuf needs zlib. If your system doesn't have zlib, it should fail to build. Are you running redis-protobuf on a different machine other than the one you build Redis-protobuf? If you do, you should install zlib on the machine where you run redis-protobuf. If you still have any problem with it, feel free to let me know. Regards |
I didCMakeLists.txtfind_library(PROTOBUF_LIB libprotobuf.a)
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
target_link_libraries(${SHARED_LIB} -Wl,-force_load ${PROTOBUF_LIB})
target_link_libraries(${SHARED_LIB} z)
else()
target_link_libraries(${SHARED_LIB} -Wl,--whole-archive ${PROTOBUF_LIB} -Wl,--no-whole-archive)
endif() to find_library(PROTOBUF_LIB libprotobuf.a)
if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
target_link_libraries(${SHARED_LIB} -Wl,-force_load ${PROTOBUF_LIB})
target_link_libraries(${SHARED_LIB} z)
else()
target_link_libraries(${SHARED_LIB} -Wl,--whole-archive ${PROTOBUF_LIB} -Wl,--no-whole-archive)
target_link_libraries(${SHARED_LIB} z) # here
endif() redis logs36813:M 06 Mar 2020 10:29:57.934 * Module 'ReJSON' loaded from /usr/local/lib/rejson.so
36813:M 06 Mar 2020 10:29:57.952 # <PB> failed to get file status: /home/aicrobo/.redis/proto
36813:M 06 Mar 2020 10:29:57.952 # Module /usr/local/lib/libredis-protobuf.so initialization failed. Module not loaded
36813:M 06 Mar 2020 10:29:57.952 # Can't load module from /usr/local/lib/libredis-protobuf.so: server aborting redis.conf
loadmodule /usr/local/lib/libredis-protobuf.so --DIR /home/aicrobo/.redis/proto to loadmodule /usr/local/lib/libredis-protobuf.so --dir /usr/lib/redis/proto resis logs38236:M 06 Mar 2020 10:53:29.299 # <ReJSON> JSON data type for Redis v1.0.4 [encver 0]
38236:M 06 Mar 2020 10:53:29.299 * Module 'ReJSON' loaded from /usr/local/lib/rejson.so
38236:M 06 Mar 2020 10:53:29.319 * Module 'PB' loaded from /usr/local/lib/libredis-protobuf.so
38236:M 06 Mar 2020 10:53:29.319 * DB loaded from disk: 0.000 seconds
38236:M 06 Mar 2020 10:53:29.319 * Ready to accept connections Now works correctly, thanks |
Hi @LHM69
I cannot reproduce the problem with Ubuntu 18.04, and if I add I'll add a link to this issue, if others have the same problem they can try your solution. Thanks a lot!
I think the reason is that the user running Redis do not have permission on Thanks again for your work! Regards |
Hi @sewenew , I was trying to download and install redis-protobuf. I have no issue till cmake but make is not successful. Let me know if you have any input. root@frcu32-1-5:/home/jthagaraja/redis-protobuf# ls -lrt root@frcu32-1-5:/home/jthagaraja/redis-protobuf/compile# make |
Is something wrong with the source code ? or am i missing any steps. Please let me know @sewenew Thanks in advance. |
that error has been resolved but still i see not able to load the generated protobuf.so file. 3795241:M 09 Aug 2024 12:58:07.553 # Module /home/jthagaraja/redis-protobuf-0.1.0/compile/libredis-protobuf.so failed to load: /home/jthagaraja/redis-protobuf-0.1.0/compile/libredis-protobuf.so: undefined symbol: inflateInit2_ |
@JaiBalaj You can try to add Check above comments in this issue for an example. Regards |
Hi @sewenew , Thanks issue has been resolved. |
I follow the requirements of Install redis-protobuf With Source Code.
system
redis.conf
redis logs
17878:M 05 Mar 2020 19:14:20.987 # WARNING: The TCP backlog setting of 511 cannot be enforced because /proc/sys/net/core/somaxconn is set to the lower value of 128. 17878:M 05 Mar 2020 19:14:20.987 # Server initialized 17878:M 05 Mar 2020 19:14:20.987 # WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect. 17878:M 05 Mar 2020 19:14:20.987 # WARNING you have Transparent Huge Pages (THP) support enabled in your kernel. This will create latency and memory usage issues with Redis. To fix this issue run the command 'echo never > /sys/kernel/mm/transparent_hugepage/enabled' as root, and add it to your /etc/rc.local in order to retain the setting after a reboot. Redis must be restarted after THP is disabled. 17878:M 05 Mar 2020 19:14:20.987 # <ReJSON> JSON data type for Redis v1.0.4 [encver 0] 17878:M 05 Mar 2020 19:14:20.987 * Module 'ReJSON' loaded from /usr/local/lib/rejson.so 17878:M 05 Mar 2020 19:14:20.989 # Module /usr/local/lib/libredis-protobuf.so failed to load: /usr/local/lib/libredis-protobuf.so: undefined symbol: deflateInit2_ 17878:M 05 Mar 2020 19:14:20.989 # Can't load module from /usr/local/lib/libredis-protobuf.so: server aborting
Help me, thank you!
The text was updated successfully, but these errors were encountered: