Translate

Thursday 17 April 2014

Configuring a temporary 'Site Down For Maintenance' page in IBM HTTP Server on windows (WebSphere Jungle)

Follow the step to configure a temporary 'Site Down For Maintenance' page in IBM HTTP Server on windows:
                            
 If u want to watch this process click on below link
                                                
(or)



                                                            This article is based on below link..... I tried one scenario to practice this  task.
                                 Normally we see "page is under Maintenance" when we browse for some websites.
  ex:

                            Sometimes websites will go to update, modify ...etc. At the time user receives an error. But by using this scenario we can server one page to user while we r doing website modification.  
Browser--->Web Server(plug-in)---->Application Server (flow of request).
    In above steps we will create one page in WebServer. We will configure this page to redirect every request when we are under Maintenance.
                  I hope u got my point. Now we will do it.
1)First install WebSphere Application Server, IBM HTTP Server, Plug-in, WCT on your box.
2)Create one deployment manager profile and one custom profile.
3)Federate the node to dmgr. Create one server.
4)Configure WAS, IHS, Plug-in.
5)Deploy any one application.
6)Check this application is available through WebServer.
       ex:
               http://localhost:80/home.(here home is my application)

             Everything is fine up to now. Think now my "home" application is under maintenance stage. So I would like to do it now.
7)First go to directory. Then Go to "htdocs" folder in it.

8)Create one HTML Page in it like below lines. Save it as  "maintenance.html".

9)Create one empty text file and save it as "serverdown.txt".

10)Then add below lines in httpd.conf file(this file path is /conf/httpd.conf).
LoadModule rewrite_module modules/mod_rewrite.so
RewriteEngine on
ReWriteCond %{DOCUMENT_ROOT}/serverdown.txt -f
RewriteRule ^(.*)$ /maintenance.html [PT]

LoadModule rewrite_module modules/mod_rewrite.so
RewriteEngine on
RewriteCond %{DOCUMENT_ROOT}/serverdown.txt -f
RewriteRule ^(.*)$ /maintenance.html [PT]

11)Then restart IBM HTTP Server.

12)Then open browser. check your maintenance page is served by IBM HTTP Server or not...

ex:         http://localhost:80/home .


                          Here we request for page which is deployed in WebSphere Application Server. But we get maintenance page.
                           After completing modification in application, delete  serverdown.txt file. Then application is available for all users.



Subscribe My blog and send e-mail id for getting my articles in PDFs.....
Subscribe My You Tube channel to get alerts to your email.... 


Thanks. Comments & feedback r most welcome.








No comments:

Post a Comment