dragonflydb / dragonfly

A modern replacement for Redis and Memcached
https://www.dragonflydb.io/
Other
25.21k stars 908 forks source link

bug(eval) SIGILL when execute EVAL command #121

Closed yoshino-s closed 2 years ago

yoshino-s commented 2 years ago

Version: dragonfly -128-NOTFOUND build time: 2022-06-06 13:36:06

Reproduce bug:

docker pull docker.dragonflydb.io/dragonflydb/dragonfly && \
docker tag docker.dragonflydb.io/dragonflydb/dragonfly dragonfly
docker run -p 6379:6379 --ulimit memlock=-1 -d --name dragonfly dragonfly
redis-cli

And run

EVAL "return {KEYS[1],KEYS[2],ARGV[1],ARGV[2]}" 2 key1 key2 first second [k

On Redis it will return

1) "key1"
2) "key2"
3) "first"
4) "second"

But on dragonfly db it will throw an error.

Log:

I20220608 01:52:41.115177     1 init.cc:56] dragonfly running in opt mode.
I20220608 01:52:41.115240     1 dfly_main.cc:179] maxmemory has not been specified. Deciding myself....
I20220608 01:52:41.115280     1 dfly_main.cc:184] Found 12.54GiB available memory. Setting maxmemory to 10.04GiB
I20220608 01:52:41.116029    10 proactor.cc:456] IORing with 1024 entries, allocated 102720 bytes, cq_entries is 2048
I20220608 01:52:41.117841     1 proactor_pool.cc:66] Running 12 io threads
I20220608 01:52:41.125202     1 server_family.cc:190] Data directory is "/data"
I20220608 01:52:41.125350     1 server_family.cc:114] Checking "/data/dump"
I20220608 01:52:41.125839    12 listener_interface.cc:79] sock[39] AcceptServer - listening on port 6379
*** SIGILL received at time=1654653180 on cpu 0 ***
PC: @     0x562988468a97  (unknown)  luaH_newkey
    @ ... and at least 1 more frames
romange commented 2 years ago

Thanks for reporting this. Yeah, it's related to #68 .

I will release a new version today that hopefully will fix it. ✌🏼

romange commented 2 years ago

fixed here: https://github.com/dragonflydb/dragonfly/releases/tag/v0.2.0 new docker image will be ready in 10min.