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

Smbfs2.1: DOSlist lock #9

Open
raziel- opened this issue May 23, 2022 · 2 comments
Open

Smbfs2.1: DOSlist lock #9

raziel- opened this issue May 23, 2022 · 2 comments

Comments

@raziel-
Copy link

raziel- commented May 23, 2022

It seems (and I'm just parrotting what i read here)
https://www.amigans.net/modules/newbb/viewtopic.php?post_id=46287#forumpost46287
that, if remote host is gone, smbfs handler will lock the doslist too (?)
Which leads to workbench become unresponsive.

Would it be possible to prevent that?
Could the handler be taught to not lock doslist when the remote host is gone?

Thank you

@obarthel
Copy link
Owner

This is not really fixable at the level of the file system, I'm afraid.

When a command such as "DiskChange" needs to tell a file system to do something, it first has to find out how to talk to the file system. This is done by locking the global dos device/assignment/volume list, finding the matching record, sending a message to the file system, waiting for it to respond and then unlocking the global dos list again.

This is how a "die" command would work, too. But there's a problem here because the file system needs to shut down properly, removing any volume/device it added to the global dos list. It cannot do that because the "die" command is already holding onto it. It will try its best by repeately attempting to lock the global dos list and eventually has to give up after 100 attempts. So this is not a deadlock, it's just not able to shut down as required. Sending the smbfs command a Ctrl+C signal is bound to be safer because nobody has to wait for anything.

Implementing a "die" command which does not lock the global dos list should be possible, though. I reckon it has not been done yet.

@raziel-
Copy link
Author

raziel- commented May 23, 2022

@obarthel

Who, you're still around, awesome :-)

It will try its best by repeately attempting to lock the global dos list and eventually has to give up after 100 attempts. So this is not a deadlock, it's just not able to shut down as required.

I did some more tests while waiting, madly clicking around on the WB icons and yes, its not a complete freeze, it will come back every once in a while (activating the last clicked icon), so that is good.

I'm trying with TIMEOUT now.

Thank you for your answer, very much appreciated.

I really hope you'll find the time to get back to smbfs...cough, cough, sambav2 support, cough ;-)

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

No branches or pull requests

2 participants