[Catalyst] Test server not releasing socket
Will Hawes
info at whawes.co.uk
Mon Apr 24 18:40:41 CEST 2006
FreeBSD 4.10-STABLE, Catalyst 5.66:
[Mon Apr 24 17:29:56 2006] [catalyst] [info] Application powered by
Catalyst 5.66
Couldn't create daemon: Address already in use at
/usr/local/lib/perl5/site_perl/5.8.7/Catalyst/Engine/HTTP.pm line 135.
admin at ds645# netstat -p tcp
Active Internet connections
Proto Recv-Q Send-Q Local Address Foreign Address (state)
...
tcp4 0 0 ds645.3000 XXX-XXX-XXX-XXX-nl.2500
TIME_WAIT
The above happens whether or not the test server is started with the
"-r" flag (I get the same problem if I stop the server with Ctrl-C).
Using bash instead of tcsh makes no difference. No other processes are
using port 3000.
On the suggestion of a few people on IRC I have tried inserting
$SIG{INT} = sub{exit(0)};
in the test server code, but to no avail.
Waiting about 10 seconds then manually reinvoking the test server avoids
the error, but is a PITA and does rather defeat the object of having a
self-restarting server.
More information about the Catalyst
mailing list