OpenBSD, Apache, and IPv6

(Last modified: 02/23/02)


The Apache httpd daemon in OpenBSD 3.0 does not support IPv6 natively. It must be patched. Unfortunately, patching the source tree w/ the patches provided by the KAME team fails miserably. This document provides information for compiling a new, IPv6-enabled httpd, with defaults similar to those used in the default configuration of the native OpenBSD httpd.

This document references Apache 1.3.19 and Mod_SSL 2.8.3-1.3.19.


Download a copy of the Apache IPv6 patch from
Download Apache from
Download Mod_SSL from

Decompress the archives, then:

cd mod_ssl-2.8.3-1.3.19
./configure --with-apache=../apache_1.3.19 --enable-rule=INET6 \
--with-layout=OpenBSD --enable-suexec --enable-module=ssl \
--suexec-caller=www --suexec-docroot=/var/www/htdocs \
--suexec-logfile=/var/log/suexec_log --suexec-userdir=public_html \
--suexec-uidmin=1000 --suexec-gidmin=1000 \

cd ..
patch < /path/to/apache.patch
cd apache_1.3.19
cp /usr/src/usr.sbin/httpd/config.layout .
sh ./configure.v6 --with-layout=OpenBSD --enable-rule=INET6 --enable-suexec \
--suexec-caller=www --suexec-docroot=/var/www/htdocs \
--suexec-logfile=/var/log/suexec_log --suexec-userdir=public_html \
--suexec-uidmin=1000 --suexec-gidmin=1000 \
--suexec-safepath=/usr/bin:/bin:/usr/local/bin --enable-module=ssl
make && make install


Note that if you are upgrading from a non-IPv6 enabled version of Apache, you may need to update your httpd.conf. There are some significant changes that will effect the server's operation. Run apachectl configtest to see if there are any immediate errors.


Finally, stop and restart httpd (simply restarting will not do the trick, since we are working with a new binary):

apachectl stop && apachectl start


Written by Robert Mooney (rjmooney\@impetus\.us).

The method used above is described in Unfortunately, it's not in English. It was, however, useful in creating this document.

Copyright (c) 2001-2002 Robert Mooney, All rights reserved.

This document may be freely distributed and modified, so long as the original author is credited.


Support a starving software engineer! If you are inclined, you can leave me a tip with PayPal. Sign up for it.

 Return to the Main index