Re: SIGBUS in AllocSetAlloc & jdbc

Поиск
Список
Период
Сортировка
От Brian P Millett
Тема Re: SIGBUS in AllocSetAlloc & jdbc
Дата
Msg-id 3728AFA8.4B55BF3F@ec-group.com
обсуждение исходный текст
Ответ на Re: SIGBUS in AllocSetAlloc & jdbc  (Peter T Mount <peter@retep.org.uk>)
Список pgsql-hackers
Peter T Mount wrote:

> On Thu, 29 Apr 1999, Brian P Millett wrote:
>
> > Peter, I hope this long and boring message can shed some light on my
> > difficulties getting jdbc & postgres6.5b1(current snapshot) to work
> > with blobs.  I have NO problem with text, numeric, etc.  Just blobs &
> > the LO interface.
> >
> > I feel that it is a 64 vs 32 bit memory management problem.
>
> At first glance, the JDBC code looks ok. In fact it is similar to the
> ImageViewer example that's included with the source.
>
> Do you get the same problem when using ImageViewer?

No, and yes.

The ImageViewer will give an error that the backend has lost connection after
importing the second image.  The first goes in just fine, it is the second
that causes the problem.  If I stop & restart the ImageViewer, then I can
import a second image.  BUT I can only view one.  When I try to view the
second, I get an error.  The back trace of that error is at the bottom.  It
IS the same as the backtrace for the example I sent you.  Again, the first
time I run ImageViewer, I can import only one image.  When I import a second
image, I get the backtrace (1).  After I stop & start the ImageViewer, there
is one image in the database.  I can import a new image, but when I try to
view the first image, I get backtrace (2).

BACKTRACE (1):
here is the bt:
vlad: ps -ef | grep po   root   272     1  0   Apr 27 ?        0:00 /usr/lib/power/powerd    bpm   815     1  0
11:00:58pts/2    0:00 /opt/pgsql/bin/postmaster -o
 
-F -o /opt/pgsql/logs/backend.log -W 30 -S 16384 -    bpm   965  1153  0 13:41:54 pts/10   0:00 grep po    bpm   961
815 0 13:41:49 pts/2    0:00 /opt/pgsql/bin/postmaster -o
 
-F -o /opt/pgsql/logs/backend.log -W 30 -S 16384 -
vlad: gdb /opt/pgsql/bin/postmaster 961
GNU gdb 4.17
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc-sun-solaris2.7"...
(no debugging symbols found)...

