Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lightning: error offset exceed range of file #40034

Closed
buchuitoudegou opened this issue Dec 19, 2022 · 2 comments · Fixed by #40232
Closed

lightning: error offset exceed range of file #40034

buchuitoudegou opened this issue Dec 19, 2022 · 2 comments · Fixed by #40232
Assignees
Labels
component/lightning This issue is related to Lightning of TiDB. severity/minor type/bug The issue is confirmed as a bug.

Comments

@buchuitoudegou
Copy link
Contributor

lightning report:

tidb lightning encountered error: [Lightning:Restore:ErrEncodeKV]encode kv error in file db.test.1.csv:0 at offset 45: syntax error: unterminated quoted field

But the file contains only 45 byte:

 File: /home/test_imp/db.test.1.csv
  Size: 45        	Blocks: 8          IO Block: 4096   regular file
Device: fd02h/64770d	Inode: 15213592    Links: 1
Access: (0777/-rwxrwxrwx)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2022-12-19 15:39:36.257455006 +0800
Modify: 2022-12-19 15:40:06.684149942 +0800
Change: 2022-12-19 15:40:06.684149942 +0800
 Birth: -

The index exceeds the range and thus, the error log output nothing:

[2022/12/19 15:39:36.348 +08:00] [ERROR] [parser.go:208] ["syntax error"] [pos=45] [content=]
@buchuitoudegou
Copy link
Contributor Author

/component lightning
/severity minor
/assign

@buchuitoudegou
Copy link
Contributor Author

/type bug

@ti-chi-bot ti-chi-bot added the type/bug The issue is confirmed as a bug. label Dec 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/lightning This issue is related to Lightning of TiDB. severity/minor type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants