Thread

  1. SPARC problem with WAL additions?

    Keith Parks <emkxp01@mtcc.demon.co.uk> — 1999-10-08T20:08:33Z

    Hi All, 
    
    I'm seeing a funny with the new WAL aware postmaster.
    
    After doing a "kill" on the postmaster process I get another 
    postmaster process which appears to be spinning on a spinlock.
    
    I left it for almost an hour whilst I did something else.
    
    I believe the spinlock code on my system, SPARCLinux, is OK 
    from running the s_lock_test, see below.
    
    Any ideas what's happening?
    
    Keith.
    
    [postgres@sparclinux pgsql]$ ps -aux| grep post
    postgres 19364  0.0  1.9  1936   760  p0 S  Sep 26   0:00 login -p -h sparc2 -f
    postgres 19365  0.0  2.2  1484   880  p0 S  Sep 26   0:10 -bash
    postgres 27333  0.0  2.4  4012   948  p0 S   22:24   0:00 postmaster -N 16 -B 3
    postgres 27385 99.6  2.9  4076  1124  p0 R   19:19  51:49 postmaster -N 16 -B 3
    postgres 27409  0.0  1.3  1116   512  p0 R   20:11   0:00 ps -aux
    postgres 27410  0.0  1.1  1176   448  p0 R   20:11   0:00 grep post
    [postgres@sparclinux pgsql]$ gdb /usr/local/pgsql/bin/postmaster 27385
    GDB is free software and you are welcome to 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.
    GDB 4.16 (sparc-unknown-linux), Copyright 1996 Free Software Foundation, Inc...
    
    /usr/local/pgsql/27385: No such file or directory.
    Attaching to program `/usr/local/pgsql/bin/postmaster', process 27385
    Reading symbols from /lib/libdl.so.1.8.3...done.
    Reading symbols from /lib/libm.so.5.0.6...done.
    Reading symbols from /usr/lib/libreadline.so.2.0...done.
    Reading symbols from /lib/libtermcap.so.2.0.8...done.
    Reading symbols from /usr/lib/libncurses.so.3.0...done.
    Reading symbols from /lib/libc.so.5.3.12...done.
    Reading symbols from /lib/ld-linux.so.1...done.
    CreateCheckPoint (shutdown=1 '\001') at ../../../include/storage/s_lock.h:151
    151             __asm__("ldstub [%2], %0" \
    (gdb) bt
    #0  CreateCheckPoint (shutdown=1 '\001') at 
    ../../../include/storage/s_lock.h:151
    #1  0x55f1c in ShutdownXLOG () at xlog.c:1426
    #2  0x587e4 in BootstrapMain (argc=5, argv=0xeffff5c8) at bootstrap.c:359
    #3  0xb63bc in SSDataBase (startup=0 '\000') at postmaster.c:2026
    #4  0xb53f0 in pmdie (postgres_signal_arg=1469440) at postmaster.c:1254
    #5  0xeffff8f0 in ?? ()
    #6  0xb48cc in ServerLoop () at postmaster.c:745
    #7  0xb468c in PostmasterMain (argc=4620, argv=0x120c) at postmaster.c:640
    
    
    [postgres@sparclinux buffer]$ make s_lock_test
    gcc -I../../../include -I../../../backend   -O2 -Wall -Wmissing-prototypes 
    -I../.. -DS_LOCK_TEST=1 s_lock.c -o
     s_lock_test
    ./s_lock_test
    S_LOCK_TEST: this will hang for a few minutes and then abort
                 with a 'stuck spinlock' message if S_LOCK()
                 and TAS() are working.
    
    FATAL: s_lock(00020bf0) at s_lock.c:270, stuck spinlock. Aborting.
    
    FATAL: s_lock(00020bf0) at s_lock.c:270, stuck spinlock. Aborting.
    make: *** [s_lock_test] IOT trap/Abort (core dumped)
    make: *** Deleting file `s_lock_test'