# Help. error: cannot open file /data/mysql/data/mysql1-bin.000022

**URL:** <https://forums.percona.com/t/help-error-cannot-open-file-data-mysql-data-mysql1-bin-000022/10454>\
**Category:** Percona XtraBackup\
**Created:** [May 13, 2021, 10:22am UTC](https://forums.percona.com/t/help-error-cannot-open-file-data-mysql-data-mysql1-bin-000022/10454 "2021-05-13T10:22:36Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![xiao](https://avatars.discourse-cdn.com/v4/letter/x/2acd7d/32.png) [@xiao](https://forums.percona.com/u/xiao)\
**Post date:** [May 13, 2021, 10:22am UTC](https://forums.percona.com/t/help-error-cannot-open-file-data-mysql-data-mysql1-bin-000022/10454/1 "2021-05-13T10:22:36Z")

</div>

When use this commond to backup a remote mysqlDB

xtrabackup --defaults-file=/etc/my.cnf --user=root --password=xxx --port=3306 --host=172.130.195.164 --backup --no-server-version-check --target-dir=/data/databak/base --stream=xbstream --compress --compress-threads=4 --parallel=4 --extra-lsndir=/data/databak/lsndir \> base.stream  
It occurred this error:  
210513 18:07:07 Finished backing up non-InnoDB tables and files  
210513 18:07:07 Executing FLUSH NO\_WRITE\_TO\_BINLOG BINARY LOGS  
210513 18:07:07 Selecting LSN and binary log position from p\_s.log\_status  
xtrabackup: File ‘/data/mysql/data/mysql1-bin.000023’ not found (OS errno 2 - No such file or directory)  
Operating system error number 2 in a file operation.  
The error means the system cannot find the path specified.  
If you are installing InnoDB, remember that you must create directories yourself, InnoDB does not create them.  
[00] error: cannot open file /data/mysql/data/mysql1-bin.000023  
[00] Error: copy\_file() failed.

What can i do now?

---

<div class="post-metadata">

**Author:** ![George\_Lorch](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/george_lorch/32/1108_2.png) [@George\_Lorch](https://forums.percona.com/u/George_Lorch)\
**Post date:** [May 13, 2021, 12:22pm UTC](https://forums.percona.com/t/help-error-cannot-open-file-data-mysql-data-mysql1-bin-000022/10454/2 "2021-05-13T12:22:36Z")

</div>

XtraBackup must have direct, physical access to the same underlying filesystem as the database host and is typically not used remotely without some kind of network mounting of the remote filesystem. The typical use i that XxtraBackup must be installed directly on the same host as the server instance.

–  
George O. Lorch III  
Director of Server Engineering, Percona Server for MySQL, Percona XtraDB Cluster, and Percona XtraBackup

---

<div class="post-metadata">

**Author:** ![xiao](https://avatars.discourse-cdn.com/v4/letter/x/2acd7d/32.png) [@xiao](https://forums.percona.com/u/xiao)\
**Post date:** [May 14, 2021, 7:05am UTC](https://forums.percona.com/t/help-error-cannot-open-file-data-mysql-data-mysql1-bin-000022/10454/3 "2021-05-14T07:05:32Z")

</div>

According to your suggestion,The xtraBackup haved be installed directly on the same host with the mysql server instance, and fixed this error.

Thanks

Xiao yang
