After upgrading from CQ5.2.X to CQ5.3 then all pages in our site return a 404 HTTP status.


If you have defined a custom 404 error handler in CQ5.2.X /apps/sling/servlet/errorhandler/404.jsp then it will override the custom 404 handler included out of the box in CQ5.3. This will cause all pages to return 404 statuses because your script will override CQ5.3's out of the box script.


To resolve this issue:

  1. Rename your custom 404 handler /apps/sling/servlet/errorhandler/404.jsp
  2. Copy /libs/sling/servlet/errorhandler/404.jsp to /apps/sling/servlet/errorhandler/404.jsp
  3. Adapt the out of the box script to do an include of your custom 404 handler. You may do this by replacing the bottom section with your 404 functionality.

    Bottom section of CQ5.3's 404.jsp (referred to above):

    // get here if authentication should not take place or if
    // no Authenticator service is available or if no
    // AuthenticationHandler is willing to authenticate
    // So we fall back to plain old 404/NOT FOUND
    // send 404
    <title>404 Not Found</title>
    <h1>Not Found</h1>
    <p>The requested URL <%= request.getRequestURI() %> was not found on this server.</p>
    <address><%= this.getServletConfig().getServletContext().getServerInfo() %></address>

Applies to

CQ5.2.X to CQ5.3 Upgrade

이 작업에는 Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License의 라이센스가 부여되었습니다.  Twitter™ 및 Facebook 게시물은 Creative Commons 약관을 적용받지 않습니다.

법적 고지 사항   |   온라인 개인 정보 보호 정책