Support » Plugin: Jetpack - WP Security, Backup, Speed, & Growth » Save Draft causing hang and 403 with Gutenberg

Viewing 14 replies - 16 through 29 (of 29 total)
  • You get a 405 doing a GET against xmlrpc.php from this error most likely:

    In file wp-includes/IXR/class-IXR-server.php

            if (!$data) {
                if (isset($_SERVER['REQUEST_METHOD']) && $_SERVER['REQUEST_METHOD'] !== 'POST') {
                    if ( function_exists( 'status_header' ) ) {
                        status_header( 405 ); // WP #20986
                        header( 'Allow: POST' );
                    }
                    header('Content-Type: text/plain'); // merged from WP #9093
                    die('XML-RPC server accepts POST requests only.');

    Any other testing suggestions for this?

    Plugin Support lizkarkoski

    (@lizkarkoski)

    Hi –

    Are you running any security plugins? If so, would you please try with those deactivated?

    No security plugins on apache or worpdress. The 405 error from xmlrpc.php is from wordpress core responding to a GET instead of a PUT.

    What is the “test__wpcom_self_test” doing? that may make it easier for me to debug.

    Plugin Contributor James Huff

    (@macmanx)

    Volunteer Moderator

    I have asked our developer for details, just so we’re sure we get this absolutely correct.

    We’ll let you know when we hear back.

    Plugin Author Brandon Kraft

    (@kraftbj)

    Code Wrangler

    Howdy!

    For the request in the original post hitting post.php, can you check the body of the response? There may be more information there, but I don’t immediately see the link to Jetpack.

    xmlrpc.php will not respond to a GET request by design ( https://github.com/WordPress/WordPress/blob/6fd8080e7ee7599b36d4528f72a8ced612130b8c/wp-includes/IXR/class-IXR-server.php#L41-L47 ) and the 405 error indicates that the wrong HTTP method is being used.

    The test__wpcom_self_test test is your Jetpack site pinging WordPress.com’s server to run our debugging suite found at https://jetpack.com/support/debug/ for your site and returning a simple “good” or “no good” response, but Jetpack’s debug tests wouldn’t reveal an issue that would be impacting Gutenberg post saving.

    My gut tells me this may be a rate-limiting issue or something with your server since it only sometimes happen.

    @kraftbj you may have missed earlier, the post.php problem seems to only happen with nextgen gallery & jetpack is connected. If jetpack is active and not connected, and nextgen gallery is active, then it doesn’t happen. I have an active ticket with nextgen over this right now. Additionally the admin UI becomes “slow”, with what appears to be large multi-second latency.

    Thanks for the tip on checking the response, I tracked down in the chrome debugging window, and it appears to be related to the nonce system.

    {"code":"wp_die","message":"The link you followed has expired.<\/p><p><a href="\/wordpress\/wp-admin\/post.php?post=1460&action=edit">Please try again.<\/a>","data":{"status":403},"additional_errors":[]}

    It’s not server related, because I’ve been able to replicate the exact error after copying the blog to a different hosting provider that using NGINX instead of apache (and obviously a different system).

    The next problem seems to be that https://2ontherun.com/ fails the jetpack selftest for some reason. And does if I disable every plugin but jetpack. But otherwise appears to be connected and responding correctly.

    • This reply was modified 1 year, 7 months ago by mattdrown.
    Plugin Author Brandon Kraft

    (@kraftbj)

    Code Wrangler

    The next problem seems to be that https://2ontherun.com/ fails the jetpack selftest for some reason. And does if I disable every plugin but jetpack. But otherwise appears to be connected and responding correctly.

    Can you check again? The WP.com-side tests are reporting all good for 2ontherun.com (as seen at jetpack.com/support/debug/ ).

    Regarding NextGen, I haven’t had a chance to look fully, but notably for me, on a fresh WordPress install with only Jetpack activated (not connected), once I activate NextGen, my admin URL is incorrect. It tries to use example.com instead of example.com/wp-admin/ .

    At first look, I’m not sure why that happened, but if something like that is happening, it would explain the nonce issue.

    jetpack.com/support/debug shows things are working, while “/wordpress/wp-admin/admin.php?page=jetpack-debugger” fails the self_check as above. I’ve just ignored it in the past.

    I’ve now pulled jetpack and looking for alternatives due to incredible lag in the admin pages. The lag was there before but has gotten a lot worse recently. I suspect it’s doing some sort of connection that is timing out, and pausing while this time out occurs. This doesn’t happen on other wordpress blogs on the same host (same server, same host), so I assume there is a config problem. Uninstalled and reinstalled the jetpack plugin did not solve the problem. I have not tried to delete/clean any jetpack database bits.

    Plugin Author Brandon Kraft

    (@kraftbj)

    Code Wrangler

    That’s a solid hypothesis. Could you copy/paste the advanced debug results section from wordpress/wp-admin/admin.php?page=jetpack-debugger except the top few lines that mention tokens?

    There is a connection test that happens on Jetpack dashboard pages—off the top of my head I don’t think it should happen on regular admin pages, but I can dig into that a bit more.

    How long of a lag? 5 seconds? 30 seconds? A rough sense can help me understand where the issue may possibly lie. Even if it is a config issue with your particular site, there may be some defensive coding we can to do to prevent this suboptimal experience. Thank you!

    Hi, I am so glad I stumbled across this. I would like to add a “me to” to this. I get exactly the same error.

    The error I see is related to

    {“code”:”wp_die”,”message”:”The link you followed has expired.<\/p><p>Please try again.<\/a>”,”data”:{“status”:403},”additional_errors”:[]}

    • This reply was modified 1 year, 7 months ago by mickwall.

    @kraftbj – I have had it disabled for the past week, and searching for alternatives to the features I used. I have installed it again, re-connected, and the info is below. I have disconnected it after this test. My admin delays were initially just 1-2 seconds between click, annoying, but ok. When I disabled it, it became 5+ seconds in my experience, any page on the admin side (and went away with just disabling jetpack). Today when I tested, it seemed “normal”.

    Debug Info
    jQuery version: 1.12.4

    CLIENT_ID: xxxxxxxxxxxxxxx
    BLOG_TOKEN: #XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
    MASTER_USER: 1
    CERT: 0
    TIME_DIFF: 0
    VERSION: 7.1.1:1552012150
    OLD_VERSION: 7.1.1:1552012150
    PUBLIC: 1
    USER_ID: 1
    USER_TOKEN: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
    PHP_VERSION: 7.2.10
    WORDPRESS_VERSION: 5.1.1
    JETPACK__VERSION: 7.1.1
    JETPACK__PLUGIN_DIR: /xxxxxxxxxx/2ontherun.com/wordpress/wp-content/plugins/jetpack/
    SITE_URL: https://2ontherun.com/wordpress
    HOME_URL: https://2ontherun.com
    PLAN: JetpackPlanfree

    — SYNC Status —
    Jetpack Sync Full Status: `
    Array
    (
    [started] => Tue, 26 Mar 2019 18:06:41 +0000
    [queue_finished] => Tue, 26 Mar 2019 18:06:41 +0000
    [send_started] => Tue, 26 Mar 2019 18:06:55 +0000
    [finished] => Tue, 26 Mar 2019 18:06:55 +0000
    [sent] => Array
    (
    [constants] => 1
    [functions] => 1
    [options] => 1
    [users] => 1
    )

    [queue] => Array
    (
    [constants] => 1
    [functions] => 1
    [options] => 1
    [users] => 1
    )

    [config] => Array
    (
    [options] => 1
    [functions] => 1
    [constants] => 1
    [users] => Array
    (
    [0] => 1
    )

    )

    [total] => Array
    (
    [constants] => 1
    [functions] => 1
    [options] => 1
    [users] => 1
    )

    )
    `
    Sync Queue size: 32
    Sync Queue lag: 22 seconds
    Full Sync Queue size: 0
    Full Sync Queue lag: 0 seconds
    Sync IDC URLs: {“home”:”https:\/\/2ontherun.com”,”siteurl”:”https:\/\/2ontherun.com\/wordpress”,”WP_HOME”:””,”WP_SITEURL”:””}
    Sync error IDC option: false
    Sync IDC Optin: 1

    HTTP_HOST: 2ontherun.com
    SERVER_PORT: 443
    HTTPS: on
    REMOTE_ADDR: 67.161.56.183
    PROTECT_TRUSTED_HEADER: {“trusted_header”:”REMOTE_ADDR”,”segments”:1,”reverse”:false}

    TEST RESULTS:

    FAILED TESTS!
    test__wpcom_self_test: Jetpack.com detected an error.
    Array
    (
    [0] => Array
    (
    [name] => test__check_if_connected
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [1] => Array
    (
    [name] => test__master_user_exists_on_site
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [2] => Array
    (
    [name] => test__master_user_can_manage_options
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [3] => Array
    (
    [name] => test__xml_parser_available
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [4] => Array
    (
    [name] => test__outbound_http
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [5] => Array
    (
    [name] => test__outbound_https
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [6] => Array
    (
    [name] => test__identity_crisis
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [7] => Array
    (
    [name] => test__wpcom_connection_test
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [8] => Array
    (
    [name] => test__server_port_value
    [pass] => 1
    [message] => Test Passed!
    [resolution] =>
    [group] => Array
    (
    [0] => default
    )

    )

    [9] => Array
    (
    [name] => test__wpcom_self_test
    [pass] =>
    [message] => Jetpack.com detected an error.
    [resolution] => Visit the Jetpack.com debugging page for more information or contact support.
    [group] => Array
    (
    [0] => default
    )

    )

    )

    I realized I probably wasn’t clear on the description of delays in the previous message.
    normally it seemed to add 1, maybe 2 seconds (ie a successful connection with a tcp rtt). While testing things out it suddenly hit more like 5+ seconds between every click, at which point I disabled the plugin. I ran without the plugin for the past 5 or so days, and just re-enabled it again to do the test above, and saw the 1 second roughly delay compared to not having it.

    In the past in my testing I went as far as deleting the plugin, reinstalling, and then disabling every option from the “single-page” configuration, and saw the same lag issue.

    Plugin Author Brandon Kraft

    (@kraftbj)

    Code Wrangler

    Thanks Matt for all of the details and work on this issue. It’s tough. There was one other site that reported this type of problem and I was never able to isolate exactly what caused it.

    What I’d do as a next step is install the Query Monitor plugin by John Blackborne. He’s a WordPress core committer and a former member of the WordPress.com VIP team. The plugin is at https://wordpress.org/plugins/query-monitor/

    Especially when you see the problem, click on the item it adds to the admin bar at the top and it’ll a “Developer Console” akin to Chrome/Firefox’s. It’ll have profiling information about queries, HTTP calls, etc — see some examples at https://cloudup.com/cMtr8Lw7WbD

    One gut thought is a HTTP call to WordPress.com/Jetpack server is taking surprisingly long—maybe something there that we can investigate. Maybe there is some database query that is problematic with Jetpack is enabled.

    I hate to see it’s a bit of a hunt, but it may just be. Please let me know how you’d like me to help.

Viewing 14 replies - 16 through 29 (of 29 total)
  • The topic ‘Save Draft causing hang and 403 with Gutenberg’ is closed to new replies.