1. 08 3月, 2019 1 次提交
  2. 20 11月, 2018 1 次提交
  3. 05 11月, 2018 1 次提交
    • C
      iotests: make 083 specific to raw · d98205c5
      Cleber Rosa 提交于
      While testing the Python 3 changes which touch the 083 test, I noticed
      that it would fail with qcow2.  Expanding the testing, I noticed it
      had nothing to do with the Python 3 changes, and in fact, it would not
      pass on anything but raw:
      
       raw: pass
       bochs: not generic
       cloop: not generic
       parallels: fail
       qcow: fail
       qcow2: fail
       qed: fail
       vdi: fail
       vhdx: fail
       vmdk: fail
       vpc: fail
       luks: fail
      
      The errors are a mixture I/O and "image not in xxx format", such as:
      
        === Check disconnect before data ===
      
        Unexpected end-of-file before all bytes were read
       -read failed: Input/output error
       +can't open device nbd+tcp://127.0.0.1:PORT/foo: Could not open 'nbd://127.0.0.1:PORT/foo': Input/output error
      
        === Check disconnect after data ===
      
       -read 512/512 bytes at offset 0
       -512 bytes, X ops; XX:XX:XX.X (XXX YYY/sec and XXX ops/sec)
       +can't open device nbd+tcp://127.0.0.1:PORT/foo: Image not in qcow format
      
      I'm not aware if there's a quick fix, so, for the time being, it looks
      like the honest approach is to make the test known to work on raw
      only.
      Signed-off-by: NCleber Rosa <crosa@redhat.com>
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      d98205c5
  4. 15 11月, 2017 1 次提交
    • M
      iotests: Make 083 less flaky · ddc7093e
      Max Reitz 提交于
      083 has (at least) two issues:
      
      1. By launching the nbd-fault-injector in background, it may not be
         scheduled until the first grep on its output file is executed.
         However, until then, that file may not have been created yet -- so it
         either does not exist yet (thus making the grep emit an error), or it
         does exist but contains stale data (thus making the rest of the test
         case work connect to a wrong address).
         Fix this by explicitly overwriting the output file before executing
         nbd-fault-injector.
      
      2. The nbd-fault-injector prints things other than "Listening on...".
         It also prints a "Closing connection" message from time to time.  We
         currently invoke sed on the whole file in the hope of it only
         containing the "Listening on..." line yet.  That hope is sometimes
         shattered by the brutal reality of race conditions, so make the sed
         script more robust.
      Signed-off-by: NMax Reitz <mreitz@redhat.com>
      Message-id: 20171109203025.27493-5-mreitz@redhat.com
      Reviewed-by: NEric Blake <eblake@redhat.com>
      Signed-off-by: NMax Reitz <mreitz@redhat.com>
      ddc7093e
  5. 31 8月, 2017 1 次提交
    • S
      qemu-iotests: test NBD over UNIX domain sockets in 083 · 02d2d860
      Stefan Hajnoczi 提交于
      083 only tests TCP.  Some failures might be specific to UNIX domain
      sockets.
      
      A few adjustments are necessary:
      
      1. Generating a port number and waiting for server startup is
         TCP-specific.  Use the new nbd-fault-injector.py startup protocol to
         fetch the address.  This is a little more elegant because we don't
         need netstat anymore.
      
      2. The NBD filter does not work for the UNIX domain sockets URIs we
         generate and must be extended.
      
      3. Run all tests twice: once for TCP and once for UNIX domain sockets.
      Reviewed-by: NEric Blake <eblake@redhat.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      Message-Id: <20170829122745.14309-4-stefanha@redhat.com>
      Signed-off-by: NEric Blake <eblake@redhat.com>
      02d2d860
  6. 12 5月, 2016 1 次提交
  7. 15 4月, 2016 1 次提交
  8. 03 2月, 2016 3 次提交
  9. 16 1月, 2016 1 次提交
    • F
      nbd: Split nbd.c · 798bfe00
      Fam Zheng 提交于
      We have NBD server code and client code, all mixed in a file. Now split
      them into separate files under nbd/, and update MAINTAINERS.
      
      filter_nbd for iotest 083 is updated to keep the log filtered out.
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Message-Id: <1452760863-25350-3-git-send-email-famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      798bfe00
  10. 07 2月, 2015 1 次提交
    • M
      nbd: Improve error messages · 1ce52846
      Max Reitz 提交于
      This patch makes use of the Error object for nbd_receive_negotiate() so
      that errors during negotiation look nicer.
      
      Furthermore, this patch adds an additional error message if the received
      magic was wrong, but would be correct for the other protocol version,
      respectively: So if an export name was specified, but the NBD server
      magic corresponds to an old handshake, this condition is explicitly
      signaled to the user, and vice versa.
      
      As these messages are now part of the "Could not open image" error
      message, additional filtering has to be employed in iotest 083, which
      this patch does as well.
      Signed-off-by: NMax Reitz <mreitz@redhat.com>
      Reviewed-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      1ce52846
  11. 28 6月, 2014 2 次提交
  12. 15 5月, 2014 1 次提交
  13. 09 5月, 2014 1 次提交
  14. 14 3月, 2014 1 次提交
    • S
      qemu-iotests: add 083 NBD client disconnect tests · dc668ded
      Stefan Hajnoczi 提交于
      This new test case uses nbd-fault-injector.py to simulate broken TCP
      connections at each stage in the NBD protocol.  This way we can exercise
      block/nbd-client.c's socket error handling code paths.
      
      In particular, this serves as a regression test to make sure
      nbd-client.c doesn't cause an infinite loop by leaving its
      nbd_receive_reply() fd handler registered after the connection has been
      closed.  This bug was fixed in an earlier patch.
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      dc668ded