[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v2 4/8] tools/ocaml/xenstored: only quit on SIGTERM when a reload is possible


  • To: "jgross@xxxxxxxx" <jgross@xxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Edwin Torok <edvin.torok@xxxxxxxxxx>
  • Date: Mon, 18 Jan 2021 09:28:08 +0000
  • Accept-language: en-GB, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=cREkINcwAVWlpVT+b3AoRmFY6fbOLmNL+/3q7HDI/+g=; b=efNIAPLV7z5QT76asgpJwIVHekvpzfSbnWjyXUjyX2Ftca809gXZLGox0s+WrW4Xb6/7LGS3DEneDXjirwbFIo1/y0q2IJ4VX/j4HPzYMdpiUPYucrbr0KhH76QWo6CoP3uSLvugcZlS4+giNcv+uKE/tFxhZgNMw+GaByX6MY86mtWfjE7CaiHyWxK0f3XXQQ8p1SHYelExw3uvYyjR1GuWegO7B9ktQjnNKgGTw+SEHQEmNy0OyssipJv1WGrWu+VrEObqFX/NrzidB2VlHvrl+guOUWTQELLM8jlk2Z0+rQykXZHTi0Xrlk/PBOoHvQZ2069dho4ELahtfvY2EA==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Ddz/YQA61f7aw1GfzhcaYuo4TgqmMlHXaMetqjrZU0XUwv6+n8QHzr+80i/ALRm9BqWNiW/rKJt8Y3ePWCfhX+YzOy1WO2nU9MbScv6tXWvxfzDXfQFcemQ9sZlt78qs6aqmYj8IG5AsIdEfqq8GDdWcH9XhbXI0TD7bS5u308Mf4yPbNiQJNP0zn9ORCrjEsVTI9wlN6fYZBIuMFWLbsIWLGdgbUYAf2bzs9uaJxFDMyds34SEIDm3fRUcH1pGsBfwnBLMBPwjqoa9PHMIMaDqfrZMGQVW5LKMXvtBD6PuD9MD30GDRSSnBGgjscBwkKlm8v3/9sf+jQLPFcTlZGA==
  • Authentication-results: esa5.hc3370-68.iphmx.com; dkim=pass (signature verified) header.i=@citrix.onmicrosoft.com
  • Cc: "wl@xxxxxxx" <wl@xxxxxxx>, Pau Ruiz Safont <pau.safont@xxxxxxxxxx>, "dave@xxxxxxxxxx" <dave@xxxxxxxxxx>, Christian Lindig <christian.lindig@xxxxxxxxxx>, "iwj@xxxxxxxxxxxxxx" <iwj@xxxxxxxxxxxxxx>
  • Delivery-date: Mon, 18 Jan 2021 09:28:18 +0000
  • Ironport-sdr: bBMfODjkBx10c5xIg/DqPsjEifeh8JPn/+mLvM6e7kol0/lgktVihN2C9IN9fNI4yYU3AykoC1 RkQA4Kdz3ReRQZ3Sp03Y7iFuRhFT6NBKy19qSctTK5JmYnywYjCGfJGe9z5IqvLDBjd0CzIGH7 dTqw7dNpVEjvqx6+4r5Wm1oeWr+lhwUKTcRANzinYlzp4q5FpgJwdsL8Zdoz31U6X9goK5o1VA tMxxwQunadFtUblK9Bz2GWHJiQRFwPSZKS17QYWmoHZ5pHlWJrugrPemCMhhLmeB4l0lgjWxb5 1Xk=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHW64310ek+Wy0m9k+iQ4GibZAM76otBnOAgAAa5oA=
  • Thread-topic: [PATCH v2 4/8] tools/ocaml/xenstored: only quit on SIGTERM when a reload is possible

On Mon, 2021-01-18 at 08:51 +0100, Jürgen Groß wrote:
> On 15.01.21 23:28, Edwin Török wrote:
> > Currently when oxenstored receives SIGTERM it dumps its state and
> > quits.
> > It is possible to then restart it if --restart is given, however
> > that is
> > not always safe:
> > 
> > * domains could have active transactions, and after a restart they
> > would
> > either reuse transaction IDs of already open transactions, or get
> > an
> > error back that the transaction doesn't exist
> > 
> > * there could be pending data to send to a VM still in oxenstored's
> >    queue which would be lost
> > 
> > * there could be pending input to be processed from a VM in
> > oxenstored's
> >    queue which would be lost
> > 
> > Prevent shutting down oxenstored via SIGTERM in the above
> > situations.
> > Also ignore domains marked as bad because oxenstored would never
> > talk
> > to them again.
> > 
> > Signed-off-by: Edwin Török <edvin.torok@xxxxxxxxxx>
> > Reviewed-by: Pau Ruiz Safont <pau.safont@xxxxxxxxxx>
> > Reviewed-by: Christian Lindig <christian.lindig@xxxxxxxxxx>
> > 
> > ---
> > Changed since V1:
> > * post publicly now that the XSA is out
> > ---
> >   tools/ocaml/xenstored/connection.ml  | 35
> > ++++++++++++++++++++++++++++
> >   tools/ocaml/xenstored/connections.ml |  8 +++++++
> >   tools/ocaml/xenstored/xenstored.ml   | 13 +++++++++--
> >   tools/xenstore/xenstored_core.c      |  7 +++++-
> 
> I don't think you should modify tools/xenstore/xenstored_core.c in
> your
> series.
> 

Thanks for spotting, I think that hunk ended up in the wrong place
during a patchqueue rebase when solving conflicts, it should be gone
when I post a V3:
https://github.com/edwintorok/xen/pull/1/commits/4ec9ffcee83a9668431b220bef4abdcd9ac51175

Best regards,
--Edwin

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.