Maintenance settings does not enable

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
Post Reply
User avatar
master3395
Forum Members
Forum Members
Posts: 94
Joined: Mon Mar 30, 2015 7:13 am
Location: Norway

Maintenance settings does not enable

Post by master3395 »

Hello.

I am currently trying to enable the Maintenance page on my main site, but it turns out it errors at 200 (ok), it does not output 503.
So I did a clean install of cms on a subdomain.
And it does the same thing.

I gave the whole subdomain 777 permission, to test, but still, blank 200 code.

https://cmstest.newstargeted.com/

OpenLiteSpeed 1.6.21
Contabo
6 vCPU Cores
16 GB RAM
400 GB SSD
400 Mbit/s Port

Firewall.
Stopped

  • Code: Select all

    ----------------------------------------------
    
    Cms Version: 2.2.15
    
    Installed Modules:
    
    AdminSearch: 1.0.5
    CMSContentManager: 1.1.9
    CmsJobManager: 0.1.3
    DesignManager: 1.1.9
    FileManager: 1.6.12
    FilePicker: 1.0.5
    MenuManager: 1.50.3
    MicroTiny: 2.2.5
    ModuleManager: 2.1.8
    Navigator: 1.0.9
    News: 2.51.11
    Search: 1.52
    
    Config Information:
    
    php_memory_limit:
    max_upload_size: 1028000000000
    url_rewriting: none
    page_extension:
    query_var: page
    auto_alias_content: true
    locale:
    set_names: true
    timezone: Europe/Oslo
    permissive_smarty: false
    
    Php Information:
    
    phpversion: 7.4.16
    md5_function: On (True)
    json_function: On (True)
    gd_version: 2
    tempnam_function: On (True)
    magic_quotes_runtime: Off (False)
    E_ALL: 22527
    E_STRICT: 0
    E_DEPRECATED: 0
    test_file_timedifference: No time difference found
    test_db_timedifference: No time difference found
    create_dir_and_file: 1
    memory_limit: 2048G
    max_execution_time: 240
    register_globals: Off (False)
    output_buffering: 4096
    disable_functions:
    open_basedir:
    test_remote_url: Success
    file_uploads: On (True)
    post_max_size: 1028G
    upload_max_filesize: 1028G
    session_save_path: /var/lib/lsphp/session/lsphp74 (1733)
    session_use_cookies: On (True)
    xml_function: On (True)
    xmlreader_class: On (True)
    check_ini_set: On (True)
    curl: On
    
    Performance Information:
    
    allow_browser_cache: On (True)
    browser_cache_expiry: 60
    php_opcache: On (True)
    smarty_cache: Off (False)
    smarty_compilecheck: Off (False)
    auto_clear_cache_age: On (True)
    Server Information:
    
    Server Software: LiteSpeed
    Server Api: litespeed
    Server Os: Linux 4.18.0-240.22.1.el8_3.x86_64 On x86_64
    Server Db Type: MySQL (mysqli)
    Server Db Version: 10.3.28
    Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
    
    Permission Information:
    
    tmp: /home/newstargeted.com/cmstest.newstargeted.com/tmp (0777)
    tmp_cache: /home/newstargeted.com/cmstest.newstargeted.com/tmp/cache (0777)
    templates_c: /home/newstargeted.com/cmstest.newstargeted.com/tmp/templates_c (0777)
    modules: /home/newstargeted.com/cmstest.newstargeted.com/modules (0777)
    uploads: /home/newstargeted.com/cmstest.newstargeted.com/uploads (0777)
    File Creation Mask (umask): /home/newstargeted.com/cmstest.newstargeted.com/tmp/cache (0777)
    config_file: 0444
    ----------------------------------------------
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Maintenance settings does not enable

Post by paulbaker »

The idea of the "down for maintenance" mode at Site Admin > Settings - Global Settings > Maintenance Mode is to change every page to a message to imply "we're working on the site at the moment". It's not meant to output an HTTP error.


EDIT: This is wrong, see below...
To copy System Information to the forum:
https://docs.cmsmadesimple.org/troubles ... nformation

CMS Made Simple Geekmoots attended:
Nottingham, UK 2012 | Ghent, Belgium 2015 | Leicester, UK 2016
User avatar
master3395
Forum Members
Forum Members
Posts: 94
Joined: Mon Mar 30, 2015 7:13 am
Location: Norway

Re: Maintenance settings does not enable

Post by master3395 »

I thought it was supposed to output what i put as "maintenance" text.
But right now it just outputs 200 ok and a blank page.

