From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Hu7TX-0001KI-Q7 for qemu-devel@nongnu.org; Fri, 01 Jun 2007 09:47:31 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Hu7TU-0001In-71 for qemu-devel@nongnu.org; Fri, 01 Jun 2007 09:47:31 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Hu7TT-0001Ij-T3 for qemu-devel@nongnu.org; Fri, 01 Jun 2007 09:47:27 -0400 Received: from wx-out-0506.google.com ([66.249.82.230]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Hu7TT-0006I2-Hl for qemu-devel@nongnu.org; Fri, 01 Jun 2007 09:47:27 -0400 Received: by wx-out-0506.google.com with SMTP id t15so502779wxc for ; Fri, 01 Jun 2007 06:47:21 -0700 (PDT) Message-ID: <46602361.3080503@codemonkey.ws> Date: Fri, 01 Jun 2007 08:47:13 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] stale pid files? References: <465FFAFF.50800@kittenberger.net> In-Reply-To: <465FFAFF.50800@kittenberger.net> Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Axel Kittenberger wrote: > Hi list again, another suggestion. > > I use the deamons pidfile feature to write pidfiles so I can controll > the virtual machines with /etc/init.d/bla scripts, to e.g. auto spawn > the guests when the server starts, auto/start/stop with runlevels and > so on.. However I got following issue, the daemon wont start if there > is a pidfile already (yes no problem for user to delete, but for auto > spawning after unattended boot) . Since e.g. following situation: > BANG! Powerout! .... System goes up when power is available again. The > init scripts want to start the qemu/kvm deamons, but they refuse > because these see their pidfiles already from pre-powerout.. -pidfile behaves properly in CVS. You may be able to find the patch on the ML that fixed it. Regards, Anthony Liguori > I have seen other daemons somehow locking their pidfiles while > running, and when killed -9ed, or poweroutes and they start again, > they see their pid-file is unlocked, thus stale, and just overwrite > it... only notifing you with a message they did so. > > Kind Regards, > Axel > > >