IBM Support

"Virtual Host/WebGroup not Found" Error When Submitting HTTP Request

Troubleshooting


Problem

Receiving the following errors:[] PLGN0021E: Servlet Request Processor Exception: Virtual Host/WebGroup Not Found : The host localhost has not been defined. PLGN0021E: Servlet Request Processor Exception: Virtual Host/WebGroup Not Found: The web group default_host/webapp/examples has not been defined.[] Where:[
  • ] [
  • ]localhost is the alias (or hostname) contained in the URL. [
  • ]default_host is the name of the virtual host in which the alias (or hostname) of the request is listed. [
  • ]/webapp/examples is the context root of the request. [
] Receiving the following error: []PLGN0021E: Servlet Request Processor Exception: Virtual Host/WebGroup Not Found : The host 123.55.67.89 on port 4567 has not been defined[] Where:[
  • ] [
  • ]123.55.67.89 is the alias contained in the URL. [
  • ]Where 4567 is the port the Web server is listening on. [
]

Cause

This specific wording of the third error (when it includes the port number) has only been found under a few circumstances which are noted below in the Solution section.

This problem is usually related to an incorrect configuration of a virtual host, or a necessary component that has not been started.

Resolving The Problem

  • This error has several possible causes and workarounds for these symptoms:


Virtual Host or Web Application Not Found: The host alias has not been defined:

This problem occurs because you have an alias defined in a virtual host (like default_host) and this virtual host is not associated with a Web module, or a change was made to the virtual host and the Application Server was not restarted. If a request is made using this alias, the host not defined error occurs. To resolve the problem, do one of the following things:
  1. Remove the virtual host because it is not associated with any Web modules.
  2. Associate the virtual host with an installed Web module.
    Please see the instruction from WebSphere Application Server Information Center http://www.ibm.com/support/knowledgecenter/SSAW57_8.5.5/com.ibm.websphere.nd.doc/ae/trun_app_mapvhosts.html
  3. Restart the Application Server.
 

Virtual Host or Web Application Not Found: The web group virtual_host/context root has not been defined:

This problem is known to occur for the following reasons:

  1. The Web module associated with the context root in the error message is not started.
     
  2. You have the same Host Alias listed in more than one virtual host.

    Example:
    <VirtualHostGroup Name="default_host">
           <VirtualHost Name="*:80"/>
           <VirtualHost Name="*:9080"/>
    </VirtualHostGroup>

    <VirtualHostGroup Name="my_host">
           <VirtualHost Name="spartan:80"/>
           <VirtualHost Name="*:9081"/>
    </VirtualHostGroup>


    spartan:80 is duplicated in both virtual hosts because a request over spartan:80 would match aliases in both virtual hosts (*:80 and spartan:80). To resolve, remove the *:80 alias in default_host and add more specific aliases, such as:

    wolverine:80
    buckeye:80

    www.wolverine.com:80
    www.buckeye.com:80


    Note:
    • The existence of localhost as an alias can cause duplicate entries.

      If localhost is used as an alias entry, check the etc/hosts file to ensure all host names (aliases) associated with the loopback address (127.0.0.1) are part of the same virtual host grouping (for example, default_host).

      For example, if I have an entry in my hosts file that looks like this:

      127.0.0.1 localhost Jones
    • Aliases need to be in the same virtual host grouping. So, you cannot put the aliases of localhost and kolinski in different virtual host groupings.
       
  3. The request was made directly to the internal HTTP transport of the Application Server and the URI entered is not valid.

    This message is seen only because the URI entered is not valid. If you do not want to see these messages, do one of the following:
    • Ensure that the URI entered into your browser is valid.
    • Send the requests through a Web server that has the WebSphere plug-in installed. The plug-in routes only the proper URIs to the Application Server

      To resolve this problem, ensure that your Web module is started, or that you do not have the same alias listed in more than one virtual host. Otherwise, make sure that the requesting URI is valid for your application.
The browser shows "Page cannot be displayed". Servlet Engine trace shows:

Virtual Host/WebGroup Not Found : The host 123.45.67.89 on port 4567 has not been defined.

This problem is known to occur because the port number in the plugin-cfg.xml does not match the port number in the virtualhosts.xml (V5.0 or V5.1), XML export (V4.0).

To resolve this problem, ensure that the port number is correctly added through the administrative console.

If problem not resolved

If the information in this document does not resolve your problem, please follow the instructions for the link that corresponds to your WebSphere version and open a PMR with IBM support:

  • WebSphere Application Server all releases

[{"Type":"MASTER","Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEQTP","label":"WebSphere Application Server"},"ARM Category":[{"code":"a8m3p000000F7xdAAC","label":"WebSphere Application Server traditional-All Platforms"}],"ARM Case Number":"","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"8.5.5;9.0.0;9.0.5"},{"Product":{"code":"SSNVBF","label":"Runtimes for Java Technology"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Java SDK","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB36","label":"IBM Automation"}}]

Document Information

Modified date:
18 August 2022

UID

swg21105548