

{"id":6633,"date":"2016-10-03T01:17:33","date_gmt":"2016-10-02T23:17:33","guid":{"rendered":"http:\/\/catalinx.ro\/wordpress\/?p=6633"},"modified":"2016-10-03T01:22:02","modified_gmt":"2016-10-02T23:22:02","slug":"test124345","status":"publish","type":"post","link":"https:\/\/catalinx.ro\/wordpress\/?p=6633","title":{"rendered":"WordPress Crash. Cannot Add New Post."},"content":{"rendered":"<div id=\"fb-root\"><\/div>\n<p>I spent my last hour debugging through wordpress as I could not add any new post , or upload anything from mobile.<\/p>\n<p>It crashed last evening when I was trying to correct a draft from mobile. I have the feeling that the mobile app from WordPress does not close the wp_posts table correctly. Or something \ud83d\ude42<\/p>\n<p>Initially I didn&#8217;t know what&#8217;s the issue . In the morning I was trying to write something from the computer and found \u00a0that when \u00a0trying to Add New Post from the menu, it would open it up without any Main Text.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"6630\" data-permalink=\"https:\/\/catalinx.ro\/wordpress\/?attachment_id=6630\" data-orig-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpresss_add_new-post.png\" data-orig-size=\"471,205\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"wordpresss_add_new-post\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpresss_add_new-post.png\" class=\"alignnone size-full wp-image-6630\" src=\"http:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpresss_add_new-post.png\" alt=\"wordpresss_add_new-post\" width=\"471\" height=\"205\" srcset=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpresss_add_new-post.png 471w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpresss_add_new-post-300x131.png 300w\" sizes=\"auto, (max-width: 471px) 100vw, 471px\" \/><\/p>\n<p>Like this .<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"6631\" data-permalink=\"https:\/\/catalinx.ro\/wordpress\/?attachment_id=6631\" data-orig-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken.png\" data-orig-size=\"1245,761\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"addnewpost_broken\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken-1024x626.png\" class=\"alignnone size-full wp-image-6631\" src=\"http:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken.png\" alt=\"addnewpost_broken\" width=\"1245\" height=\"761\" srcset=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken.png 1245w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken-300x183.png 300w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken-768x469.png 768w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken-1024x626.png 1024w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/AddNewPost_broken-640x391.png 640w\" sizes=\"auto, (max-width: 1245px) 100vw, 1245px\" \/><\/p>\n<p>Well done WP mobile app! \u00a0I have checked on the internet for solutions of course \u00a0and got to the page that <a href=\"http:\/\/wordpress.stackexchange.com\/questions\/118770\/cannot-create-a-new-post\">tells you to \u00a0enable the debug<\/a>. Which I did and got this output below, that basically shows a duplicate key message from DB for the post id in the table <strong>wp_post<\/strong>:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" data-attachment-id=\"6632\" data-permalink=\"https:\/\/catalinx.ro\/wordpress\/?attachment_id=6632\" data-orig-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id.png\" data-orig-size=\"1547,554\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"wordpress_duplicate_key_post_id\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id-1024x367.png\" class=\"alignnone size-full wp-image-6632\" src=\"http:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id.png\" alt=\"wordpress_duplicate_key_post_id\" width=\"1547\" height=\"554\" srcset=\"https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id.png 1547w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id-300x107.png 300w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id-768x275.png 768w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id-1024x367.png 1024w, https:\/\/catalinx.ro\/wordpress\/wp-content\/uploads\/2016\/10\/wordpress_duplicate_key_post_id-640x229.png 640w\" sizes=\"auto, (max-width: 1547px) 100vw, 1547px\" \/><\/p>\n<p>I have checked in mysql ( you do have \u00a0to take a backup of \u00a0your wordpress DB before doing that , I am just too good for it &#8211; kidding , I had one from yesterday). There I have only 6628 posts, there&#8217;s no duplicate on 6629 ,but obviously there is something wrong, because\u00a0I would get same issue while trying to manually add new line in mysql.<\/p>\n<p>I have checked the <em>autoincrement<\/em> and it was fine. But the table was not fine when I made a mysql check. \u00a0It&#8217;s stored as myISAM.<\/p>\n<p><code>check table wp_posts; <\/code><\/p>\n<p><code>db_wordpress.wp_posts check warning Table is marked as crashed<\/code><br \/>\n<code>db_wordpress.wp_posts check warning 22 clients are using or haven't closed the table properly<\/code><br \/>\n<code>db_wordpress.wp_posts check error Found key at page 36192256 that points to record outside datafile<\/code><br \/>\n<code>db_wordpress.wp_posts check error Corrupt<\/code><\/p>\n<p>I have ran the \u00a0repair table and everything is back to normal. I think :).<\/p>\n","protected":false},"excerpt":{"rendered":"<p>I spent my last hour debugging through wordpress as I could not add any new post , or upload anything from mobile. It crashed last&hellip;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[7,1055,229],"tags":[1407,1406,1405],"class_list":["post-6633","post","type-post","status-publish","format-standard","hentry","category-administrare-it","category-english","category-tech","tag-cannot-add-new-post","tag-wordpress-crash","tag-wp_posts-duplicate-id"],"views":2335,"jetpack_publicize_connections":[],"jetpack_featured_media_url":"","jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p4Eq23-1IZ","jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/6633","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=6633"}],"version-history":[{"count":6,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/6633\/revisions"}],"predecessor-version":[{"id":6639,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=\/wp\/v2\/posts\/6633\/revisions\/6639"}],"wp:attachment":[{"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=6633"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=6633"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/catalinx.ro\/wordpress\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=6633"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}