简体   繁体   中英

Wordpress Error 500 (Internal Server Error)

Last week, I moved the wordpress instance to new server. After that I frequently get 500 Internal Server Error. This error comes all of the sudden. The apache error log does not contain any fatal error messages but it contains PHP warning messages.

Whenever this error occurs, I restart the apache and the site is back to normal state. What may be the reason for this 500 Internal Server Error?

How does restarting apache solves this error? Only this site gets this error, other sites deployed to this server are working fine.

One of the reasons why wordpress urls contained in the BD pointing to the url old, running this script in phpmyadmin can solve:

UPDATE wp_options SET option_value = REPLACE(option_value,'old_site','new_site');
UPDATE wp_posts SET post_content = REPLACE(post_content,'old_site','new_site');
UPDATE wp_posts SET guid = REPLACE(guid,'old_site','new_site');
UPDATE wp_postmeta SET meta_value = REPLACE(meta_value,'old_site','new_site');

Also exist the possibility that your hosting account contains a folder with your username, in the wp_options table may be included, for example upload_path: "/home/[folder_old_id]/public_html/wp-content/uploads"

UPDATE wp_options SET option_value = REPLACE(option_value,'folder_old_id','folder_new_id');

Wordpress internal server error, 500 Internal Server Error Solved!

firstly login admin dashboard in wordpress

  1. go to setting
  2. select option permalink
  3. change option and select post url format in all option list and save it
  4. check visit our page where error is come ...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM