Windows/Apache Web Server

Updating Apache

Introduction

The same as any software, to keep it secure it should be updated periodically. I use Apache for Windows from Apache Haus.

Update Notes

Apache.org stopped distributing the Windows MSI binary packages in 2015, but it does keep a list of Windows binary packages. In later Windows installations and updates I used the Apache Haus versions. On February 27, 2023, Apache Haus announced that their project is on hold. The latest version available at the time was Apache 2.4.55. In the announcement, Apache Haus does say that the versions from Apache Lounge are 100% compatible with theirs. Of course you can download the source files and compile it for Windows yourself.

Updating

The files are pre-compiled and are supplied as a zip file. It just needs to be decompressed and follow the directions given in an old 2017 post in their fourms, which says:

1. Shutdown Apache
2. Back up your current /bin and /modules folders
3. Download 2.4.25 of the same compiler and architecture
4. Replace all files in these 2 folders with the ones from 2.4.25 package
5. Try starting Apache. It should work
6. Optionally, you can replace the files in /include and /lib folders like you did above.

Current Version Information

Finding the current Apache version information is fairly easy. Open a command prompt, navigate to the bin folder in the Apache files and type:

httpd -v

Or

httpd -V

There is a difference in the information given if lowercase or uppercase v is used.

Lowercase v

Server version: Apache/2.4.41 (Win32)
Server built: Oct 18 2019 21:59:44

Uppercase V

Server version: Apache/2.4.41 (Win32)
Server built: Oct 18 2019 21:59:44
Distributed by: The Apache Haus
Compiled with: Visual Studio 2015 (VC14)
Server's Module Magic Number: 20120211:88
Server loaded: APR 1.7.0, APR-UTIL 1.6.1
Compiled using: APR 1.7.0, APR-UTIL 1.6.1
Architecture: 32-bit
Server MPM: WinNT
threaded: yes (fixed thread count)
forked: no
Server compiled with....
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses disabled)
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=256
-D HTTPD_ROOT="/Apache24"
-D HTTPD_EXEC="/Apache24/bin/httpd.exe"
-D DEFAULT_PIDLOG="logs/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_ERRORLOG="logs/error.log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"

Updating

The post said to use the "same compiler and architecture." After 3 years, I guessed the compiler was not going to be the same. I also wanted to upgrade to the 64bit version. All I knew for certain was that as I had only just installed the SSL certificates I wanted to keep the OpenSSL system rather than try and change to the LibreSSL version.

I copied all the current Apache folders as a backup then downloaded the Apache v2.4.54 64bit version from the Apache Haus downloads page and unzipped it.

Next, I stopped the server and copied the new /bin and /modules folders into the original installation folders, replacing all the files. I left all the other original files, including the configuration files, and folders as they were. Then restarted the server.

I had thought I was bound to break something, but everything went surprisingly well, the server seems to be working as it should and httpd -V now gives.

Server version: Apache/2.4.54 (Win64)
Server built: Nov 4 2022 20:49:29
Distributed by: The Apache Haus
Compiled with: Visual Studio 2022 (VS17)
Server's Module Magic Number: 20120211:124
Server loaded: APR 1.7.0, APR-UTIL 1.6.1, PCRE 10.40 2022-04-14
Compiled using: APR 1.7.0, APR-UTIL 1.6.1, PCRE 10.40 2022-04-14
Architecture: 64-bit
Server MPM: WinNT
threaded: yes (fixed thread count)
forked: no
Server compiled with....
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses disabled
) -D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=256
-D HTTPD_ROOT="/Apache24"
-D HTTPD_EXEC="/Apache24/bin/httpd.exe"
-D DEFAULT_PIDLOG="logs/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_ERRORLOG="logs/error.log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"

This page created November 12, 2022; last modified May 14, 2023