qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Miguel Arruga Vivas <rosen644835@gmail.com>
Cc: qemu-devel@nongnu.org, marcandre.lureau@redhat.com,
	Wei Yang <richardw.yang@linux.intel.com>,
	dgilbert@redhat.com
Subject: Re: [Qemu-devel] [Fail] tests/test-util-filemonitor fails
Date: Tue, 5 Nov 2019 09:54:59 +0000	[thread overview]
Message-ID: <20191105095459.GC41709@redhat.com> (raw)
In-Reply-To: <20191104171624.6e62c112@gmail.com>

On Mon, Nov 04, 2019 at 08:35:23PM +0100, Miguel Arruga Vivas wrote:
> Hi Daniel,
> 
> I've been trying to open a bug in launchpad about exactly this, but it
> always raises an error when trying to log in.  Then I found this
> thread diving into the archives, so I'll try to kindly ask here about
> it.
> 
> Daniel P. Berrangé <berrange@redhat.com> wrote:
> > On Fri, Aug 09, 2019 at 08:06:09AM +0800, Wei Yang wrote:
> > > On Thu, Aug 08, 2019 at 10:22:13AM +0100, Daniel P. Berrangé
> > > wrote:  
> > > >On Thu, Aug 08, 2019 at 04:46:53PM +0800, Wei Yang wrote:  
> > > >> On Thu, Aug 08, 2019 at 09:02:29AM +0100, Daniel P. Berrangé
> > > >> wrote:  
> > > >> >On Thu, Aug 08, 2019 at 10:07:23AM +0800, Wei Yang wrote:  
> > > >> >> Current qemu fails tests/test-util-filemonitor.  
> > > >> >
> > > >> >You'll need to provide more info. The test works for me and
> > > >> >passes in all the QEMU CI environments.
> > > >> >  
> > > >> 
> > > >> The error message from my side is:
> > > >> 
> > > >> /util/filemonitor: Expected watch id 200000000 but got 100000000
> > > >> **
> > > >> ERROR:tests/test-util-filemonitor.c:665:test_file_monitor_events:
> > > >> assertion failed: (err == 0)
> > > >> 
> > > >> What else you'd prefer to have?  
> > > >
> > > >Can you set the  "FILEMONITOR_DEBUG=1" env variable before running
> > > >the test - it will print out lots more info
> > > >  
> > > 
> > > Here is the output with more info.
> > > 
> > >     $ FILEMONITOR_DEBUG=1
> > > QTEST_QEMU_BINARY=x86_64-softmmu/qemu-system-x86_64
> > > tests/test-util-filemonitor  
> > 
> > >     Rmdir /tmp/test-util-filemonitor-151B6Z/fish
> > >     Event id=200000000 event=4 file=
> > >     Expected watch id 200000000 but got 100000000
> > >     **  
> > 
> > Ok, so the kernel is sending the events in an unexpected order
> 
> I've been reading about the issue and as far as I understand the inotify
> man-page[http://man7.org/linux/man-pages/man7/inotify.7.html], section
> "Dealing with rename() events", points out that the order nor the
> atomicity of the concurrent events is something that should be relied
> on.
>  
> > >     ERROR:tests/test-util-filemonitor.c:665:test_file_monitor_events:
> > > assertion failed: (err == 0) Aborted (core dumped)
> > > 
> > >   
> > > >Also what operating system are you using, and what kernel version
> 
> We have hit this error on GNU Guix master
> [http://issues.guix.gnu.org/issue/37860]. I'm using linux-libre 5.3.4
> on x86_64.  It does not seem to be something deterministic, but I just
> commented out the test the fifth time I've hit the same error.
> 
> Is there any way to change the test to not rely on the ordering of the
> events from different views of the same fs action?

This reported bug was already fixed in git master with

  commit bf9e0313c27d8e6ecd7f7de3d63e1cb25d8f6311
  Author: Daniel P. Berrangé <berrange@redhat.com>
  Date:   Wed Aug 21 16:14:27 2019 +0100

    tests: make filemonitor test more robust to event ordering
    

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|



  reply	other threads:[~2019-11-05  9:57 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-08  2:07 [Qemu-devel] [Fail] tests/test-util-filemonitor fails Wei Yang
2019-08-08  8:02 ` Daniel P. Berrangé
2019-08-08  8:46   ` Wei Yang
2019-08-08  9:22     ` Daniel P. Berrangé
2019-08-09  0:06       ` Wei Yang
2019-08-09  9:12         ` Daniel P. Berrangé
2019-08-12  0:49           ` Wei Yang
2019-11-04 19:35           ` Miguel Arruga Vivas
2019-11-05  9:54             ` Daniel P. Berrangé [this message]
2019-11-08  8:52               ` Miguel Arruga Vivas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191105095459.GC41709@redhat.com \
    --to=berrange@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=richardw.yang@linux.intel.com \
    --cc=rosen644835@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).