Wednesday, October 15, 2014

Site Down Maintenance page in iPlanet

When ever your site is going to Schedule Maintenance or Down due to some issues at back end servers. Is it good to show 404 or 500 Page errors to users?. No , in this situation we need to build the custom Site Maintenance pages.

How to configure Site Maintenance Page in iPlanet?
  • Add below configuration lines in obj.conf file
        <Client urlhost="examplesite.com">
                 NameTrans fn="redirect" from="/" url="/Site_Maintenance_Page.htm"
        </Client>
  • Push or Deploy the configuration changes . No need of the server restart.
How to display the site logs or Images in Maintenance Page?
  • If you are using the images or static files to display your site Maintenance page to looks good you may face the problems.

    • How to solve it ?
      • Rewrite your static files as below
    • NameTrans fn="rewrite" from="/Site_Maintenance_Page/site_logo.png" root="/opt/iplanet" path="/Site_Maintenance_Page/site_logo.png"
    • NameTrans fn="rewrite" from="/Site_Maintenance_Page/Site_body.jpg" root="/opt/iplanet" path="/Site_Maintenance_Page/Site_body.jpg" 

 Note: Make sure Rewrite directive configuration should be placed before the redirect directive , other static images or files wont access.
  • Overall Configuration looks like
<Client urlhost="examplesite.com">
           NameTrans fn="rewrite" from="/Site_Maintenance_Page/site_logo.png" root="/opt/iplanet"                 path="/Site_Maintenance_Page/site_logo.png"

            NameTrans fn="rewrite" from="/Site_Maintenance_Page/Site_body.jpg" root="/opt/iplanet"               path="/Site_Maintenance_Page/Site_body.jpg"
            NameTrans fn="redirect" from="/" url="/Site_Maintenance_Page.htm"
</Client>

5 comments: