Are you experiencing issues during the backup scan step, such as warnings, errors, or timeouts? This article provides solutions to common problems related to file structure, permissions, and server configurations that can cause these issues. We’ll walk you through step-by-step solutions for these issues.
File Structure
Resolving scan issues related to your server’s file structure can be frustrating. This section will guide you through common issues like symbolic links, large file counts, unreadable files, and more, providing step-by-step solutions to get your scans running smoothly again:
Symbolic Links
Links that point to themselves can cause a recursive loop. Check the file system for directory links that link to itself. For example, if /public_html/mydir points back topublic_html/ then that might create a recursive loop for PHP in which case you would need to filter public_html/mydir/.
To check for symbolic links, go to Duplicator » Tools » General » Scan Validator, and click the button Run Scan Integrity Validation. This will find sym-links and unreadable files. When the scan is complete, add the full path(s) of the “Symbolic Links” to the directory filter list in Step 1 of the backup creation process.
If the scan validator does not pick up files, go into your host’s file manager and look for anything that would cause this (for instance, that may look like /dir1, and if you go into /dir1, it would contain the contents of /, which would mean it would also include /dir1, etc). For these types of directories/links, enable file filters and add the full directory paths to the directories box when you are creating a backup.
Large File Counts
For some budget host setups with timeouts enabled, large file counts might cause the scan to time out. If PHP or Apache timeouts are set to low, and you’re trying to scan 250k+ files, then the process may not be able to scan all the files.
To resolve, go to Backups,» Create New,» Step 1, Archive Directory filters, and add a filter to the directory with the large file count. The recommended approach is to increase your PHP and Web Server timeouts so the scan has time to finish.
Unreadable Files
On some systems, certain utf8 characters can cause the scan to have issues. This is a very uncommon issue and typically more prevalent on Windows operating systems running lower versions of PHP.
To check for unreadable files from within the plugin, go to Duplicator » Tools » General » Scan Validator » Run Scan Integrity Validation”. This will run a scan check that will look for unreadable files. When the scan is complete, add the path(s) of the “Unreadable Files” to the directory filter list in Step 1 of the backup creation process.
No Files Found
If you run a scan and the results show no files being found, In your server could be configured with “server separation”. You will need to contact your hosting provider for more details; however, this can be an issue on some systems. Possible options in the Domain Configuration window are:
No forwarding
- Forward to subfolder without service separation.
- Forward to subfolder with service separation.
- Forward to IP/Host/URL.
Switching temporarily to #2 will allow the Duplicator to run without issues for both the backup and installer.
403 Forbidden
When encountering a 403 Forbidden error, it can be challenging to troubleshoot and resolve the issue. This section will guide you through common causes of 403 errors, including permission issues, mod_security rules, and plugin/theme conflicts, providing solutions to get your scanner up and running again.
Common Error Messages:
- Forbidden: You don’t have permission to access wp-admin/xyz.php on this server.
- 403 Forbidden error was encountered.
Solution 1
A permission issue might be related to a file/directory or the .htaccess file. Try changing the permission of your host’s root .htaccess file to 755, then try the request a few times to see if it starts the scan. If the issue persists, try contacting your host.
Solution 2
Check with your host for any mod_security rules that might be causing the issue, and ask them to whitelist the rule causing the issue on your host.
Also see:
What can I do for issues with migrating a large site?
What can I try for 502/503/504 Gateway issues during the scan/build?
Recommended hosting providers for Duplicator?
Solution 3
In some cases, a poorly written plugin or theme could have code that conflicts with Duplicator. To resolve plugin/theme conflicts, see Why is the Duplicator user interface (UI) not working?
500 errors
Most 500 web server errors can be difficult to track-down as they are being thrown from the web server and not PHP. Below are several options you can try for 500/502/503/504 gateway issues with the scanner.
Solution 1
Config Update
Consider the following updates to the .htaccess file:
- Option 1: Change the dynamic value for Ajax calls
<IfModule mod_timeout.c>
<Files ~ ".php">
SetEnvIf Request_URI "admin-ajax" DynamicTimeout=240
</Files>
</IfModule> - Option 2: Update the .htaccess file from the file manager interface (Path: public_html/.htaccess) and also increase the max_execution_time limit from 300 to 3000from the Select PHP version interface provided in cPanel.
<IfModule Litespeed>
RewriteEngine On
RewriteRule .* - [E=noabort:1, E=noconntimeout:1]
</IfModule>
Solution 2
Cloudflare
If you’re using Cloudflare, the below settings may help
- Log in to Cloudflare
- From Overview Page click “Advanced” » Click “Pause”
- Run installer deployment
- Turn Cloudflare back on
Solution 3
Contact Hosting Provider
Connect with your hosting provider and let them know you’re getting a 500 error. Many times, your host will have access to the web server logs, which can help isolate what is triggering the error on their server configurations. In some cases, the host may be able to provide enough information to give you a status as to why the 500 error is being thrown. This information, in some cases, can help us try different configurations in the host’s environment.
Upgrade:
Ask your host if they are running the latest version of a web server software such as Apache or nginx. Many times, hosts will run a very outdated version of software, which will have patches and fixes for the issue you’re experiencing.
Solution 4
General Troubleshooting
There are several troubleshooting protocols you can implement to validate if the issue is indeed a networking issue between your browser and the server. If you can try from a different computer or even a different browser, that can sometimes isolate the issue. For a full run-down of various ways to fix this issue, please see this article on Understanding and Fixing 502 Bad Gateway Errors.
Also see:
What can I try for 502/503/504 Gateway issues during the install?
Recommended hosting providers for Duplicator?
JSON Service
Do you get the error message ‘Unable to read JSON from service’ during the backup scan? The following steps can help you resolve this issue:
- Go to Duplicator Pro » Settings » Backups » Advanced Settings.
- Change Thread Lock Type to SQL.
- Retry building a backup.
Troubleshoot
The following are general troubleshooting steps that help to resolve the backup scan issues:
Option 1
Go to Backups » Create New » Choose “Database Only”. This will build only the database and let you know if there is an issue with a specific file or directory. If the scanner is complete, there is an issue with one of the files in your system. In this case, you can follow these steps:
- Go back to step one “1-Setup” and click the [root path] quick link to add the WordPress root directory as a filter, then run the scanner.
- If this works, continue adding and removing directories until you locate the problem area. Start with the top-most directories and work your way down. If not, see “Option 2” below.
Option 2
If you have already tried all the solutions mentioned earlier, and it still doesn’t work, please check your PHP error log and contact your hosting provider.