473,386 Members | 1,654 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

socket_close() problem

Hi to everybody.

First, let mi apologize if I'm doing a newbe question: I'm not a PHP
programmer, but I have to solve a problem located in a PHP web page.
Thanks in advance if you try to help me.

I have a Linux host (Suse 9.2 2.6.8-24.14-smp) running
apache2-2.0.50-7.3 and php4-4.3.8-8.2. In this host there is also a C
custom made server. The PHP web page opens a socket in order to send
data to the C server. The problem happens when the web page close the
connection using socket_shutdown($socket,2); and socket_close($socket);
At this moment the socket connection ends (after a short TIME_WAIT
state), but the C server socket file descriptor remains until it is
stopped. There aren't error messages or values.

This is a lsof (list open files) screen showing the problem:

pcotcpvie 6509 mem REG 3,2 106308 8857
/lib/ld-2.3.3.so
pcotcpvie 6509 mem REG 3,2 1359489 8882
/lib/tls/libc.so.6
pcotcpvie 6509 0r CHR 1,3 28476 /dev/null
pcotcpvie 6509 1u CHR 136,1 3 /dev/pts/1
pcotcpvie 6509 2u CHR 136,1 3 /dev/pts/1
pcotcpvie 6509 3r FIFO 0,7 10100 pipe
pcotcpvie 6509 4w FIFO 0,7 10100 pipe
pcotcpvie 6509 5u unix 0xd0a01580 21433 socket
pcotcpvie 6509 6u IPv4 21434 TCP *:pcovie
(LISTEN)
pcotcpvie 6509 7u sock 0,4 21435 can't identify
protocol
pcotcpvie 6509 8u sock 0,4 21482 can't identify
protocol
pcotcpvie 6509 9u sock 0,4 21483 can't identify
protocol
pcotcpvie 6509 10u sock 0,4 22069 can't identify
protocol
pcotcpvie 6509 11u sock 0,4 22274 can't identify
protocol
pcotcpvie 6509 12u sock 0,4 22305 can't identify
protocol
pcotcpvie 6509 13u sock 0,4 22314 can't identify
protocol
pcotcpvie 6509 14u sock 0,4 22398 can't identify
protocol
pcotcpvie 6509 15u sock 0,4 22402 can't identify
protocol
pcotcpvie 6509 16u sock 0,4 22413 can't identify
protocol
pcotcpvie 6509 17u sock 0,4 22669 can't identify
protocol

At every new connection close, it appears a new "can't identify
protocol" line

This problem don't happen if I use a C client to connect to the C
server, so this let me to think that the problem is in the PHP code or
maybe in the apache config.

The fact is that I'm very disconcerted. I haven't found any information
on the net, so I will apreciate your suggests.

Kind regards!

Jul 17 '05 #1
0 1229

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Bruce Davis | last post by:
I'm having a problem on windows (both 2000 and XP) with a multi-threaded tkinter gui application. The problem appears to be a deadlock condition when a child thread pops up a Pmw dialog window in...
11
by: Kostatus | last post by:
I have a virtual function in a base class, which is then overwritten by a function of the same name in a publically derived class. When I call the function using a pointer to the derived class...
0
by: Refky Wahib | last post by:
Hi I need Technical Support I finished a Great project using .Net and SQL Server and .Net Mobile Control My Business case is to implement this Program to accept about 1 Million concurrent...
9
by: Sudesh Sawant | last post by:
Hello, We have an application which communicates using remoting. There is a server which is a Windows Service. The server exposes an object which is a singleton. The client is a Web Application...
117
by: Peter Olcott | last post by:
www.halting-problem.com
28
by: Jon Davis | last post by:
If I have a class with a virtual method, and a child class that overrides the virtual method, and then I create an instance of the child class AS A base class... BaseClass bc = new ChildClass();...
6
by: Ammar | last post by:
Dear All, I'm facing a small problem. I have a portal web site, that contains articles, for each article, the end user can send a comment about the article. The problem is: I the comment length...
16
by: Dany | last post by:
Our web service was working fine until we installed .net Framework 1.1 service pack 1. Uninstalling SP1 is not an option because our largest customer says service packs marked as "critical" by...
2
by: Mike Collins | last post by:
I cannot get the correct drop down list value from a drop down I have on my web form. I get the initial value that was loaded in the list. It was asked by someone else what the autopostback was...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.