1

If I switch my store to maintenance mode, then I get so see this page:

1 exception(s):
Exception #0 (Exception): Unable to proceed: the maintenance mode is enabled. 

Exception #0 (Exception): Unable to proceed: the maintenance mode is enabled. 
<pre>#1 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\Http\Interceptor#000000001f0deaee00000000184ccfc2#) called at [pub/index.php:45]
</pre>

How can I show a custom CMS Site or HTML Site instead?

1 Answer 1

4

When switching to the maintenance mode and developer mode is enabled, it will show the below message instead of 503 - Service Temporarily Unavailable page. The error message returns from the function assertMaintenance() from the file /var/www/html/magento/vendor/magento/framework/App/Bootstrap.php

1 exception(s):
Exception #0 (Exception): Unable to proceed: the maintenance mode is enabled. 

Exception #0 (Exception): Unable to proceed: the maintenance mode is enabled. 
<pre>#1 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\Http\Interceptor#000000001f0deaee00000000184ccfc2#) called at [pub/index.php:45]
</pre>

If you switched to the default or production mode from developer mode then it will show the 503 error message page (/var/www/html/magento/pub/errors/default/503.phtml)

<?php
/**
 * Copyright © Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */
?>

<h1>Service Temporarily Unavailable</h1>
<p>
    The server is temporarily unable to service your request due to maintenance downtime or capacity problems.
    Please try again later.
</p>

You can customize HTML of the 503.phtml page as per your requirement.

Hope this helps!

1
  • This is the best answer I've seen. It turns out, because I was in developer mode, I haven't been seeing the 503 error page all this time. Thanks to this post, I finally realized. Even though the 503 page appears in the LIVE environment in production mode, I now understand why it hasn't been showing up on my desktop PC. AWESOME Guy~
    – madagaskar
    Apr 8 at 4:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.