Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

SOLVED Unsuspend account gives error 404 temporarily

Discussion in 'General Discussion' started by ruiz, Sep 5, 2018.

  1. ruiz

    ruiz Active Member

    Joined:
    Feb 13, 2008
    Messages:
    41
    Likes Received:
    2
    Trophy Points:
    58
    Hello,

    We have the weirdest behavior on our servers. When we unsuspend a account, the website start showing a 404 error page, and after around 15 minutes the website starts loading just fine.

    Any idea of what it might be? Here's some information:
    - Website files are currectly in /public_html.
    - It's not the browsers cache. Servers logs also show the error 404
    - This happens only on some accounts. Others are unsuspended without issue
    - We are suspending/unsuspending accounts via API, but it all seems to work fine.
    - We tried suspending and unsuspending again via WHM, but it still shows the 404 error
    - Tried restarting apache, no change
    - Currently we use mod security, php-fpm. Any of then might be the culprit?

    Thanks for your help!
     
  2. sparek-3

    sparek-3 Well-Known Member

    Joined:
    Aug 10, 2002
    Messages:
    1,893
    Likes Received:
    152
    Trophy Points:
    343
    cPanel Access Level:
    Root Administrator
    Have you verified that the file being listed in the domain's domlog (that is showing a 404 response code) actually exists in the domain's DocumentRoot?

    Do you have any caching system installed on the server? Varnish? nginx?
     
  3. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    5,815
    Likes Received:
    444
    Trophy Points:
    233
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    My assumption here is that there must be some kind of caching involved here as suggested by @sparek-3 I tested this on my own server with a domain running php-fpm and php v7.1:

    Code:
    # curl -vv https://mydomain.tld
    * About to connect() to mydomain.tld port 443 (#0)
    *   Trying <MyIP>...
    * Connected to mydomain.tld (<MyIP>) port 443 (#0)
    * Initializing NSS with certpath: sql:/etc/pki/nssdb
    *   CAfile: /etc/pki/tls/certs/ca-bundle.crt
      CApath: none
    * SSL connection using TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
    * Server certificate:
    *     subject: CN=mydomain.tld
    *     start date: Jul 18 00:00:00 2018 GMT
    *     expire date: Oct 16 23:59:59 2018 GMT
    *     common name: mydomain.tld
    *     issuer: CN="cPanel, Inc. Certification Authority",O="cPanel, Inc.",L=Houston,ST=TX,C=US
    > GET / HTTP/1.1
    > User-Agent: curl/7.29.0
    > Host: mydomain.tld
    > Accept: */*
    >
    < HTTP/1.1 200 OK
    < Date: Thu, 06 Sep 2018 15:08:31 GMT
    < Server: Apache
    < Link: <https://mydomain.tld/index.php/wp-json/>; rel="https://api.w.org/", <https://mydomain.tld/>; rel=shortlink
    < Transfer-Encoding: chunked
    < Content-Type: text/html; charset=UTF-8
    <
    
    Then suspended the account:
    Code:
    whmapi1 suspendacct user=myuser resason=test
    ---
    metadata:
      command: suspendacct
      output:
        raw: "Changing Shell to /bin/false...Done\nLocking Password...Done\nSuspending webdav users\nSuspending email account logins for mydomain.tld .... Done\nSuspending email account logins for domain.us .... Done\nSuspending email account logins for testingstuff.com .... Done\nSuspending mysql users\nSuspending websites...\nSuspending FTP accounts...\nSuspending outgoing email....Done\nMyUser's account has been suspended\n"
      reason: OK
      result: 1
      version: 1
    Confirmed it was suspended:

    Code:
    curl -vv https://mydomain.tld
    * About to connect() to mydomain.tld port 443 (#0)
    *   Trying <MyIP>...
    * Connected to mydomain.tld (<MyIP>) port 443 (#0)
    * Initializing NSS with certpath: sql:/etc/pki/nssdb
    *   CAfile: /etc/pki/tls/certs/ca-bundle.crt
      CApath: none
    * SSL connection using TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
    * Server certificate:
    *     subject: CN=mydomain.tld
    *     start date: Jul 18 00:00:00 2018 GMT
    *     expire date: Oct 16 23:59:59 2018 GMT
    *     common name: mydomain.tld
    *     issuer: CN="cPanel, Inc. Certification Authority",O="cPanel, Inc.",L=Houston,ST=TX,C=US
    > GET / HTTP/1.1
    > User-Agent: curl/7.29.0
    > Host: mydomain.tld
    > Accept: */*
    >
    < HTTP/1.1 302 Found
    < Date: Thu, 06 Sep 2018 15:09:34 GMT
    < Server: Apache
    < Location: https://mydomain.tld/cgi-sys/suspendedpage.cgi
    < Content-Length: 229
    < Content-Type: text/html; charset=iso-8859-1
    <
    <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
    <html><head>
    <title>302 Found</title>
    </head><body>
    <h1>Found</h1>
    <p>The document has moved <a href="https://mydomain.tld/cgi-sys/suspendedpage.cgi">here</a>.</p>
    </body></html>
    * Connection #0 to host mydomain.tld left intact
    Unsuspended the account:

    Code:
    whmapi1 unsuspendacct user=myuser
    ---
    metadata:
      command: unsuspendacct
      output:
        raw: "Unsuspending outgoing email....Done\nUnsuspending webdav users\nUnsuspending email account logins for mydomain.tld .... Done\nUnsuspending email account logins for domain.us .... Done\nUnsuspending email account logins for testingstuff.com .... Done\nUnsuspending websites...\nUnsuspending FTP accounts...\nmyusern's account is now active\nUnsuspending mysql users\nmyusers's account has been unsuspended\n"
      reason: OK
      result: 1
      version: 1
    checked again and no issues:

    Code:
    curl -vv https://mydomain.tld
    * About to connect() to mydomain.tld port 443 (#0)
    *   Trying <MyIP>...
    * Connected to mydomain.tld (<MyIP>) port 443 (#0)
    * Initializing NSS with certpath: sql:/etc/pki/nssdb
    *   CAfile: /etc/pki/tls/certs/ca-bundle.crt
      CApath: none
    * SSL connection using TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384
    * Server certificate:
    *     subject: CN=mydomain.tld
    *     start date: Jul 18 00:00:00 2018 GMT
    *     expire date: Oct 16 23:59:59 2018 GMT
    *     common name: mydomain.tld
    *     issuer: CN="cPanel, Inc. Certification Authority",O="cPanel, Inc.",L=Houston,ST=TX,C=US
    > GET / HTTP/1.1
    > User-Agent: curl/7.29.0
    > Host: mydomain.tld
    > Accept: */*
    >
    < HTTP/1.1 200 OK
    < Date: Thu, 06 Sep 2018 15:10:10 GMT
    < Server: Apache
    < Link: <https://mydomain.tld/index.php/wp-json/>; rel="https://api.w.org/", <https://mydomain.tld/>; rel=shortlink
    < Transfer-Encoding: chunked
    < Content-Type: text/html; charset=UTF-8
    <
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. Duilio Fanton

    Duilio Fanton Registered

    Joined:
    Nov 23, 2018
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Brasil
    cPanel Access Level:
    Root Administrator
    Hi guys!
    Same problem.
    When unsuspend a account, the website start showing a 404 error page, after after a few minutes the website starts loading normally
     
  5. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    5,815
    Likes Received:
    444
    Trophy Points:
    233
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    Can you please open a ticket using the link in my signature? I've been unable to replicate this, thus far and as such I'd like to see if having access to an affected system may shed some further light on the situation. Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved.


    Thanks!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. bibleman

    bibleman Member

    Joined:
    Mar 30, 2008
    Messages:
    7
    Likes Received:
    1
    Trophy Points:
    51
    Has there been any fix to this bug?

    A Reseller account that was unsuspended about 3 hours ago is displaying a 404 error on all the domains.
     
  7. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    5,815
    Likes Received:
    444
    Trophy Points:
    233
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    I was unable to replicate this behavior @bibleman per my last response. I had asked the OP to open a ticket and if you're experiencing the same issue please feel free to open a ticket using the link in my signature so that we might take a closer look. Once open please reply with the Ticket ID here so that we can update this thread with the resolution once the ticket is resolved.


    Thanks!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. bibleman

    bibleman Member

    Joined:
    Mar 30, 2008
    Messages:
    7
    Likes Received:
    1
    Trophy Points:
    51
    Rebooting the server resolved the problem.

    Thanks
     
    cPanelLauren likes this.
  9. cPanelLauren

    cPanelLauren Forums Analyst II Staff Member

    Joined:
    Nov 14, 2017
    Messages:
    5,815
    Likes Received:
    444
    Trophy Points:
    233
    Location:
    Houston
    cPanel Access Level:
    DataCenter Provider
    Hi @bibleman


    I'm glad to hear that the issue is resolved. Thanks for letting us know. If it should occur again please open a ticket as requested previously so we can take a closer look.


    Thanks!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice