qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] fstrim & upstream kernel not working
@ 2014-03-13 21:49 Richard W.M. Jones
  2014-03-14 12:30 ` Paolo Bonzini
  0 siblings, 1 reply; 7+ messages in thread
From: Richard W.M. Jones @ 2014-03-13 21:49 UTC (permalink / raw)
  To: qemu-devel, pbonzini

I got fstrim happily working in Fedora 20, but it's not working with
the upstream kernel.  The message is:

  fstrim -v /sysroot/
  [   45.541339] sda: WRITE SAME failed. Manually zeroing.
  /sysroot/: 47.2 MiB (49466368 bytes) trimmed

While this isn't technically an error, it of course doesn't trim
anything.  In fact the host disk grows after the fstrim.

A couple of questions:

- Is there any reason why virtio-scsi doesn't emulate WRITE SAME?  It
seems pretty simple, and upstream kernels issue WRITE SAME when they
want to zero large areas of disk.

- Can you see where ext4 issues the zeroout/write same call?  AFAICT
it is still issuing discards, but these are getting turned into
zeroout/write same by some sort of block layer magic that I can't
quite follow.

kernel: 3.14.0-0.rc6.git2.1.fc21
qemu: 1.7.0-5.fc21.x86_64

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-03-14 13:34 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-13 21:49 [Qemu-devel] fstrim & upstream kernel not working Richard W.M. Jones
2014-03-14 12:30 ` Paolo Bonzini
2014-03-14 12:42   ` Richard W.M. Jones
2014-03-14 12:47     ` Paolo Bonzini
2014-03-14 13:24       ` Richard W.M. Jones
2014-03-14 13:28         ` Paolo Bonzini
2014-03-14 13:34           ` Richard W.M. Jones

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).