qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [Bug 1422307] [NEW] qemu-nbd corrupts files
@ 2015-02-16 10:05 Pierre Schweitzer
  2015-02-17 14:50 ` [Qemu-devel] [Bug 1422307] " Max Reitz
                   ` (21 more replies)
  0 siblings, 22 replies; 25+ messages in thread
From: Pierre Schweitzer @ 2015-02-16 10:05 UTC (permalink / raw)
  To: qemu-devel

Public bug reported:

Dear all,

On Trusty, in certain situations, try to copy files over a qemu-nbd
mounted file system leads to write errors (and thus, file corruption).

Here is the last example I tried:
-> virtual disk is a VDI disk
-> It has only one partition, in FAT

Here is my mount process:
# modprobe nbd max_part=63
# qemu-nbd -c /dev/nbd0 "virtual_disk.vdi"
# partprobe /dev/nbd0
# mount /dev/nbd0p1 /tmp/mnt/

Partition is properly mounted at that point:
/dev/nbd0p1 on /tmp/mnt type vfat (rw)

Now, when I copy a file (rather big, ~28MB):
# cp file_to_copy /tmp/mnt/ ; sync
# md5sum /tmp/mnt/file_to_copy
2efc9f32e4267782b11d63d2f128a363  /tmp/mnt/file_to_copy
# umount /tmp/mnt 
# mount /dev/nbd0p1 /tmp/mnt/
# md5sum /tmp/mnt/file_to_copy
42b0a3bf73f704d03ce301716d7654de  /tmp/mnt/file_to_copy

The first hash was obviously the right one.

On a previous attempt I did, I spotted thanks to vbindiff that parts of the file were just filed with 0s instead of actual data.
It will randomly work after several attempts to write.

Version information:
# qemu-nbd --version
qemu-nbd version 0.0.1
Written by Anthony Liguori.

Cheers,

** Affects: qemu
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1422307

Title:
  qemu-nbd corrupts files

Status in QEMU:
  New

Bug description:
  Dear all,

  On Trusty, in certain situations, try to copy files over a qemu-nbd
  mounted file system leads to write errors (and thus, file corruption).

  Here is the last example I tried:
  -> virtual disk is a VDI disk
  -> It has only one partition, in FAT

  Here is my mount process:
  # modprobe nbd max_part=63
  # qemu-nbd -c /dev/nbd0 "virtual_disk.vdi"
  # partprobe /dev/nbd0
  # mount /dev/nbd0p1 /tmp/mnt/

  Partition is properly mounted at that point:
  /dev/nbd0p1 on /tmp/mnt type vfat (rw)

  Now, when I copy a file (rather big, ~28MB):
  # cp file_to_copy /tmp/mnt/ ; sync
  # md5sum /tmp/mnt/file_to_copy
  2efc9f32e4267782b11d63d2f128a363  /tmp/mnt/file_to_copy
  # umount /tmp/mnt 
  # mount /dev/nbd0p1 /tmp/mnt/
  # md5sum /tmp/mnt/file_to_copy
  42b0a3bf73f704d03ce301716d7654de  /tmp/mnt/file_to_copy

  The first hash was obviously the right one.

  On a previous attempt I did, I spotted thanks to vbindiff that parts of the file were just filed with 0s instead of actual data.
  It will randomly work after several attempts to write.

  Version information:
  # qemu-nbd --version
  qemu-nbd version 0.0.1
  Written by Anthony Liguori.

  Cheers,

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1422307/+subscriptions

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

end of thread, other threads:[~2015-09-09  1:35 UTC | newest]

Thread overview: 25+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-16 10:05 [Qemu-devel] [Bug 1422307] [NEW] qemu-nbd corrupts files Pierre Schweitzer
2015-02-17 14:50 ` [Qemu-devel] [Bug 1422307] " Max Reitz
2015-02-17 14:50 ` Max Reitz
2015-02-17 17:18 ` Max Reitz
2015-02-17 18:22 ` Max Reitz
2015-02-17 19:21 ` Max Reitz
2015-02-17 21:25 ` Max Reitz
2015-02-18  9:11 ` Pierre Schweitzer
2015-02-18 13:58   ` Stefan Hajnoczi
2015-02-19 17:48 ` Pierre Schweitzer
2015-02-23 10:42   ` Stefan Hajnoczi
2015-04-09  8:00 ` Pierre Schweitzer
2015-07-06 11:40 ` Nicolas Rüegg
2015-07-06 13:46 ` Max Reitz
2015-07-06 14:46 ` Pierre Schweitzer
2015-08-17 10:29 ` Robie Basak
2015-08-17 10:30 ` Robie Basak
2015-08-19  7:28 ` Pierre Schweitzer
2015-08-26 16:49 ` Serge Hallyn
2015-08-26 21:32 ` Serge Hallyn
2015-08-27 22:41 ` Brian Murray
2015-08-28  6:29 ` Pierre Schweitzer
2015-08-28  6:42 ` Pierre Schweitzer
2015-09-09  1:28 ` Launchpad Bug Tracker
2015-09-09  1:28 ` [Qemu-devel] [Bug 1422307] Update Released Chris Halse Rogers

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