Debug says it's executed.
DB shows 1 on sitepref

Code: Select all

Debug: (8.000000000008E-6) - (net usage: 465688) - (peak: 466424) Initialize Database
Debug: (0.00093299999999996) - (net usage: 526392) - (peak: 527128) Done Initializing Database
Debug: (0.00096200000000002) - (net usage: 526552) - (peak: 527288) initialize internal global cache
Debug: (0.001593) - (net usage: 637896) - (peak: 650232) done initializing global cache
Debug: (0.001617) - (net usage: 637360) - (peak: 650232) Loading Modules
Debug: (0.0025259999999999) - (net usage: 747224) - (peak: 747960) End of Loading Modules
Debug: (0.004898) - (net usage: 803960) - (peak: 804704) SELECT username, password, active, first_name, last_name, admin_access, email FROM cms_users WHERE user_id = 1
Debug: (0.074714) - (net usage: 804488) - (peak: 805232) SELECT preference,value FROM cms_userprefs WHERE user_id = 1
Debug: (0.074941) - (net usage: 788040) - (peak: 805232) Initialize Smarty
Debug: (0.077082) - (net usage: 943032) - (peak: 962840) Done Initialing Smarty
Debug: (0.077509) - (net usage: 960880) - (peak: 962840) SELECT group_id FROM cms_user_groups WHERE user_id = 1
Debug: (0.078448) - (net usage: 1028216) - (peak: 1051888) UPDATE cms_siteprefs SET sitepref_value = '1' WHERE sitepref_name = 'enablesitedownmessage'
Debug: (0.078916) - (net usage: 1039176) - (peak: 1051888) SELECT sitepref_name,sitepref_value FROM cms_siteprefs
Debug: (0.079754) - (net usage: 1030496) - (peak: 1051888) UPDATE cms_siteprefs SET sitepref_value = '1' WHERE sitepref_name = 'sitedown_use_wysiwyg'
Debug: (0.080068) - (net usage: 1039968) - (peak: 1051888) SELECT sitepref_name,sitepref_value FROM cms_siteprefs
Debug: (0.080887) - (net usage: 1030944) - (peak: 1051888) UPDATE cms_siteprefs SET sitepref_value = '<p>Site is currently down for maintenance</p>' WHERE sitepref_name = 'sitedownmessage'
Debug: (0.081183) - (net usage: 1040416) - (peak: 1051888) SELECT sitepref_name,sitepref_value FROM cms_siteprefs
Debug: (0.081879) - (net usage: 1031984) - (peak: 1051888) UPDATE cms_siteprefs SET sitepref_value = '' WHERE sitepref_name = 'sitedownexcludes'
Debug: (0.082128) - (net usage: 1041472) - (peak: 1051888) SELECT sitepref_name,sitepref_value FROM cms_siteprefs
Debug: (0.082961) - (net usage: 1032416) - (peak: 1051888) UPDATE cms_siteprefs SET sitepref_value = 0 WHERE sitepref_name = 'sitedownexcludeadmins'
Debug: (0.084846) - (net usage: 1024712) - (peak: 1051888) INSERT INTO cms_adminlog (timestamp, user_id, username, item_id, item_name, action, ip_addr) VALUES (1620056812,1,'admin',-1,'Global Settings','Edited','162.158.222.131')
Debug: (2.6999999999999E-5) - (net usage: 1040256) - (peak: 1051888) before theme load
Debug: (0.00046899999999994) - (net usage: 1059960) - (peak: 1060696) SELECT sitepref_name,sitepref_value FROM cms_siteprefs
Debug: (0.001224) - (net usage: 1053824) - (peak: 1070288) after theme load
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Maintenance settings does not enable

Post by paulbaker »

Hmm, I have just checked on one of my 2.2.15 sites and maintenance mode does indeed set the output to 503. Sorry, I was wrong above. Every day's a school day. ;D

I don't know why yours is not behaving.
To copy System Information to the forum:
https://docs.cmsmadesimple.org/troubles ... nformation

CMS Made Simple Geekmoots attended:
Nottingham, UK 2012 | Ghent, Belgium 2015 | Leicester, UK 2016
User avatar
master3395
Forum Members
Forum Members
Posts: 94
Joined: Mon Mar 30, 2015 7:13 am
Location: Norway

Re: Maintenance settings does not enable

Post by master3395 »

No worries, it was @DIGI3 That told me it is supposed to show 503 (with custom text).
But I guess this is the lesson of hosting a website on VPS and not on a pre-webhost.
Much to learn.
Post Reply

Return to “CMSMS Core”