wiki:pkg-apache

Version 16 (modified by jmckenna, 15 years ago) ( diff )

--

WikiStart back

Apache OSGeo4W Package

Version

  • Apache 2.x
  • you can also browse the exact versions available for OSGeo4W here
  • the source is available at apache.org

Installation

Windows 7 and beyond

  • the installer will create and start the Apache service during installation automatically
    • available since Apache package version 2.2.14-2

XP and Vista

  • Apache is not automatically installed as a service
  • to install the Apache service:
    • click on the "OSGeo4w" shortcut on your desktop
    • the OSGeo4W command window will open
    • type the following command:
        apache-install.bat
      
    • you should see a message such as:
        Installing the Apache OSGeo4W Web Server service
        The Apache OSGeo4W Web Server service is successfully installed.
        Testing httpd.conf....
        Errors reported here must be corrected before the service can be started.
        The Apache OSGeo4W Web Server service is starting.
        The Apache OSGeo4W Web Server service was started successfully.
      
  • The apache-uninstall.bat and apache-restart.bat scripts are also available to uninstall the service, or restart the server.

Administrative Privileges note

If you are using Vista or more recent, you may receive an error when trying to install the Apache service, such as:

  >apache-install.bat
  Installing the Apache OSGeo4W Web Server service
  (OS 5)Access is denied.  : Failed to open the WinNT service manager
  The service name is invalid.

  More help is available by typing NET HELPMSG 2185.

Starting with Vista, Windows made changes so that you must allow commands to run as administrator. To get around this, you should:

  • right-click on the "OSGeo4W" shortcut on your desktop
  • click on "Run as Administrator"

Run as Administrator

Verifying that Apache is installed as a Service

Apache service listing

Port

  • Currently hardcoded to run on port 80.
  • If you wish to have Apache use a different port:
    • open /osgeo4w/apache/conf/httpd.conf in a text editor
    • search for "Listen 80" (around line 46)
    • change the "80" into another value (such as "8080")
    • restart the "Apache OSGeo4W web server" service

Note: if you are having problems with ports, you can use TCPView to get a list of active ports

Getting Started

Once Apache is installed, you can now open an Internet browser (Firefox or Internet Explorer) and goto http://localhost

localhost page

Maintainers

Note: See TracWiki for help on using the wiki.