Skip site navigation (1)Skip section navigation (2)
Date:      01 Mar 2017 16:19:13 +0100
From:      Nikola Kolev <koue@chaosophia.net>
To:        freebsd-net@freebsd.org
Subject:   Sockets unexpected behavior
Message-ID:  <Prayer.1.3.5.1703011619130.54782@chaosophia.net>

next in thread | raw e-mail | index | archive | help
Howdy,

I'm maintainer of www/obhttpd - OpenBSD httpd. Currently I'm trying to 
update the port to current version of httpd in OpenBSD cvs and I'm facing 
problem with the sockets during startup. There is major change in sockets 
management which cause httpd to exited abnormally on FreeBSD during startup 
with correct configuration file:

# ./httpd -d -f ~/nkolev/httpd-multi.conf
startup
server: invalid location
lost child: pid 55160 exited abnormally
server: invalid location
server: invalid location
lost child: pid 55159 exited abnormally
lost child: pid 55161 exited abnormally
logger exiting, pid 55162
parent terminating, pid 55158

and then the output of sockstat is:

# sockstat -l | grep ":80 "
?        ?          ?     ?  tcp4   192.168.104.17:80     *:*
?        ?          ?     ?  tcp4   127.0.0.1:80          *:*
?        ?          ?     ?  tcp4   192.168.104.17:80     *:*
?        ?          ?     ?  tcp4   127.0.0.1:80          *:*
?        ?          ?     ?  tcp4   192.168.104.17:80     *:*
?        ?          ?     ?  tcp4   127.0.0.1:80          *:*

I'm even able to connect to the socket once:

# telnet localhost 80
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
^]
telnet> quit
Connection closed.

I'm facing the same problem on 11-STABLE and 10-STABLE and with IPv6 
configuration also.

I assume sockets should not appear in sockstat output after abnormally exit 
of httpd. Is this httpd problem or FreeBSD kernel problem?

Regards,
Nikola 

-- 
Nikola Kolev
koue@chaosophia.net
https://github.com/koue/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Prayer.1.3.5.1703011619130.54782>