Re: Psql crashes with Segmentation fault on copy from

Поиск
Список
Период
Сортировка
От Gregory Stark
Тема Re: Psql crashes with Segmentation fault on copy from
Дата
Msg-id 87lk1up7nt.fsf@oxford.xeocode.com
обсуждение исходный текст
Ответ на Re: Psql crashes with Segmentation fault on copy from  ("Francisco Reyes" <lists@stringsutils.com>)
Ответы Re: Psql crashes with Segmentation fault on copy from
Список pgsql-general
"Francisco Reyes" <lists@stringsutils.com> writes:

> #1  0x0000002a955820ae in pqPutMsgBytes (buf=0x2a9860a010, len=2147483647,

So it's trying to execute an sql query that's MAXINT bytes long which is
pretty off-course.

> #5  0x0000000000406e95 in SendQuery (
>     query=0x2a9860a010 "yjbjK8WKLRHKavptOqlPD4QeI24=\t200803\t2008-03-11\t0\t10.47\t08620667742MDF1\t\tMCDONALD'S
F7742\t5814\t1003\t1187954\nyjbjK8WKLRHKavptOqlPD4QeI24=\t200803\t2008-03-11\t0\t16.99\t00614111869AWG1\t\tPIGGLY
WIGGLY#52\t5411"...)
>     at common.c:878
> #6  0x0000000000409dfa in MainLoop (source=0x5414f0) at mainloop.c:340
> #7  0x000000000040408d in process_file (filename=0x541d70
> "data/usb_t_60M.sql", single_txn=0 '\0') at command.c:1394
> #8  0x00000000004057cd in exec_command (cmd=0x541bc0 "i",
> scan_state=0x549b30, query_buf=0x549890) at command.c:546

Could you post the first couple lines of data/usb_t_60M.sql ? Does it really
have a COPY command at the beginning? Are you really doing \i
data/usb_t_60M.sql or were you trying to do a copy from this file?

> #9  0x0000000000406286 in HandleSlashCmds (scan_state=0x549b30,
> query_buf=0x549890) at command.c:92
> #10 0x0000000000409f66 in MainLoop (source=0x541070) at mainloop.c:259
> #11 0x000000000040408d in process_file (filename=0x560750
> "bench-index-after.sql", single_txn=0 '\0') at command.c:1394
> #12 0x00000000004057cd in exec_command (
>     cmd=0x569360 "Hxnh9aOwMviVVP9I=\t200803\t2008-03-10\t0\t15.54\t434240509886\t\tNU-YALE CLEANERS
(BARD\t4225\t0\t11636644\n3MM9gwBGMHiyPGmUrqIEOOha1Ao=\t200803\t2008-03-11\t0\t739.95\t554172100100007\t\tUSAAP&C
PREMIUM\t6300\t0\t183718"...,
>     scan_state=0x549c20, query_buf=0x54a480) at command.c:546

I'm a bit puzzled by this. The command being executed here seems to have been
overwritten by data from the later command -- before it was overwritten it was
apparently "\i bench-index-after.sql". It seems something with the
PsqlScanState is not being sufficient to make the lexer completely reentrant
here.

What version of flex is this built with?

--
  Gregory Stark
  EnterpriseDB          http://www.enterprisedb.com
  Ask me about EnterpriseDB's 24x7 Postgres support!

В списке pgsql-general по дате отправления:

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Revealing the "postgres" user service-account in Windows XP Home
Следующее
От: Gregory Stark
Дата:
Сообщение: Re: Bottom Posting