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

Wait for zombie process in case of timed out nvts. #379

Merged
merged 3 commits into from
Aug 30, 2019

Conversation

jjnicola
Copy link
Member

Before, if an NVT timedout, the process is terminated and removed
from the running process struct, and the parent process does not wait for the child.
This leaved a zombie process until the end of the scan. The zombies proc become orphan proc
and removed for the system.
Now the timed out nvts are terminated, but a check is performerd to know
if the process was waited, before removing it from the running process struct.
In case it was not cleaned, it is kept in the running process table until is waited
for the parent and finally removed from the struct.

Before, if an NVT timedout, the process is terminated and removed
from the running process struct, and the parent process does not wait for the child.
This leaved a zombie process until the end of the scan. The zombies proc become orphan proc
and removed for the system.
Now the timed out nvts are terminated, but a check is performerd to know
if the process was waited, before removing it from the running process struct.
In case it was not cleaned, it is kept in the running process table until is waited
for the parent and finally removed from the struct.
janowagner
janowagner previously approved these changes Aug 30, 2019
Copy link
Member

@janowagner janowagner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it can fix a rare condition I observed during massive scans.
Would be good to add doc strings for functions where worked on.

@jjnicola jjnicola merged commit 70f908b into greenbone:master Aug 30, 2019
@jjnicola jjnicola deleted the zombies-7 branch August 30, 2019 07:41
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

Successfully merging this pull request may close these issues.

2 participants