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

ksmbd stuck on write event after attempt to shutdown #560

Open
consp opened this issue Jun 6, 2022 · 13 comments
Open

ksmbd stuck on write event after attempt to shutdown #560

consp opened this issue Jun 6, 2022 · 13 comments
Labels
fixed fixed issue

Comments

@consp
Copy link

consp commented Jun 6, 2022

After I tried shutting down ksmbd gave these errors and could not be stopped:

[82661.298655] ksmbd: sock_read failed: -108
[82661.559100] ksmbd: smb_direct: Unexpected RDMA CM event. cm_id=00000000ea775640, event=timewait exit (15)
[82667.180135] ksmbd: Unable to close RPC pipe 2
[82667.180351] ksmbd: Unable to close RPC pipe 1
[82667.180572] ksmbd: Unable to close RPC pipe 0

Console output of the stuck part on reboot, I do not have the logs:
image

Have not been able to reproduce it but it might have had to do with a change in the filesystem since a disk was remounted.

Hopefully the information is of use to you!

@namjaejeon
Copy link
Member

ksmbd: smb_direct: Unexpected RDMA CM event. cm_id=00000000ea775640, event=timewait exit (15)

@hclee any opinion?

@namjaejeon
Copy link
Member

@consp Let me know your NIC model name and kernel version.

@hclee
Copy link
Member

hclee commented Jun 13, 2022

ksmbd: smb_direct: Unexpected RDMA CM event. cm_id=00000000ea775640, event=timewait exit (15)

@hclee any opinion?

We have to terminate the loop for handling connection if RDMA_CM_EVENT_TIMEWAIT_EXIT is received like RDMA_CM_EVENT_DISCONNECTED.

@consp
Copy link
Author

consp commented Jun 13, 2022

@consp Let me know your NIC model name and kernel version.

5.17 xanmod (also had it with the mainline version now) and a change to allow the ConnectX 4 card to be detected.
Card: ConnectX 4 MCX455A

@namjaejeon
Copy link
Member

We have to terminate the loop for handling connection if RDMA_CM_EVENT_TIMEWAIT_EXIT is received like RDMA_CM_EVENT_DISCONNECTED.

@hclee So, what are you going to do ?

@hclee
Copy link
Member

hclee commented Jun 13, 2022

We have to terminate the loop for handling connection if RDMA_CM_EVENT_TIMEWAIT_EXIT is received like RDMA_CM_EVENT_DISCONNECTED.

@hclee So, what are you going to do ?

I will send a patch for this issue.

@namjaejeon
Copy link
Member

@hclee Thanks!
@consp I have applied the patch(bb974ae) for this issue. Can you check it ?

@consp
Copy link
Author

consp commented Jun 14, 2022

@hclee Thanks! @consp I have applied the patch(bb974ae) for this issue. Can you check it ?

Will install it this week, might take a while to show up/not show up as it doesn't happen very often.

@consp
Copy link
Author

consp commented Jun 14, 2022

So far so good, the things I got it to sometimes break don't do anything bad anymore and so far no issues with ksmbd.control -s. Stability seems ok, but I will have to leave it running for longer to be sure.

@namjaejeon
Copy link
Member

@consp I guess this issue may be fixed with this patch(5039a45)

@consp
Copy link
Author

consp commented Jul 28, 2022

@consp I guess this issue may be fixed with this patch(5039a45)

Looks like it might be the case, "racy" sounds like what I experienced. I'll have a look at it when I get back from holiday.

@namjaejeon namjaejeon added the fixed fixed issue label Aug 19, 2022
@consp
Copy link
Author

consp commented Aug 25, 2022

Fixed is correct, I do not get any issues anymore. @namjaejeon tnx for the fix!
ksmbd restarted several times as that is part of the server hibernation procedure, power is expensive these days and I've seen no messages so far.

@namjaejeon
Copy link
Member

@consp Thanks for your checking it:) Let me know if you have any issue while using ksmbd.

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

No branches or pull requests

3 participants