on 07-07-2009 3:49 PM
<pre>
Hi, I currently use MaxDB 7.6.06 Build 003-121-202-135 on Linux and experience severe problems with binary columns and the loader. I do the following (with Python):
session = sdb.loader.Loader ()
session.cmd('USE USER XYZ SECURE SERVERDB MYDB ON MYSERVER')
cmd = "EXPORT COLUMNS * FROM some_binary_table DATA OUTSTREAM 'myfile' FWV BINARY"
session.release()
For normal tables without binary columns, this works. However, for tables with binary columns that look like this it crashes:
CREATE TABLE my_binary_table (
id INTEGER NOT NULL DEFAULT SERIAL,
data LONG BYTE NOT NULL,
PRIMARY KEY (id))
The output of my script is the following:
-
snip -
EXPORT COLUMNS * FROM my_binary_table DATA OUTSTREAM '/tmp/output.dat' FWV BINARY
-
> Emergency stack backtrace <----
Using 'backtrace' for stack tracing
(0):0x00007febdc407b30
(1):0x0000000000720920
(2):0x00000000007268ce
(3):0x000000000071eecc
(4):0x00000000006e4d9c
(5):0x00000000006e6ee0
(6):0x00000000006df8a8
(7):0x00000000004142f1
(8):0x00007febdb73c436
(9):0x0000000000413c3a
-
> Dump of siginfo contents <----
signal: 11(SIGSEGV)
code: 1(ILL_ILLOPC:illegal opcode)
errno: 0
value(int): 66(0x42)
value(ptr): 0x42
pid: 0
addr: (nil)
-
> Register Dump <----
rax: 0x0000000000000000 rbx: 0x0000000000c55ea8
rcx: 0x0000000000c5a530 rdx: 0x0000000000000003
rsi: 0x0000000000c55b90 rdi: 0x0000000000a36440
rsp: 0x00007fffe4c70c10 rbp: 0x0000000000000004
r08: 0x0000000000a36340 r09: 0x0101010101010101
r10: 0x0000000000000000 r11: 0x00007febdb79d50e
r12: 0x0000000000c54c30 r13: 0x0000000000000002
r14: 0x0000000000c533f2 r15: 0x0000000000000003
rip: 0x0000000000720920 eflg: 0x0000000000010246
cs: 0x0000 gs: 0x0000
fs: 0x0000
omsk: 0x0000000000000000 cr2: 0x0000000000000000
trap: 0x000000000000000e err: 0x0000000000000004
-
> Floating-point register dump <----
foper: 0x0000 frip: 0x0000000000000000 fdata: 0x0000000000000001
control: 0x0001 status: 0x0000 tag: 0x0000
mxcsr: 0x0000037f mxcr_mask: 0x00000000
fp[0]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[1]: 0x0.1f80 0000 ffff 0000 * 2^0x0000
fp[2]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[3]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[4]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[5]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[6]: 0x0.0000 0000 0000 0000 * 2^0x0000
fp[7]: 0x0.0000 0000 0000 0000 * 2^0x0000
xmm[00]: 0x00000000.00000000.00000000.00000000
xmm[01]: 0x00000000.00000000.00000000.00000000
xmm[02]: 0x00000000.00000000.00000000.00000000
xmm[03]: 0x00000000.00000000.00000000.00000000
xmm[04]: 0x00000000.00000000.00000000.00000000
xmm[05]: 0x00000000.00000000.00000000.00000000
xmm[06]: 0x00000000.00000000.00000000.00000000
xmm[07]: 0x00000000.00000000.00000000.00000000
xmm[08]: 0x00000000.00000000.00000000.00000000
xmm[09]: 0x00000000.00000000.00000000.00000000
xmm[10]: 0x00000000.00000000.00000000.00000000
xmm[11]: 0x00000000.00000000.00000000.00000000
xmm[12]: 0x00000000.00000000.00000000.00000000
xmm[13]: 0x00000000.00000000.00000000.00000000
xmm[14]: 0x00000000.00000000.00000000.00000000
xmm[15]: 0x00000000.00000000.00000000.00000000
-
> Module List <----
|.text Start |.text End | Module File Name
|0x0000000000400000|0x00000000008e3000| /opt/sdb/programs/pgm/lserver
|0x00007febdb71e000|0x00007febdb86d000| /lib64/libc-2.8.so
|0x00007febdba77000|0x00007febdba8d000| /lib64/libgcc_s.so.1
|0x00007febdbc8e000|0x00007febdbce3000| /lib64/libm-2.8.so
|0x00007febdbee4000|0x00007febdbfd4000| /usr/lib64/libstdc++.so.6.0.10
|0x00007febdc1f0000|0x00007febdc1f8000| /lib64/librt-2.8.so
|0x00007febdc3f9000|0x00007febdc40f000| /lib64/libpthread-2.8.so
|0x00007febdc615000|0x00007febdc622000| /lib64/libcrypt-2.8.so
|0x00007febdc852000|0x00007febdc854000| /lib64/libdl-2.8.so
|0x00007febdca56000|0x00007febdca73000| /lib64/ld-2.8.so
-
> Symbolic stack backtrace <----
0: Lunlock_17 + 0x2f
SFrame: IP: 0x00007febdc407b30 (0x00007febdc407b01+0x2f)
Module: /lib64/libpthread-2.8.so
-
1: ls27_InitDatExtrRec(tls00_DBInfo, MetaDataDef&, tls00_TransformationCmd*,
tls00_DextractRec&, char) + 0xa90
Symbol: Z19ls27InitDatExtrRecP12tls00_DBInfoRP11MetaDataDefP23tls00_T
ransformationCmdRP17tls00_DextractRecPc
SFrame: IP: 0x0000000000720920 (0x000000000071fe90+0xa90)
Module: /opt/sdb/programs/pgm/lserver
-
2: ls27ExportTableRows(MetaDataDef&, tls00_DextractRec, char*) + 0xae
Symbol: Z19ls27ExportTableRowsRP11MetaDataDefP17tls00DextractRecPc
SFrame: IP: 0x00000000007268ce (0x0000000000726820+0xae)
Module: /opt/sdb/programs/pgm/lserver
-
3: ExportPackageDataRecord(MetaDataDef, tls00_DBInfo, char*) + 0x72c
Symbol: Z23ExportPackageDataRecordP11MetaDataDefP12tls00DBInfoPc
SFrame: IP: 0x000000000071eecc (0x000000000071e7a0+0x72c)
Module: /opt/sdb/programs/pgm/lserver
-
4: ExecuteTransformationPackage(tls00_Command, tls00_DBInfo) + 0x2ac
Symbol: Z28ExecuteTransformationPackageP13tls00CommandP12tls00_DBInfo
SFrame: IP: 0x00000000006e4d9c (0x00000000006e4af0+0x2ac)
Module: /opt/sdb/programs/pgm/lserver
-
5: ParseExecuteStatement(tls00_Command&, tls00_DBInfo) + 0x550
Symbol: Z21ParseExecuteStatementRP13tls00CommandP12tls00_DBInfo
SFrame: IP: 0x00000000006e6ee0 (0x00000000006e6990+0x550)
Module: /opt/sdb/programs/pgm/lserver
-
6: ctrlservcommand + 0x398
SFrame: IP: 0x00000000006df8a8 (0x00000000006df510+0x398)
Module: /opt/sdb/programs/pgm/lserver
-
7: c_main + 0x451
SFrame: IP: 0x00000000004142f1 (0x0000000000413ea0+0x451)
Module: /opt/sdb/programs/pgm/lserver
-
8: 0x00007febdb73c436 <symbol name not found>
SFrame: IP: 0x00007febdb73c436
Module: /lib64/libc-2.8.so
-
9: __gxx_personality_v0@@CXXABI_1.3 + 0xea
SFrame: IP: 0x0000000000413c3a (0x0000000000413b50+0xea)
Source: start.S:116
Module: /opt/sdb/programs/pgm/lserver
Traceback (most recent call last):
File "/home/dusty/bin/bsppython", line 142, in ?
execfile(sys.argv[0])
File "./dump.py", line 8, in ?
dump_table_data(metadata)
File "/home/dusty/prog/bsp/buildout/src/sa_tools/sa_tools/dump/__init__.py", l ine 17, in dump_table_data
dbdump(conn, table.name, FILENAME_PATTERN % (table.name, fn))
File "/home/dusty/prog/bsp/buildout/src/sa_tools/sa_tools/dump/maxdb.py", line 37, in dbdump
session.cmd(cmd)
loader.CommunicationError: loader.CommunicationError: [1] Reading header from pi pe:closed by serve
ERR -11608 COMMUNIC sql03_request: wrong connection state, state is 'requested'
-
snip -
Any clues about how to get around this?
Best Regards,
Hermann Himmelbauer</pre>
Edited by: Hermann Himmelbauer on Jul 7, 2009 4:54 PM
Thanks for your hint, but I found another satisfying solution: MaxDB has the the possibility to export all non-binary data to a CSV-File format and export the rest to a specific binary file like that:
EXPORT COLUMNS * FROM mytable DATA OUTSTREAM 'mytable.csv' LOB OUTSTREAM 2 'mytable.dat'
This fortunately works now!
Best Regards,
Hermann Himmelbauer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello,
would it be possible you upgrade the loader to version 7.7?
Maybe you could give it a try on second machine and access your database remotely.
Best Regards
Wolfgang
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
24 | |
11 | |
9 | |
7 | |
6 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.