• Login to WebSphere Administrative Console
• Go to the Servers >> Server Types >> WebSphere application servers
• Click the JVM where you want to override the error
• Expand “Web Container Settings” and click “Web container”
• Click Custom properties
• Click New and Enter the Name as
com.ibm.ws.webcontainer.webgroupvhostnotfound
• and Value the error message you want to show. For ex:
“Sorry, requested page not found.”
• Click OK
• Review and save the configuration
• Restart the JVM
Now, let’s try to access some page which doesn’t exist.