The br log start success, but actually unable to write to the br log
- Dominant language
- Go
- Stars
- 40.5k
- Forks
- 6.2k
- PR merge metrics
- PR metrics pending
Description
## Bug Report
Please answer these questions before submitting your issue. Thanks!
### 1. Minimal reproduce step (Required)
tiup br:v6.5.3 log start --task-name=pitr1 --pd="172.16.114.81:2389" --storage='/data1/nfs/pitr-backup/log-backup'
[2023/08/23 17:51:00.971 +08:00] [INFO] [collector.go:73] ["log start"] [streamTaskInfo="{taskName=pitr1,startTs=443753210121551876,endTS=999999999999999999,tableFilter=*.*}"] [pausing=false] [rangeCount=2]
[2023/08/23 17:51:04.462 +08:00] [INFO] [collector.go:73] ["log start success summary"] [total-ranges=0] [ranges-succeed=0] [ranges-failed=0] [total-take=3.563272246s]
### 2. What did you expect to see? (Required)
tiup br:v6.5.3 log status --task-name=pitr1 --pd="172.16.114.81:2389"
Starting component `br`: /root/.tiup/components/br/v6.5.3/br log status --task-name=pitr1 --pd=172.16.114.81:2389
Detail BR log in /tmp/br.log.2023-08-23T18.16.48+0800
● Total 1 Tasks.
> #1 <
name: pitr1
status: ○ ERROR
start: 2023-08-23 17:49:17.263 +0800
end: 2090-11-18 22:07:45.624 +0800
storage: local:///data1/nfs/pitr-backup/log-backup
speed(est.): 0.00 ops/s
checkpoint[global]: 2023-08-23 17:49:17.263 +0800; gap=27m33s
error[store=1]: KV:LogBackup:Io
error-happen-at[store=1]: 2023-08-23 17:55:55.423 +0800; gap=20m54s
error-message[store=1]: I/O Error: Permission denied (os error 13)
### 3. What did you see instead (Required)
Because the permissions are incorrect, the br log cannot be written. This should be detected during startup, and it should prompt 'fail' along with listing the reason for the error.
[root@vm172-16-114-81 ~]# cd /data1/nfs/pitr-backup/log-backup
[root@vm172-16-114-81 log-backup]# ll
-rw-r--r-- 1 root root 78 8月 23 17:49 backup.lock
-rw-r--r-- 1 root root 214274 8月 23 17:49 backupmeta
### 4. What is your TiDB version? (Required)
6.5.3
Contributor guide
Assessment
This issue has not been assessed yet.