Getting "A custom errorhandler for 404 responses" while hitting "<ip>:4502" | Community
Skip to main content
December 27, 2023
Solved

Getting "A custom errorhandler for 404 responses" while hitting "<ip>:4502"

  • December 27, 2023
  • 3 replies
  • 1153 views

Getting "A custom errorhandler for 404 responses" while hitting "<ip>:4502",

 

where it should redirect to login page > "http://<ip>/libs/granite/core/content/login.html?resource=%2F&$$login$$=%24%24login%24%24&j_reason=unknown&j_reason_cod"

 

Facing this issue in Author instance.

Kindly suggest any solution.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by arunpatidar

Hi @vips24 
You need to update the logic for custom 404 at /apps/sling/servlet/errorhandler

e.g.

https://github.com/arunpatidar02/com.aemlab.junitapp/tree/master/ui.apps/src/main/content/jcr_root/apps/sling/servlet/errorhandler 

3 replies

Preetpal_Bindra
Community Advisor
Community Advisor
December 27, 2023

Hello @vips24 

Do the logs complain about a bundle or a service missing or stopped when you use that URL?

Can you set the logs to debug mode, if not already?

Also, when starting AEM up were there errors that were recorded in the logs?

 

thanks,

Preetpal

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
December 28, 2023

Hi @vips24 
You need to update the logic for custom 404 at /apps/sling/servlet/errorhandler

e.g.

https://github.com/arunpatidar02/com.aemlab.junitapp/tree/master/ui.apps/src/main/content/jcr_root/apps/sling/servlet/errorhandler 

Arun Patidar
kautuk_sahni
Community Manager
Community Manager
January 2, 2024

@vips24 Did you find the suggestions from users helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.

Kautuk Sahni