[Info-vax] Nonexisting "Owner process" of a device.
Michael Moroney
moroney at world.std.spaamtrap.com
Fri Jul 7 10:52:07 EDT 2017
mcleanjoh at gmail.com writes:
>I can see one way that this might happen ...
>Process A requests that some other process (let's call it B) provide an I/O
>device or channel and then process A terminates without telling process B
>to deassign the device or channel.
Pretty much.
If I recall correctly, the original problem went somewhat like this:
Process A assigns a channel/allocates some device that is not normally
shareable (such as a terminal, whether virtual or real). Since the
device isn't shareable (such as a disk), the owner PID field gets set
to this process' PID.
Process B, using the SHARE privilege, assigns a channel to the same device
and does some IO. A remains the owner.
Process A deassigns the channel/logs out/similar, but since the device
reference count doesn't go to 0 (because of B), certain cleanup
activities (including zeroing of the owner PID) doesn't happen.
Once A logs out, the owner PID references a nonexistent process.
When B deassigns its channel, for some reason the PID field does
not get set to 0 because it's not B's PID. In the original problem,
the reference count to the device does not go to 0 for some reason, so
now the device is "owned" by a nonexistent process with a phantom
reference to it.
More information about the Info-vax
mailing list