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

[Subtask] Add debug log for FUSE API handling. #5873

Open
Tracked by #5504
diqiu50 opened this issue Dec 16, 2024 · 3 comments · May be fixed by #5905
Open
Tracked by #5504

[Subtask] Add debug log for FUSE API handling. #5873

diqiu50 opened this issue Dec 16, 2024 · 3 comments · May be fixed by #5905
Assignees
Labels
subtask Subtasks of umbrella issue

Comments

@diqiu50
Copy link
Contributor

diqiu50 commented Dec 16, 2024

Describe the subtask

When handling FUSE API calls, we need detailed logs to aid in debugging. We should record the called API and its parameters, as well as whether the call was successful and the returned content.

Parent issue

#5504

@unknowntpo
Copy link
Contributor

May I take this issue?

@xunliu
Copy link
Member

xunliu commented Dec 17, 2024

hi @unknowntpo sure, Please go ahead

@diqiu50
Copy link
Contributor Author

diqiu50 commented Dec 17, 2024

Here is an example of go-fuse debug log:

2024/12/17 16:05:15 rx 4: GETATTR n1 {Fh 0 } p10929
2024/12/17 16:05:15 tx 4:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 6: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 6:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 8: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 8:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 10: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 10:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 12: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 12:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 14: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 14:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 16: ACCESS n1 {u=1000 g=1000 } p10760
2024/12/17 16:05:16 tx 16:     OK
2024/12/17 16:05:16 rx 18: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 18:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 20: ACCESS n1 {u=1000 g=1000 } p10760
2024/12/17 16:05:16 tx 20:     OK
2024/12/17 16:05:16 rx 22: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 22:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 24: ACCESS n1 {u=1000 g=1000 } p10760
2024/12/17 16:05:16 tx 24:     OK
2024/12/17 16:05:16 rx 26: ACCESS n1 {u=1000 g=1000 x} p10760
2024/12/17 16:05:16 tx 26:     OK
2024/12/17 16:05:16 rx 28: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 28:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 30: GETATTR n1 {Fh 0 } p10760
2024/12/17 16:05:16 tx 30:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 32: OPENDIR n1 {NONBLOCK,LARGEFILE,DIRECTORY} p10941
Gvfs.OpenDir called with NodeId: 1
2024/12/17 16:05:16 tx 32:     OK, {Fh 1000 }
2024/12/17 16:05:16 rx 34: GETATTR n1 {Fh 0 } p10941
2024/12/17 16:05:16 tx 34:     OK, {tA=0s {M040644 SZ=4096 L=1 1000:1000 B0*0 i0:1 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 36: READDIRPLUS n1 {Fh 1000 [0 +4096)  L 0 NONBLOCK,LARGEFILE,DIRECTORY} p10941
Gvfs.ReadDirPlus called nodeId 1, offset:0
2024/12/17 16:05:16 tx 36:     OK,  160b data "\x00\x00\x00\x00\x00\x00\x00\x00"...
2024/12/17 16:05:16 rx 38: LOOKUP n1 "juicefs" p10941
Gvfs.Lookup called with name: juicefs
2024/12/17 16:05:16 tx 38:     OK, {n1000000 g1 tE=1s tA=1s {M040755 SZ=4096 L=1 1000:1000 B0*0 i0:1000000 A 1734422683.000000 M 1734422683.000000 C 1734422683.000000}}
2024/12/17 16:05:16 rx 40: READDIRPLUS n1 {Fh 1000 [1 +4096)  L 0 NONBLOCK,LARGEFILE,DIRECTORY} p10941
Gvfs.ReadDirPlus called nodeId 1, offset:1
2024/12/17 16:05:16 tx 40:     OK
2024/12/17 16:05:16 rx 42: RELEASEDIR n1 {Fh 1000 NONBLOCK,LARGEFILE,DIRECTORY  L0} p0
Gvfs.ReleaseDir called
2024/12/17 16:05:16 tx 42:     OK

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
subtask Subtasks of umbrella issue
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants