Invalid buffer received from client.

80 views
Skip to first unread message

Watery

unread,
May 10, 2005, 6:18:07 PM5/10/05
to
I'm having seriouos trouble after installing SP4. I have an application written in ASP.NET 1.1 which worked fine with SQL 2000 SP3, but after upgrading to SP4, the application totally crashed while trying to access the database. It gives an error saying a severe error has occued on the server. The
event log on the server has the following logged:

Error: 17805, Severity: 20, State: 3
Invalid buffer received from client.

For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.

I'm sure it's SP4 because after I reinstalled SQL Server with SP3, everything worked fine again. The server is running Windows 2003 SP1.

Anyone else having this problem or have a solution?

oj

unread,
May 10, 2005, 10:42:00 PM5/10/05
to
Sp4 reduces the network packet size to 32767. Consider adjusting your app to
avoid the error.

<quote>
In SP4, the maximum value for the network packet size option (set using
sp_configure) is 32767. This is slightly less than half the previous maximum
of 65536. During upgrade, existing values larger than 32767 will
automatically be adjusted to 32767. If a script attempts to use sp_configure
to set a value larger than 32767 but less than or equal to 65536, the value
will also be set to 32767. Setting the network packet size to a value larger
than 65536 results in an error.
</quote>

There's used to be a bug even when the network packet size was set to
65535...
http://support.microsoft.com/kb/875411


--
-oj

"Watery" <wate...@hotmail.com> wrote in message
news:4281...@duster.adelaide.on.net...

Watery

unread,
May 10, 2005, 11:34:11 PM5/10/05
to
Thanks oj...

Do you have an example of how to change the packet size to 32767 - is it through the connection string? At the moment, it has packet size set to 4096.

oj

unread,
May 11, 2005, 12:49:05 PM5/11/05
to
Yes. You want to specify the "Packet Size=xxx" in your connectionstring.

According to the article, you might want to limit each of your insert batch
to 32767 rows.

--
-oj


"Watery" <wate...@hotmail.com> wrote in message

news:42817d1b$1...@duster.adelaide.on.net...

Watery

unread,
May 11, 2005, 7:22:33 PM5/11/05
to
I tried what you suggested but with no vail.

Here's my connection string:
UID=user;PWD=password;Initial Catalog=DatabaseName;Data Source=ServerName;Packet Size=4096;

I tried the packet size 2048, 1024, 768 but they all return the same error.

Any help is greatly appreciated!

oj

unread,
May 11, 2005, 8:31:19 PM5/11/05
to
Perhaps, you want to explicitly define the sqldbtype for the sqlparameter
and be sure the length is not exceeding the allowable for the specified
type.

If you post your code (.Net call + sql), someone will take a closer look.

--
-oj


"Watery" <wate...@hotmail.com> wrote in message

news:428293aa$1...@duster.adelaide.on.net...

Watery

unread,
May 11, 2005, 10:17:12 PM5/11/05
to
Thanks oj... I changed my code as you suggested and it is now working! :)

But now it runs extremely slow and frequently timeout. Any solution to this problem as well?

oj

unread,
May 11, 2005, 10:28:00 PM5/11/05
to
Double check your sql to make sure proper indexes installed. Check out these
to see if they help:
http://support.microsoft.com/?id=308049
http://support.microsoft.com/kb/224587/

--
-oj

"Watery" <wate...@hotmail.com> wrote in message

news:4282...@duster.adelaide.on.net...

Watery

unread,
May 11, 2005, 11:32:45 PM5/11/05
to
Thanks oj... It's working fine now...

The problem was caused by creating an SQL parameter using DbType instead of SqlDbType. I was trying to create a generic data provider that connects to both Oracle and SQL Server. Now I think I have to map the individual DbType to SqlDbType.

Anyway, thanks for your help!! Much appreciated!

oj

unread,
May 12, 2005, 2:03:45 AM5/12/05
to
You're very welcome.

--
-oj

"Watery" <wate...@hotmail.com> wrote in message
news:4282...@duster.adelaide.on.net...

Reply all
Reply to author
Forward
0 new messages