/home/bpm/compile_area/cvs_pgsql/pgsql.snapshot/961: No such file or
directory.
Attaching to program `/opt/pgsql/bin/postmaster', process 961
Reading symbols from /usr/lib/libgen.so.1...(no debugging symbols found)...
done.
Reading symbols from /usr/lib/libcrypt_i.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libnsl.so.1...(no debugging symbols found)...
done.
Reading symbols from /usr/lib/libsocket.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libdl.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libm.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libcurses.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libc.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libmp.so.2...(no debugging symbols
found)...done.
Reading symbols from /usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1...
---Type <return> to continue, or q <return> to quit---
(no debugging symbols found)...done.
Reading symbols from /usr/lib/nss_files.so.1...(no debugging symbols
found)...
done.
Symbols already loaded for /usr/lib/libgen.so.1
Symbols already loaded for /usr/lib/libcrypt_i.so.1
Symbols already loaded for /usr/lib/libnsl.so.1
Symbols already loaded for /usr/lib/libsocket.so.1
Symbols already loaded for /usr/lib/libdl.so.1
Symbols already loaded for /usr/lib/libm.so.1
Symbols already loaded for /usr/lib/libcurses.so.1
Symbols already loaded for /usr/lib/libc.so.1
Symbols already loaded for /usr/lib/libmp.so.2
Symbols already loaded for /usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1
Symbols already loaded for /usr/lib/nss_files.so.1
0xff195d88 in _sigsuspend ()
(gdb) c
Continuing.

Program received signal SIGBUS, Bus error.
0xff145d70 in t_delete ()
(gdb) bt
#0  0xff145d70 in t_delete ()
#1  0xff145490 in _malloc_unlocked ()
#2  0xff145314 in malloc ()
#3  0x19f3a8 in AllocSetAlloc ()
#4  0x19fe48 in PortalHeapMemoryAlloc ()
#5  0x19f7b8 in MemoryContextAlloc ()
#6  0xb28c0 in initStringInfo ()
#7  0x13d4cc in SendFunctionResult ()
#8  0x13dcd4 in HandleFunctionRequest ()
#9  0x14048c in PostgresMain ()
#10 0x11161c in DoBackend ()
#11 0x110e78 in BackendStartup ()
#12 0x10fd98 in ServerLoop ()
#13 0x10f6e0 in PostmasterMain ()
#14 0xbca58 in main ()


BACKTRACE (2):
vlad: ps -ef | grep po   root   272     1  0   Apr 27 ?        0:00 /usr/lib/power/powerd    bpm   815     1  0
11:00:58pts/2    0:00 /opt/pgsql/bin/postmaster -o
 
-F -o /opt/pgsql/logs/backend.log -W 30 -S 16384 -    bpm   983  1153  0 14:08:13 pts/10   0:00 grep po    bpm   981
815 0 14:08:09 pts/2    0:00 /opt/pgsql/bin/postmaster -o
 
-F -o /opt/pgsql/logs/backend.log -W 30 -S 16384 -
vlad: gdb /opt/pgsql/bin/postmaster 981
GNU gdb 4.17
Copyright 1998 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.

Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc-sun-solaris2.7"...
(no debugging symbols found)...

/home/bpm/compile_area/cvs_pgsql/pgsql.snapshot/981: No such file or
directory.
Attaching to program `/opt/pgsql/bin/postmaster', process 981
Reading symbols from /usr/lib/libgen.so.1...(no debugging symbols found)...
done.
Reading symbols from /usr/lib/libcrypt_i.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libnsl.so.1...(no debugging symbols found)...
done.
Reading symbols from /usr/lib/libsocket.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libdl.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libm.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libcurses.so.1...(no debugging symbols
found)...
done.
Reading symbols from /usr/lib/libc.so.1...(no debugging symbols
found)...done.
Reading symbols from /usr/lib/libmp.so.2...(no debugging symbols
found)...done.
Reading symbols from /usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1...
---Type <return> to continue, or q <return> to quit---
(no debugging symbols found)...done.
Reading symbols from /usr/lib/nss_files.so.1...(no debugging symbols
found)...
done.
Symbols already loaded for /usr/lib/libgen.so.1
Symbols already loaded for /usr/lib/libcrypt_i.so.1
Symbols already loaded for /usr/lib/libnsl.so.1
Symbols already loaded for /usr/lib/libsocket.so.1
Symbols already loaded for /usr/lib/libdl.so.1
Symbols already loaded for /usr/lib/libm.so.1
Symbols already loaded for /usr/lib/libcurses.so.1
Symbols already loaded for /usr/lib/libc.so.1
Symbols already loaded for /usr/lib/libmp.so.2
Symbols already loaded for /usr/platform/SUNW,Ultra-5_10/lib/libc_psr.so.1
Symbols already loaded for /usr/lib/nss_files.so.1
0xff195d88 in _sigsuspend ()
(gdb) c
Continuing.

Program received signal SIGBUS, Bus error.
0x19f180 in AllocSetAlloc ()
(gdb) bt
#0  0x19f180 in AllocSetAlloc ()
#1  0x19fa2c in GlobalMemoryAlloc ()
#2  0x19f7b8 in MemoryContextAlloc ()
#3  0x4cc44 in RelationGetIndexScan ()
#4  0x5b4d0 in btbeginscan ()
#5  0x199e8c in fmgr_c ()
#6  0x19a46c in fmgr ()
#7  0x4d2e4 in index_beginscan ()
#8  0x133624 in inv_seek ()
#9  0x133514 in inv_seek ()
#10 0xb4070 in lo_lseek ()
#11 0x199e60 in fmgr_c ()
#12 0x19a46c in fmgr ()
#13 0x13dc44 in HandleFunctionRequest ()
#14 0x14048c in PostgresMain ()
#15 0x11161c in DoBackend ()
#16 0x110e78 in BackendStartup ()
#17 0x10fd98 in ServerLoop ()
#18 0x10f6e0 in PostmasterMain ()
#19 0xbca58 in main ()


--
Brian Millett
Enterprise Consulting Group     "Heaven can not exist,
(314) 205-9030                     If the family is not eternal"
bpm@ec-group.com                   F. Ballard Washburn





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

Предыдущее
От: Andy Lewis
Дата:
Сообщение: PLpgSQL Stat Problem
Следующее
От: Massimo Dal Zotto
Дата:
Сообщение: Re: [HACKERS] How do I get the backend server into gdb?