Why do I receive "Internal Server Error" and how to fix it?
This kind of error appears usually on websites hosted on shared hosting solutions. Such hostings usually have a certain number of CPU threads that can run in parallel and when this limit is reached ShortPixel will start returning such "Internal Server Error" messages.
Here are the usual steps to address this kind of issue:
- Make sure you don't run already a CPU&HDD intensive task like making a backup with your website. If you're running such a resource-intensive task just wait for it to finish before trying to run the image optimization again.
- Check out your plugins and see if you have 2-3 plugins that you could temporary deactivate. Once you deactivate them just try again to run ShortPixel Image Optimizer. On most occasions, doing this frees up enough CPU resources to be able to finish optimizing the images on your website.
If this does not help, please contact your hosting provider so they can further assist you.
Sometimes, if you are running a multisite, you will see this message or a similar one:
Error: There was an error and your request was not processed. (20190603_190924.jpg: Could not download file (500 Internal Server Error).)
The error may be related to the upload paths. Basically when you upload to a subdomain (if you’ve configured the secondary site in a WP multisite to be a subdomain) by default the upload path in the multisite’s database (it’s just one database) is still set to the main site. This means the images don’t appear in the subdomain’s media library (only when you click on them to edit, but this doesn’t make a difference) and the subdomain hasn’t been told how to ‘download’ them from the main site upload location.
Warning: make a backup of your database first!
The possible solution is to access the database, table wp-options, look for ‘upload path’ and change this. This is what you will probably see:
Change it to
And it should work. Both the main and sub-domain can access this path.