Starting and stopping the IBM HTTP Server

Perform the steps on this page to start or stop your IBM HTTP Server.

Before you begin

Ensure that you configured the IBM HTTP Server properly or you might encounter errors when you attempt to start the server. For more information, see

Procedure

  • To start your Web server:
    OptionDescription
    Windows
    • On local IHS, run the following command:
      HTTPServer_installdir/bin/apache.exe -k start -f WC_installdir/instances/instance_name/httpconf/httpd.conf
    • On remote IHS, run the following command:
      HTTPServer_installdir/bin/apache.exe -k start -f Remote_configuration_dir/httpconf/httpd.conf
      where Remote_configuration_dir is the directory specified during instance creation using the remote IHS option.
    Important: If you have started your IBM HTTP Server through the Windows Services menu, you must stop the IBM HTTP Server through the Windows Services menu. Alternatively, if you have started your IBM HTTP Server through the command line, you must stop it through the command line.
    SolarisLinuxAIX
    • On local IHS, log in as the root user using the su - root command and run the following command:
      HTTPServer_installdir/bin/apachectl -k start -f WC_installdir/instances/instance_name/httpconf/httpd.conf
    • On remote IHS, log in as the root user using the su - root command and run the following command:
      HTTPServer_installdir/bin/apachectl -k start -f Remote_configuration_dir/httpconf/httpd.conf
      where Remote_configuration_dir is the directory specified during instance creation using the remote IHS option.
    For IBM i OS operating system

    Run the following command from an IBM i command line:

    STRTCPSVR SERVER(*HTTP) HTTPSVR(instance_name)
  • To stop your Web server:
    OptionDescription
    Windows
    • On local IHS, run the following command:
      HTTPServer_installdir/bin/apache.exe -k stop -f WC_installdir/instances/instance_name /httpconf/httpd.conf
    • On remote IHS, run the following command:
      HTTPServer_installdir/bin/apache.exe -k stop -f Remote_configuration_dir/httpconf/httpd.conf
      where Remote_configuration_dir is the directory specified during instance creation using the remote IHS option.
    Important: If you have started your IBM HTTP Server through the Windows Services menu, you must stop the IBM HTTP Server through the Windows Services menu. Alternatively, if you have started your IBM HTTP Server through the command line, you must stop it through the command line.
    SolarisLinuxAIX
    • On local IHS, log in as the root user using the su - root command and run the following command:
      HTTPServer_installdir/bin/apachectl -k stop -f WC_installdir/instances/instance_name /httpconf/httpd.conf
    • On remote IHS, log in as the root user using the su - root command and run the following command:
      HTTPServer_installdir/bin/apachectl -k stop -f Remote_configuration_dir/httpconf/httpd.conf
      where Remote_configuration_dir is the directory specified during instance creation using the remote IHS option.
    For IBM i OS operating system

    Run the following command from an IBM i command line:

    ENDTCPSVR SERVER(*HTTP) HTTPSVR(instance_name)