Oracle Net Trace Shows Ns2=12539 Error (Doc ID 753809.1)

Last updated on MARCH 05, 2010

Applies to:

Oracle Net Services - Version: 9.2.0.1.0 to 11.1.0.6.0
Information in this document applies to any platform.

Symptoms

Oracle Net trace reports an error stack that includes a 12539:

[000001 15-AUG-2008 15:06:43:068] nserror: nsres: id=0, op=65, ns=12532, ns2= 12539; nt[0]=0, nt[1]=0, nt[2]=0; ora[0]=0, ora[1]=0, ora[2]=0
[000001 15-AUG-2008 15:06:43:068] nsdo: nsctxrnk=0
[000001 15-AUG-2008 15:06:43:068] nsdo: error exit
[000001 15-AUG-2008 15:06:43:068] nioqrc: send failed: bl = 1, nicbl = 1
[000001 15-AUG-2008 15:06:43:068] nioqper: error from nioqrc
[000001 15-AUG-2008 15:06:43:068] nioqper: ns main err code: 12532
[000001 15-AUG-2008 15:06:43:068] nioqper: ns (2) err code: 12539
[000001 15-AUG-2008 15:06:43:068] nioqper: nt main err code: 0
[000001 15-AUG-2008 15:06:43:068] nioqper: nt (2) err code: 0
[000001 15-AUG-2008 15:06:43:068] nioqper: nt OS err code: 0
[000001 15-AUG-2008 15:06:43:068] nioqer: entry
[000001 15-AUG-2008 15:06:43:068] nioqer: incoming err = 12150
[000001 15-AUG-2008 15:06:43:068] niomapnserror: entry
[000001 15-AUG-2008 15:06:43:068] niqme: entry
[000001 15-AUG-2008 15:06:43:068] niqme: reporting NS-12532 error as ORA-12532

This is  a TNS-12539 TNS buffer over- or under-flow.
In this case the SQL failing over a database link reported to screen

ORA-12532: TNS:invalid argument
ORA-02063: preceding line <str> from <name >

Checking packets in the client trace file, before the error stack, a data packet of 957 bytes can be seen:

[000001 15-AUG-2008 15:06:43:032] nsprecv: tlen=957, plen=957, type=6

And the matching server trace shows same packet size was sent:

[000001 15-AUG-2008 15:06:43:031] nspsend: plen=957, type=6

And then a marker packet:

[000001 15-AUG-2008 15:06:43:068] nsprecv: packet dump
[000001 15-AUG-2008 15:06:43:068] nsprecv: 00 0B 00 00 0C 00 00 00 |........|
[000001 15-AUG-2008 15:06:43:068] nsprecv: 01 00 01 |... |
[000001 15-AUG-2008 15:06:43:068] nsprecv: normal exit
[000001 15-AUG-2008 15:06:43:068] nsrdr: got NSPTMK packet

Marker packets (NSPTMK) and some ORA-03111 errors are just a part of the break handling
protocol that attempts to resync communications if the client application and server are operating too fast for each other.
So we know the packet was sent / received at the correct size and the timestamp show no delay.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms