Re: [Nbd] nbd-client and SIGSTOP/SIGCONT
- To: <paul.clements@...856...>
- Cc: nbd-general@lists.sourceforge.net
- Subject: Re: [Nbd] nbd-client and SIGSTOP/SIGCONT
- From: "Ian" <coughlan@...866...>
- Date: Mon, 18 Apr 2011 08:44:02 -0700
- Message-id: <1E2BDAB96EA24FC4B8B6C9D43D0E1CE7@...867...>
- References: <18F04FC1323C451FAA5F1A46D91AFEF3@...867...> <BANLkTikhxVX0QTQaCTrW4P8fL42m9a4s1g@...18...>
Hi Paul,
Thanks for the patch. This same thing was the first thing I tried, but
quickly realized that more was needed. When -ERESTARTSYS is returned
(without first shutting down the socket), we re-enter the ioctl, create
another thread, and that thread prints out "nbd3: wrong magic", terminates,
and we return -EPROTO to the client, which also terminates, and the block IO
is hosed.
So, I experimented with keeping both the thread and the socket alive on
ERESTARTSYS (I moved the thread ptr into the nbd_device struct). But I
still saw errors in nbd_read_stat(), and didn't have time to investigate
further.
I think I might just hack killall5 for now, to prevent it from sending the
SIGSTOP/SIGCONT to nbd.
Regards,
Ian
Reply to: