SQL backups require a folder which is shared between the host where the SQL server is running and the host where ubackup is running. SQL Server can only back up a database to a file system to which it has access. Once the backup is in the shared folder it is then transferred to the final folder or the FTP server defined in ubackup. The shared folder is only used for temporary files.
Both the container running SQL Server and ubackup must be able to access the folder that is shared between them. This can be accomplished by adding a bind mount to both containers (SQL Server and ubackup). If SQL Server is not running in a container, simply use a shared folder that ubackup has access to and provide the bind mount to ubackup only.
For example, if the database server is defined to use the folder /tmp/sql (in Backup > Settings, SQL Tab) as SQL Temp. Folder, this can be mapped to a host folder using a bind mount. We'll name the host folder /host/tmp/sql. The bind mount would look as follows:
Add such a bind mount to ubackup and the SQL server container. If SQL Server is not running in a container, SQL Server must have access to /host/tmp/sql.
The following shows an excerpt of a docker-compose file with the bind mount used above.
volumes: - /host/tmp/sql:/tmp/sql
When running on Windows/IIS, no configuration is required as long as both the ubackup host and the SQL Server host can access the shared folder.
For a shared folder C:\Host\Temp\SQL, using a command line prompt, give the following permissions to the ubackup application pool so it has full access to the folder:
icacls C:\Host\Temp\SQL /grant "IIS APPPOOL\ubackup:(OI)(CI)F"
ubackup.io - © Copyright 2021 Softel vdm, Inc.