Validation issue Validator "Restore" returned fail status File Unable to prepare restore script.
|
Posted 04 June 2017 - 03:31 AM #1
Validation issue Validator "Restore" returned fail status File Unable to prepare restore script.
Posted 05 June 2017 - 05:19 AM #2
Usually the issue caused by the following reasons:
- wrong permissions on the restore.php file
- file cannot be reached by direct URL
Start from checking these points at first
Posted 19 June 2017 - 04:50 PM #3
I tried to upgrade my store again, and checked my log file what it shown :
2017-06-19 19:41:28: Executing "Accounting Migration Confirmation" validator 2017-06-19 19:41:28: Executing "Core Changes Confirmation" validator 2017-06-19 19:41:29: Executing "collisions" validator 2017-06-19 19:41:29: Executing "permissions" validator 2017-06-19 19:41:29: Executing "restore" validator 2017-06-19 19:41:29: Backup filename is "upg_core_4.4.3-4.5.1_19Jun2017_194128" 2017-06-19 19:41:29: Preparing restore script 2017-06-19 19:41:29: Upgrades directory permissions: drwxr-xr-x [****:******] 017-06-19 19:41:29: Source restore script permissions: -rw-rw-rw- [****:******] 2017-06-19 19:41:29: Directory "/[severname]/upgrades/core_4.4.3-4.5.1/" for restore script already created 2017-06-19 19:41:29: Unable to create restore script at "[severname]/upgrades/core_4.4.3-4.5.1/restore_2017-06-19_19-41-28.php" 2017-06-19 19:41:29: Upgrade stopped: unable to prepare restore file.
I checked the answer by eComlabs at : http://forum.cs-cart...re-restore-file, too.
Could you please help me to resolve it.
Thanks!
Posted 20 June 2017 - 06:40 AM #4
In the config.local.php file try to change
define('DEFAULT_FILE_PERMISSIONS', 0666); define('DEFAULT_DIR_PERMISSIONS', 0777);
with
define('DEFAULT_FILE_PERMISSIONS', 0644); define('DEFAULT_DIR_PERMISSIONS', 0755);
Posted 20 June 2017 - 02:35 PM #5
In the config.local.php file try to change
define('DEFAULT_FILE_PERMISSIONS', 0666); define('DEFAULT_DIR_PERMISSIONS', 0777);with
define('DEFAULT_FILE_PERMISSIONS', 0644); define('DEFAULT_DIR_PERMISSIONS', 0755);
I tried and it's nothing changed, still stopped upgrading
2017-06-20 17:30:36: Source restore script permissions: -rw-r--r-- dotadb93:dotadb93 2017-06-20 17:30:36: Directory "/home/dotadb93/public_html/upgrades/core_4.4.3-4.5.1/" for restore script already created 2017-06-20 17:30:36: Unable to create restore script at "/home/dotadb93/public_html/upgrades/core_4.4.3-4.5.1/restore_2017-06-20_17-30-34.php" 2017-06-20 17:30:36: Upgrade stopped: unable to prepare restore file.
what thing should i do to upgrade the store?
Posted 21 June 2017 - 05:35 AM #6
PM me temporary FTP access to your server so that we can check the issue
Posted 28 June 2017 - 01:30 PM #7
Thank you so much! the problem was my low disk space and now I can upgrade my store normally.
Posted 28 June 2017 - 02:07 PM #8
Thank you so much! the problem was my low disk space and now I can upgrade my store normally.
Note that some additional code changes in the upgrade script were also made
Posted 14 August 2017 - 09:02 PM #9
Hi,
I get the same warning when I want to upgrade from 4.6.1. to 4.6.2.
Changing the directory & file permissions didn't work for me and I have enough disk space.
Any other possibilities I could try?
Thanks,
Ralph
Posted 15 August 2017 - 06:34 AM #10
Hi,
I get the same warning when I want to upgrade from 4.6.1. to 4.6.2.
Changing the directory & file permissions didn't work for me and I have enough disk space.
Any other possibilities I could try?
Thanks,
Ralph
Please check the upgrade log (var/upgrade/core_log.txt)
Posted 15 August 2017 - 12:48 PM #11
Please check the upgrade log (var/upgrade/core_log.txt)
Thanks! Here's my log:
2017-08-14 23:58:36: Starting installation of the "core" upgrade package 2017-08-14 23:58:36: Upgrading version 4.6.1 to 4.6.2 2017-08-14 23:58:36: Running as user "hennepplaza" 2017-08-14 23:58:36: Storing entry point files permissions... 2017-08-14 23:58:36: index.php ==> 33188 (-rw-r--r--) 2017-08-14 23:58:36: admin-cs-shop.php ==> 33188 (-rw-r--r--) 2017-08-14 23:58:36: api.php ==> 33188 (-rw-r--r--) 2017-08-14 23:58:36: vendor.php ==> 33188 (-rw-r--r--) 2017-08-14 23:58:36: ==> 16877 (drwxr-xr-x) 2017-08-14 23:58:36: Executing pre-upgrade validators 2017-08-14 23:58:36: Found 0 validators at package 2017-08-14 23:58:36: Executing "collisions" validator 2017-08-14 23:58:36: Executing "permissions" validator 2017-08-14 23:58:36: Executing "restore" validator 2017-08-14 23:58:36: Backup filename is "upg_core_4.6.1-4.6.2_14Aug2017_235835" 2017-08-14 23:58:36: Preparing restore script 2017-08-14 23:58:36: Upgrades directory permissions: drwxr-xr-x hennepplaza:hennepplaza 2017-08-14 23:58:36: Source restore script permissions: -rw-r--r-- hennepplaza:hennepplaza 2017-08-14 23:58:36: Directory "/home/hennepplaza/public_html/upgrades/core_4.6.1-4.6.2/" for restore script already created 2017-08-14 23:58:36: Created restore script at "/home/hennepplaza/public_html/upgrades/core_4.6.1-4.6.2/restore_2017-08-14_23-58-35.php" 2017-08-14 23:58:36: Restore script permissions: -rw-r--r-- hennepplaza:hennepplaza 2017-08-14 23:58:36: Correcting target restore script directory permissions... 2017-08-14 23:58:36: ---------- 2017-08-14 23:58:36: Changing permissions of "/home/hennepplaza/public_html/upgrades/core_4.6.1-4.6.2/" to 755 2017-08-14 23:58:36: Using chmod()... OK 2017-08-14 23:58:36: ---------- 2017-08-14 23:58:36: Target restore script directory permissions: drwxr-xr-x hennepplaza:hennepplaza 2017-08-14 23:58:36: Correcting upgrades directory permissions... 2017-08-14 23:58:36: ---------- 2017-08-14 23:58:36: Changing permissions of "/home/hennepplaza/public_html/upgrades" to 755 2017-08-14 23:58:36: Using chmod()... OK 2017-08-14 23:58:36: ---------- 2017-08-14 23:58:36: Upgrades directory permissions: drwxr-xr-x hennepplaza:hennepplaza 2017-08-14 23:58:36: Checking restore script availability via HTTP 2017-08-14 23:58:36: Restore script is NOT available via HTTP at "http://hennepplaza.com/upgrades/core_4.6.1-4.6.2/restore_2017-08-14_23-58-35.php". 2017-08-14 23:58:36: Upgrade stopped: unable to prepare restore file.
And reading those last three lines our store is over HTTPS. Does that make any difference?
Posted 23 November 2018 - 03:43 PM #12
Getting this same error with 4.9.2 upgrade, how did you fix the issue?
Posted 26 November 2018 - 06:07 AM #13
You should find a reason why this file is no accessible through direct URL
Posted 26 November 2018 - 02:24 PM #14
You should find a reason why this file is no accessible through direct URL
it was a cs-cart bug
Posted 26 November 2018 - 02:36 PM #15
Exactly the same error is not updated. Restore file is not available, curl does not detect it. The problem apparently in the settings NGINX. And specifically in the directory:
location ~ ^/(\w+/)?(\w+/)?var/restore/ { return 404; }
Config configured according to official documentation. That seems to be the problem here:
So I think developers should pay attention and help customers!
Posted 26 November 2018 - 02:51 PM #16
Exactly the same error is not updated. Restore file is not available, curl does not detect it. The problem apparently in the settings NGINX. And specifically in the directory:
location ~ ^/(\w+/)?(\w+/)?var/restore/ { return 404; }Config configured according to official documentation. That seems to be the problem here:
So I think developers should pay attention and help customers!
Amendment! It is necessary to add a directory to the NGINX configuration:
location ~ ^/(\w+/)?(\w+/)?upgrades/ { allow all; }
then the file will be available on https, but the check is on http. but how to fix it, any ideas?
then the file will be available on https, but the check is on https. but how to fix it, any ideas?
Posted 18 June 2019 - 06:25 AM #17
I have the same issue when upgrading from 4.9.3.SP1 - 4.10.1.
Validator "Restore" returned fail status
The file permision is fine and I have enough space on server.
Any ideas?
Posted 19 June 2019 - 03:04 PM #18
It seems that the website had password protected directory that caused the issue