-
Notifications
You must be signed in to change notification settings - Fork 34
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
cs_hash_dup_count crash backend #28
Comments
some more info for un init cs,the sql emmit other error: for loaded small data, the sql run OK: for bigger data,it emmit different error message and also crash the backend: |
Looks like in both cases memory corruption takes place. |
some more case: crash=> select agg_val,group_by from crashlog_get('{604176597}'::int[]),cs_project_agg(cs_hash_dup_count(uin,cs_filter(class1=cs_const('737a7612853859405ba846b99f35f4c3'),class2))) order by 1 desc limit 5; I will dump the data to you. |
Actually the query you are using is not correct: there is inconsistency between "values" and "group-by" sequences in hash_agg operator. You should duplicate filter condition: |
Oh,I get it.Thank you for your explaination. |
Not sure if crash really caused by this error. |
I have send the data to you by email. |
The problem was caused by non-reentrant (thread-unsafe) errro reporting in PostgreSQL (because PostgreSQL itself is not using threads). |
select agg_val,group_by from crashlog_get('{604176597}'::int[]),cs_project_agg(cs_hash_dup_count(uin,cs_filter(class1=cs_const('737a7612853859405ba846b99f35f4c3'),class2))) order by 1 desc limit 5;
glibc-2.12-1.49.tl1.x86_64
(gdb) c
Continuing.
[New Thread 0x7f7217ef8700 (LWP 18782)]
[New Thread 0x7f72176f7700 (LWP 18783)]
[New Thread 0x7f7216ef6700 (LWP 18784)]
[New Thread 0x7f72166f5700 (LWP 18785)]
[New Thread 0x7f7215ef4700 (LWP 18786)]
[New Thread 0x7f72156f3700 (LWP 18787)]
[New Thread 0x7f7214ef2700 (LWP 18788)]
[New Thread 0x7f72146f1700 (LWP 18789)]
[New Thread 0x7f7213ef0700 (LWP 18790)]
[New Thread 0x7f72136ef700 (LWP 18791)]
[New Thread 0x7f7212eee700 (LWP 18792)]
[New Thread 0x7f72126ed700 (LWP 18793)]
[New Thread 0x7f7211eec700 (LWP 18794)]
[New Thread 0x7f72116eb700 (LWP 18795)]
[New Thread 0x7f7210eea700 (LWP 18796)]
[New Thread 0x7f72106e9700 (LWP 18797)]
Program received signal SIGSEGV, Segmentation fault.
0x00007f7e25c9b28b in imcs_thread_pool_wait (pool=0xb61940) at threadpool.c:45
45 pool->sync->unlock(pool->sync);
(gdb) print pool->sync
$1 = (imcs_mutex_t *) 0x0
(gdb) bt
#0 0x00007f7e25c9b28b in imcs_thread_pool_wait (pool=0xb61940) at threadpool.c:45
#1 0x0000000700004201 in ?? ()
#2 0x0000000000000000 in ?? ()
(gdb) \l
Undefined command: "". Try "help".
(gdb) l
40 {
41 pool->sync->lock(pool->sync);
42 pool->work_id = 0;
43 pool->start->signal(pool->start, pool->n_workers);
44 pool->finish->wait(pool->finish, pool->sync, pool->n_workers, IMCS_TM_INFINITE);
45 pool->sync->unlock(pool->sync);
46
47 }
48 int counters[4] = {0,0,0,0};
49 static void imcs_thread_pool_execute(struct imcs_thread_pool_t* self, imcs_job_t job, void* arg)
(gdb)
if use cs_hash_count,the sql will run ok
The text was updated successfully, but these errors were encountered: