From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by yocto-www.yoctoproject.org (Postfix, from userid 118) id BCF3AE00CA5; Thu, 21 Apr 2016 04:13:06 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on yocto-www.yoctoproject.org X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_LOW autolearn=ham version=3.3.1 X-Spam-HAM-Report: * -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low * trust * [74.125.82.41 listed in list.dnswl.org] * -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% * [score: 0.0000] * 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily * valid * -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature Received: from mail-wm0-f41.google.com (mail-wm0-f41.google.com [74.125.82.41]) by yocto-www.yoctoproject.org (Postfix) with ESMTP id 34748E00931 for ; Thu, 21 Apr 2016 04:13:04 -0700 (PDT) Received: by mail-wm0-f41.google.com with SMTP id v188so239956434wme.1 for ; Thu, 21 Apr 2016 04:13:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=RjKjPq1YLafJTSu6mTDAIN2DmBLopo7uTMlsF+7xc/w=; b=UTnlgE7/GwFp1Ct69DwuTI2CCLGTpV9Ve4GRe+8a1kpOEEFcmG5XlMjVSwp/CDUSAd e8jKd74VOTVqaxuJbANL6fRlwm8yWMIzjvbt1MMnE/CsmGUwcWkJaEk7+jyuIrNs1Yxv pLzG8sUyyCrxch3mGODxVu1rkXe+1mYSt73MqcMZb+50zwIGGixQpIZqDBjrZVE+NktP zEERIAT5fznCTZU3mrqXNzBGVuGxFsiEw+6YmMtJTvc2Yab7sCAIbH9yBBR5bOsEsUnx x5vg+HqtC7hS4QGtiU5doup0bIvRdU1dsokqguwwEpeu6fjkFTxES2mlVXV5s7Y15Pd2 WgCw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=RjKjPq1YLafJTSu6mTDAIN2DmBLopo7uTMlsF+7xc/w=; b=O/Rlrgh3+G57WNxQijz3aZy8Zi29FlTxJcMGORIHW/PhnCwHRe7m9KotTvaHg+M9hu 8W98iz2DCQXCSH9S/qQdIHtg9hSzc9b5TlGzDzWuZAxPnLOnKCOjLDuKtcuggQe3RstQ 6UaZ+7SFSRYI9X1DlHe+BZRIcYWDzy1fJGqL54I+GuwVUEyMoj5OtT0uKG0+fA7PuCQZ /NYQG6JnXNdab7xVKjw7qdOHeNglExYEUp5eU1LoeNzizdjdrQa0pUqeFripbLdndwe6 6t37NELKVqkPNTInmFoODUlONoOKguwLlGwq6jaHta88cjCRn2dBKlSawu1hCfKi9jbL Mjow== X-Gm-Message-State: AOPr4FX6VvqmYi9KLqMzt6ZTiR0HI0zZL4AfG+8hy3eiI9ROOF/wIrN2fIOtYUyAy/IR5SZP X-Received: by 10.194.95.198 with SMTP id dm6mr14389309wjb.136.1461237181612; Thu, 21 Apr 2016 04:13:01 -0700 (PDT) Received: from [192.168.2.37] ([83.217.123.106]) by smtp.googlemail.com with ESMTPSA id l124sm2719648wmf.11.2016.04.21.04.13.00 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 21 Apr 2016 04:13:01 -0700 (PDT) To: "Barros Pena, Belen" , "toaster@yoctoproject.org" References: From: Michael Wood Message-ID: <5718B5BC.5010109@intel.com> Date: Thu, 21 Apr 2016 12:13:00 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.5.1 MIME-Version: 1.0 In-Reply-To: Cc: "Reinhard.Tartler@deshawresearch.com" Subject: Re: Weird migration issue X-BeenThere: toaster@yoctoproject.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Web based interface for BitBake List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Apr 2016 11:13:06 -0000 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Yes I briefly looked into this, and I think it has to do with a memory mapping issue. If the database is not closed before trying to run database migrate we get into a weird state where there is a transaction in memory that can't be completed as the database has been deleted. This then blocks creating the database until it's gone from memory, the only way to do this is seemingly to reboot or use a different location on the filesystem for Toaster ...which is kind of worrying, we should probably open a django bug about this. To avoid this make sure that toaster/bitbake is fully stopped before running migrate/touching the database file. Michael On 20/04/16 10:24, Barros Pena, Belen wrote: > I've been coming across a problem with migrations occasionally (and rather > randomly) when I start Toaster. At the beginning it seemed I was the only > one seeing this. But, while at ELC, someone came to me because they were > having the same problem. His trace is below. Restarting the host seems to > solve the problem for me. In his case, he tried a different host and > everything worked. > > It doesn't seem distro-related: his was CentOS, mine Ubuntu. That's all I > know. Michael Wood looked at this briefly, so he might have something to > add. It was not a problem when it was just me, but if other people are > seeing this, then I am bit more worried. > > Any ideas on what could be causing it? > > Cheers > > Belén > > File > "/state/partition1/scratch/tartler/yocto-master/poky/bitbake/bin/../lib/toa > ster/manage.py", line 10, in > execute_from_command_line(sys.argv) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/core/management/__init__.py", line 354, in > execute_from_command_line > utility.execute() > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/core/management/__init__.py", line 346, in execute > self.fetch_command(subcommand).run_from_argv(self.argv) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/core/management/base.py", line 394, in > run_from_argv > self.execute(*args, **cmd_options) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/core/management/base.py", line 445, in execute > output = self.handle(*args, **options) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/core/management/commands/migrate.py", line 222, in > handle > executor.migrate(targets, plan, fake=fake, fake_initial=fake_initial) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/migrations/executor.py", line 110, in migrate > self.apply_migration(states[migration], migration, fake=fake, > fake_initial=fake_initial) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/migrations/executor.py", line 148, in > apply_migration > state = migration.apply(state, schema_editor) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/backends/base/schema.py", line 93, in __exit__ > self.atomic.__exit__(exc_type, exc_value, traceback) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/transaction.py", line 228, in __exit__ > connection.rollback() > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/backends/base/base.py", line 183, in rollback > self._rollback() > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/backends/base/base.py", line 147, in _rollback > return self.connection.rollback() > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/utils.py", line 98, in __exit__ > six.reraise(dj_exc_type, dj_exc_value, traceback) > File > "/state/partition1/scratch/tartler/yocto-master/poky/build/venv/lib/python2 > .7/site-packages/django/db/backends/base/base.py", line 147, in _rollback > return self.connection.rollback() > django.db.utils.OperationalError: cannot rollback - no transaction is > active > Failed migrations, aborting system start > Failed start. > >