By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,664 Members | 1,643 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,664 IT Pros & Developers. It's quick & easy.

Incomplete Socket data at destination

P: n/a
I've setup a simple stream_socket_client and socket server scripts.
If I run the server script on a different machine than the client and
send data, not all the data reaches the server. If I run the server
and client on the same machine there is no problem. If I play around
with the size of the chunks I'm sending I get slightly different
results, but it never resolves the problem entirely. The error
message I see on the server side is "Warning: socket_read(): unable to
read from socket [104]: Connection reset by peer"

I'd normally consider this a network issue, but I've seen this work
recently from a PHP 4.3.x box as the client and a server somewhere
else on the Internet.

Are there factors that impact how much data stream_socket_client can
send? I've checked my php.ini's to make sure there is plenty of
memory available and timeouts aren't too short.

Any thoughts? Thanks
Aug 14 '08 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On 2008-08-14, Gozer <gc*********@gmail.comwrote:
I've setup a simple stream_socket_client and socket server scripts.
If I run the server script on a different machine than the client and
send data, not all the data reaches the server. If I run the server
and client on the same machine there is no problem. If I play around
with the size of the chunks I'm sending I get slightly different
results, but it never resolves the problem entirely. The error
message I see on the server side is "Warning: socket_read(): unable to
read from socket [104]: Connection reset by peer"

I'd normally consider this a network issue, but I've seen this work
recently from a PHP 4.3.x box as the client and a server somewhere
else on the Internet.

Are there factors that impact how much data stream_socket_client can
send? I've checked my php.ini's to make sure there is plenty of
memory available and timeouts aren't too short.

Any thoughts? Thanks
How much are you trying to send? There are limits in any network,
ones imposed by the cabling, any routers or switches along the way,
and the network interfaces involved.

These limits are generally *much* higher for the loopback device.

--
Andrew Poelstra ap*******@wpsoftware.com
To email me, use the above email addresss with .com set to .net
Aug 15 '08 #2

This discussion thread is closed

Replies have been disabled for this discussion.