johngodley / redirection

Manage all your WordPress 301 redirects and monitor 404 errors
https://redirection.me
GNU General Public License v3.0
559 stars 140 forks source link

WordPress database error Unknown column 'domain' in 'field list' for query INSERT INTO `wp_redirection_logs` #2899

Closed rodneyjoyce closed 3 years ago

rodneyjoyce commented 3 years ago

Hi,

I am getting this error message constantly in my Error Logs. I think that this table (wp_redirection_logs) is part of the Redirection plugin, and I am on the latest version of both WP (5.7.1) and this plugin (5.1.1). I am on PHP 7.4

2021/05/07 12:16:40 [error] 39203#39203: *144819 FastCGI sent in stderr: "PHP message: WordPress database error Unknown column 'domain' in 'field list' for query INSERT INTOwp_redirection_logs(url,domain,ip,created,agent,request_method,http_code,redirection_id,sent_to,redirect_by) VALUES ('/DesktopModules/DnnForge - NewsArticles/Controls/ImageChallenge.captcha?captcha=9C3DCF63A19603E1565F12EC28B2449C7D13660997CB6AA1452258F4E02F8148BC27D9F98703041AF5B914D693FC0893EF5D327C493995DFCF7E1691FFC5B91B428C1BC324E1A7CCA8190AF7EAE0202A0FD485EBA7AF694B9C571C5470E381E8AB8D71AA127D1369404EE2C975D8D30E5D93B76E65A3C44780AAF6B85BA7F1EB2195F9BD0D08C087FFFA4E4D794B5A2E34D95D1EE9D208E7FE05C90BF212CC513FB23161&alias=www.pokerdiy.com', 'https://pokerdiy.com', '114.119.141.168', '2021-05-07 05:16:40', 'Mozilla/5.0 (Linux; Android 7.0;) AppleWebKit/537.36 (KHTML, like Gecko) Mobile Safari/537.36 (compatible; PetalBot;+https://webmaster.petalsearch.com/site/petalbot)', 'GET', '301', '140', 'http://pokerdiy.com/', 'redirection') made by require('wp-blog-header.p" while reading response header from upstream, client: 114.119.141.168, server: pokerdiy.com, request: "GET /DesktopModules/DnnForge%20-%20NewsArticles/Controls/ImageChallenge.captcha?captcha=9C3DCF63A19603E1565F12EC28B2449C7D13660997CB6AA1452258F4E02F8148BC27D9F98703041AF5B914D693FC0893EF5D327C493995DFCF7E1691FFC5B91B428C1BC324E1A7CCA8190AF7EAE0202A0FD485EBA7AF694B9C571C5470E381E8AB8D71AA127D1369404EE2C975D8D30E5D93B76E65A3C44780AAF6B85BA7F1EB2195F9BD0D08C087FFFA4E4D794B5A2E34D95D1EE9D208E7FE05C90BF212CC513FB23161&alias=www.pokerdiy.com HTTP/1.0", upstream: "fastcgi://unix:/var/run/php8.0-fpm-pokerdiy.sock:", host: "pokerdiy.com"

In the Support page, the selected Database is showing as 2.3.1 and there are much higher versions in the list: https://i.imgur.com/NY156Ka.png

It sounds like it might be a code and DB mismatch, so might the fix be that it is not set to use the latest DB?

and lastly - thanks for all the hardwork on this plugin and for making it free - that is very kind of you!

johngodley commented 3 years ago

Sure, your site thinks you've upgraded your database but it hasn't. Usually this happens when you are using a caching system which is affecting your REST API. You can change the database version to the latest and see if it manages to escape your cache.

johngodley commented 3 years ago

Closing for now, please reopen with more information.