[MDEV-17008] restore using mariabackup where data files are not in target-dir - Service fails to start Created: 2018-08-17  Updated: 2020-05-18  Resolved: 2019-05-03

Status: Closed
Project: MariaDB Server
Component/s: Backup, mariabackup
Affects Version/s: 10.3.8
Fix Version/s: 10.2.24, 10.3.15, 10.4.5

Type: Bug Priority: Trivial
Reporter: Julian Edwards Assignee: Vladislav Vaintroub
Resolution: Fixed Votes: 0
Labels: mariabackup
Environment:

Windows Server 2012 R2 Standard
RAM 8GB
4 core xeon e5-2407


Attachments: File C92012.err    

 Description   

Backup using
mariabackup --backup --target-dir F:\MD-Backup\ --user Buser --passsword XXX
successful
Prepare
mariabackup --prepare --target-dir F:\MDB_Backup\ --user Buser --password XXX
result
mariabackup based on MariaDB server 10.3.8-MariaDB Win64 (AMD64)
mariabackup: cd to F:\MDB_Backup\Restore\
mariabackup: This target seems to be not prepared yet.
mariabackup: using the following InnoDB configuration for recovery:
mariabackup: innodb_data_home_dir = .
mariabackup: innodb_data_file_path = ibdata1:10M:autoextend
mariabackup: innodb_log_group_home_dir = .
mariabackup: Starting InnoDB instance for recovery.
mariabackup: Using 104857600 bytes for buffer pool (set by --use-memory parameter)
2018-08-17 12:35:48 0 [Note] InnoDB: Mutexes and rw_locks use Windows interlocked functions
2018-08-17 12:35:48 0 [Note] InnoDB: Uses event mutexes
2018-08-17 12:35:48 0 [Note] InnoDB: Compressed tables use zlib 1.2.3
2018-08-17 12:35:48 0 [Note] InnoDB: Number of pools: 1
2018-08-17 12:35:48 0 [Note] InnoDB: Using SSE2 crc32 instructions
2018-08-17 12:35:48 0 [Note] InnoDB: Initializing buffer pool, total size = 100M, instances = 1, chunk size = 100M
2018-08-17 12:35:48 0 [Note] InnoDB: Completed initialization of buffer pool
2018-08-17 12:35:48 0 [Note] InnoDB: Starting crash recovery from checkpoint LSN=7388214
Last binlog file , position 0
180817 12:35:49 completed OK!

copy back
mariabackup --copy-back --datadir "C:\Program Files\MariaDB 10.3\data" --force-non-empty-directories --target-dir F:/MDB_Backup/Restore --user Buser --password XXX
copies back all files
copy back my.ini to target-dir.
start mysql service

C92012.err file attached.

datadir is C:\Program Files\MariaDB 10.3\data
table create uses DATA DIRECTORY='D:\C9/\data'
if DATA DIRECTORY='D:\C9/\data' is not used the service starts.



 Comments   
Comment by Julian Edwards [ 2018-08-21 ]

setting the privileges on the ROOT of 'DATA DIRECTORY' so NETWORK SERVICE has FULL control AND ensuring that all sub-directories have inherited rights resolves the issue.

Generated at Thu Feb 08 08:33:13 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.