MonetDB icon indicating copy to clipboard operation
MonetDB copied to clipboard

MonetDB server crashes in `mvc_row_result_wrap`

Open fuboat opened this issue 1 year ago • 0 comments

Describe the bug MonetDB server crashes in mvc_row_result_wrap.

To Reproduce

SELECT 50 , CASE WHEN COUNT ( ) OVER ( ) THEN ( 63 ) END;

Backtrace of the Crash

#0 0x7f232aa70e6c (mvc_row_result_wrap+0x7bc)
#1 0x7f232afe9dad (runMALsequence+0xe8d)
#2 0x7f232afe8ace (runMAL+0xee)
#3 0x7f232aa8f9d2 (SQLrun+0x142)
#4 0x7f232aa91499 (SQLengineIntern+0xc9)
#5 0x7f232aa8e0d2 (SQLengine_+0x1122)
#6 0x7f232aa8b1fe (SQLengine+0x3e)
#7 0x7f232b00fb2f (runScenario+0x6f)
#8 0x7f232b010cfe (MSscheduleClient+0xb6e)
#9 0x7f232b1546c2 (doChallenge+0x132)
#10 0x7f232bf71b38 (thread_starter+0x318)
#11 0x7f232a982609 (start_thread+0xd9)
#12 0x7f232a8a5353 (clone+0x43)

Software versions

  • MonetDB version number: v11.49.1 (Dec2023)
  • OS and version: Ubuntu 20.04
  • From docker image monetdb/monetdb:Dec2023 (or monetdb/dev-builds:default)

An example of steps to reproduce in docker container (write the poc into /tmp/test.sql first):

docker container rm monetdb_test -f
docker run -e MDB_DB_ADMIN_PASS=monetdb --name monetdb_test -itd monetdb/monetdb:Dec2023
docker exec monetdb_test bash -c 'echo -n -e "user=monetdb\npassword=monetdb\n" > /root/.monetdb'

sleep 10
cat /tmp/test.sql | timeout 5s docker exec -i monetdb_test mclient monetdb     # run test case

if docker exec monetdb_test bash -c "grep '[m]server5' /proc/*/cmdline -lR"; then
    echo "[INFO] Server normal."
else
    echo "[CRASH] Mserver5 process does NOT exist."
fi

It can also be reproduced on the docker image monetdb/dev-builds:default.

Issue labeling bug

fuboat avatar Mar 17 '24 11:03 fuboat