/
/
Error "Failed to download file or folder from backup"

Error "Failed to download file or folder from backup"

Symptoms

When trying to download backup files, restore individual sites from a backup, or view a backup archive from the file manager, the error "Failed to download a file or folder from backup. Check settings, availability of the file, or folder in the storage".

Causes

This error occurs when the panel cannot access the backup files when FTP storage is used. There may be several reasons for this:

  • Incorrect credentials have been set for connecting to the FTP storage;
  • The backup files are missing;
  • Port 21 is closed;
  • The FTP service is not running.

Solution

Validating the credentials for connecting to FTP storage

To verify that the credentials are correct, you can use either the built-in FTP client or a third-party one, for example, "FileZilla". To learn how to use Windows FTP-clients and FileZilla see the article, Connecting and working on the server via FTP/SFTP.

To connect to an FTP server from Linux, open the terminal or server console and follow these steps:

  1. Enter the command ftp;
  2. In the second line that appears, with ftp>, type open <ip-address> where <ip-address> is the IP address of the FTP storage;
  3. In the line with Name: enter the user login for the FTP storage;
  4. In the line with Password:, enter the password for the FTP storage.

If you connect successfully, the system will display the string ftp> again which means that the connection to the FTP server has been established and you have gotten into the FTP server environment.

 

If you enter an incorrect user name or password, an error will appear in the console "530 Login authentication failed".

After verifying that the user name and password for the FTP storage are correct, ensure that these are the credentials specified in the backup settings in your ispmanager panel:

  1. Go to "Backups" - "Settings".

     
  2. In the tab that opens, check the "User" and "Password" fields. To see the current password, click on the eye icon in the "Password" field.
     
  3. Change the credentials if necessary and click the "Save" button.

Checking that the backup files are available

The backup files in the repository are stored in directories with names that correspond to the user name. The path to these directories starts from the directory set in the "Path to the directory" field. Check that this directory contains the directories with the user name. There should also be directories with the date of copy creation, containing files named as follows:

  • <creation-date>.<user>.info
  • <creation-date>.<user>.tgz

In the console, you can do this with the ls command:

ls -lah <path-to-the-directory>

You can connect to the storage via FTP or SSH and use the specified commands to view the files.

Example of how to use the command

 

If you are connecting using a graphical FTP client, simply check for backup files in the appropriate directories.

Checking access to FTP storage

To check if the FTP storage is available, connect to it via SSH and run one of the following commands:

telnet <storage-address> 21
nmap <storage-address> -p21

 

If the system returns a "Command not found" error, then the appropriate utility has not been installed.

You can install these utilities through the operating system's package manager:

  • apt install nmap telnet - for Debian and Ubuntu
  • yum install nmap telnet - for RHEL systems (e.g. CentOS and AlmaLinux)

If you connect to the storage using "telnet", the system will return the following output:

telnet <storage-address> 21
Trying <ip-address>...
Connected to ftp.example.com.
Escape character is '^]'.

This verifies that you have connected to the repository via "telnet". To end the "telnet" connection press Ctrl+] and then Ctrl+D.

If the port is closed on the storage side, the connection will stop on the next line:

Trying <ip-address>...

If an accessibility check via "nmap" has been performed, the correct output will look like this:

Starting Nmap 7.80 ( https://nmap.org ) at 2024-06-26 08:07 MSK
Nmap scan report for example.com (<ip-address>)
Host is up (0.030s latency).
rDNS record for <ip-address>:<storage-address>
PORT   STATE SERVICE
21/tcp open  ftp

If the port is closed on the storage side, the output will be as follows:

Starting Nmap 7.80 ( https://nmap.org ) at 2024-06-26 08:07 MSK
Nmap scan report for example.com (<ip-address>)
Host is up (0.030s latency).
rDNS record for <ip-address>:<storage-address>
PORT   STATE SERVICE
21/tcp closed  ftp

To open the port, you need to change the network settings on the server or higher-level hardware (e.g., router). To do so, contact the server administrator or tech support of the hosting provider if you are using one.

Checking the FTP server service

If you’re using ProFTPD as the FTP server, check the status of the FTP server service using the command:

systemctl status proftpd

If the service is running and active, the output will contain the string "Active: active (running)", for example:

systemctl status proftpd
● proftpd.service - LSB: Starts ProFTPD daemon
     Loaded: loaded (/etc/init.d/proftpd; generated)
     Active: active (running) since Sun 2024-06-23 00:00:04 MSK; 3 days ago
       Docs: man:systemd-sysv-generator(8)
      Tasks: 1 (limit: 4595)
     Memory: 6.4M
     CGroup: /system.slice/proftpd.service
             └─1812732 proftpd: (accepting connections)

If the output contains the string "Active: inactive (dead)", then the service is not running. To try to start the service, enter the following command:

systemctl start proftpd

Then, check the status of the FTP server service again, and, if the service also hasn’t been started or has a status other than "Active: active (running)", analyze the FTP server log and the system log to find out why the service wasn’t be started:

  • The path to the ProFTPD FTP server log is /var/log/proftpd/proftpd.log
  • The path to the system log is /var/log/syslog or /var/log/messages

To display system log entries about the ProFTPD FTP server service, run the following command:

journalctl -eu proftpd

 

To check the status of FTP server services other than ProFTPD, use the commands corresponding to your operating system and FTP server:

  • For Windows, you can use cmdlet in PowerShell:
    Get-Service -Name "ftpsvc"
  • For most Linux distributions, use the command:
    systemctl status vsftpd
  • To check the status of the FileZilla Server service on Windows, use the command:
    sc query FileZillaServer
  • To check the status of the Titan FTP Server service on Windows, use the command:
    sc query TitanFTP
  • To check the status of the WS_FTP Server service on Windows, use the command:
    sc query WS_FTP
  • To check the status of the Syncplify.me Server! service on Windows, use the command:
    sc query "SyncplifyMeServer"

 

Keep in mind that each FTP server may have its own specific commands and ways to check the service status, so refer to the official documentation of each server for more details.