Subject Re: [firebird-support] Access Violation on Disconnect
Author Helen Borrie
At 09:13 AM 22/09/2003 +1000, you wrote:
>Just a query regarding the crashes on disconnect when event notification
>is used. I am finding that on some Win2k machines when I disconnect a
>IB_Connection I get an access violation in the fbclient.dll. I have
>upgraded to Firebird and am using IBO 4.2Ie.
>This problem does not occur on all machines but on the machines that it
>does happen every time I attempt to disconnect I get an access violation
>and my service crashes.

Event notifications are transmitted through a different port-to-port
channel than the other API traffic. It's random. It could be that the
problem clients don't have any available listening ports or that the
clients are hitting an unavailable port on the server. Or, even more
simply, the server's firewall doesn't accept the IP address/port
combination at all.

You can set it up in firebird.conf so that event traffic uses a dedicated

# The TCP Port Number to be used for server Event Notification
# messages. The value of 0 (Zero) means that the server will choose
# a port number randomly.
# Type: integer
#RemoteAuxPort = 0

Now, my interpretation of this is likely to be flawed, as I have three
machines here which are all open to internal network traffic, and I haven't
had time to test it by locking down ports. I'm using Norton Pro 2003 and
it's a bit of a blunt instrument for internal firewalling.

RemoteAuxPort is a new feature in field-test software so, if you need help
with troubleshooting, you need to ask on firebird-devel.

Another thing you could look at in firebird.conf is
DummyPacketInterval. When using TCP/IP on Win32 you must make sure this is
zero. The default changed from 60 to zero in RC 6. Don't take my word for
it, read the notes in the firebird.conf that comes with RC 6.

Also, using IBO, don't overlook the fact that you need OldParameterOrdering
switched on for the time being.
>Is there a debug version of fbclient that I could use to help me debug
>this issue further as it is proving difficult to do as the problem does
>not occur within my devel environment?

Fb-devel is the place to ask for that.

Don't exclude the possibility that the problem client machines have an old
gds32.dll somewhere around in their application paths. For IBO they need -
in their System32 directory - the small gds32.dll + fbclient.dll ---
BOTH. Alternatively, you can rename fbclient.dll to gds32.dll and let IBO
load it directly.

gds32.dll (36 Kb) File Version, Special Build Description "Firebird
1.5 Release Candidate 6"
fbclient.dll (352Kb) File Version, SBD as above.

If there's an old gds32.dll in the same dir as their application exe, for
example, then they will be loading and calling that, not the Firebird
ones. Remember that the gds32.dll that came in Delphi 5 and 6 were broken
for events...