content_image/739812.jpg
ERROR 3845 (HY000): Redo log archive directory ’ directory_path1 ’ is in, under, or over server directory ’datadir’ - ’ /path/to/data_directory ’ 

When a backup utility that supports redo log archiving initiates a backup, the backup utility activates redo log archiving by invoking the innodb_redo_log_archive_start()  function. 

If you are not using a backup utility that supports redo log archiving, redo log archiving can also be activated manually, as shown: 

mysql> SELECT innodb_redo_log_archive_start(’ label ’, ’ subdir ’); +------------------------------------------+ | innodb_redo_log_archive_start(’ label ’) | +------------------------------------------+ | 0 | +------------------------------------------+ 

Or: 

mysql> DO innodb_redo_log_archive_start(’ label ’, ’ subdir ’); Query OK, 0 rows affected (0.09 sec) 

<img src='content_image/739812.jpg'>

## Note 

The MySQL session that activates redo log archiving (using innodb_redo_log_archive_start() ) must remain open for the duration of the archiving. The same session must deactivate redo log archiving (using innodb_redo_log_archive_stop() ). If the session is terminated before the redo log archiving is explicitly deactivated, the server deactivates redo log archiving implicitly and removes the redo log archive file. 

where label  is a label defined by innodb_redo_log_archive_dirs ; subdir  is an optional argument for specifying a subdirectory of the directory identified by label  for saving the archive file; it must be a simple directory name (no slash (/), backslash (\), or colon (:) is permitted). subdir  can be empty, null, or it can be left out. 

Only users with the INNODB_REDO_LOG_ARCHIVE  privilege can activate redo log archiving by invoking innodb_redo_log_archive_start() , or deactivate it using innodb_redo_log_archive_stop() . The MySQL user running the backup utility or the MySQL user activating and deactivating redo log archiving manually must have this privilege. 

The redo log archive file path is directory_identified_by_label / [ subdir /]archive. serverUUID .000001.log , where directory_identified_by_label  is the archive directory identified by the label  argument for innodb_redo_log_archive_start() . subdir is the optional argument used for innodb_redo_log_archive_start() . 

For example, the full path and name for a redo log archive file appears similar to the following: 

/ directory_path / subdirectory /archive.e71a47dc-61f8-11e9-a3cb-080027154b4d.000001.log 

After the backup utility finishes copying InnoDB  data files, it deactivates redo log archiving by calling the innodb_redo_log_archive_stop()  function. 

If you are not using a backup utility that supports redo log archiving, redo log archiving can also be deactivated manually, as shown: 

mysql> SELECT innodb_redo_log_archive_stop(); +--------------------------------+ 

