Skip to content

Commits

Permalink
logical-partit…
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Commits on Jan 22, 2019

  1. tests: Duplicate test-partitioning4.sh for MBR.

    Since both the partitioning plugin and partition filter now support
    MBR logical partitions, the original test for GPT
    (test-partitioning4.sh) can be duplicated and modified to test MBR.
    rwmjones committed Jan 22, 2019
    Copy the full SHA
    bc77ab3 View commit details
    Browse the repository at this point in the history
  2. tests: Implement a better nbdkit-partition-filter test.

    Test the partition filter against real life partition tables created
    by sfdisk.
    rwmjones committed Jan 22, 2019
    Copy the full SHA
    cdc307f View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    e4a7652 View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    56a6891 View commit details
    Browse the repository at this point in the history
  5. partition: Break long line of code.

    Simple whitespace-only change, updating
    commit 188b159.
    rwmjones committed Jan 22, 2019
    Copy the full SHA
    ae36565 View commit details
    Browse the repository at this point in the history

Commits on Jan 21, 2019

  1. partition: Use SECTOR_SIZE instead of hard-coding 512 everywhere.

    This probably doesn't make the sector size adjustable, but at least
    documents where we make this assumption.
    rwmjones committed Jan 21, 2019
    Copy the full SHA
    188b159 View commit details
    Browse the repository at this point in the history
  2. partition: Move MBR and GPT parsing code to separate files.

    Simply code motion, there should be no change to the functionality.
    rwmjones committed Jan 21, 2019
    Copy the full SHA
    aac9047 View commit details
    Browse the repository at this point in the history
  3. partitioning: Use bool in appropriate places.

    Trivial code refactoring with no functional change.
    rwmjones committed Jan 21, 2019
    Copy the full SHA
    fcbdc20 View commit details
    Browse the repository at this point in the history

Commits on Jan 20, 2019

  1. server: Return bool from is_config_key.

    This function does not return any error, so it can use bool.
    rwmjones committed Jan 20, 2019
    Copy the full SHA
    22cf8f2 View commit details
    Browse the repository at this point in the history

Commits on Jan 18, 2019

  1. Copy the full SHA
    fb882a1 View commit details
    Browse the repository at this point in the history
  2. docs: Miscellaneous revisions to nbdkit-loop(1) man page.

    All suggested by Eric Blake:
    
    - Users may need to ‘modprobe nbd’ to load the kernel module.
    
    - Warn about loop mounting untrusted filesystems and suggest
      libguestfs for this instead.
    rwmjones committed Jan 18, 2019
    Copy the full SHA
    9ce6bbf View commit details
    Browse the repository at this point in the history
  3. openbsd: Disable ANSI C test on OpenBSD.

    The ancient GCC on OpenBSD does not support the -std=c90 option.
    Change ./configure so it can detect this and disable the test where
    not available.
    rwmjones committed Jan 18, 2019
    Copy the full SHA
    802336c View commit details
    Browse the repository at this point in the history
  4. Version 1.10.0.

    rwmjones committed Jan 18, 2019
    Copy the full SHA
    d4d209f View commit details
    Browse the repository at this point in the history
  5. tests: Test that public headers are ANSI (ISO C90) compatible.

    In commit 3775916 (and before that in
    discussions with Eric) we decided that we should try to allow plugins
    to be compiled with C compilers other than GCC or Clang (or with very
    old / peculiar / incompatible versions of those compilers).
    
    However until we test this we cannot guarantee that changes to the
    code will not break this in future, hence this test.
    
    Note that GCC or Clang is still required to compile nbdkit itself.
    rwmjones committed Jan 18, 2019
    Copy the full SHA
    25eef3a View commit details
    Browse the repository at this point in the history
  6. include: Fix NBDKIT_HANDLE_NOT_NEEDED for C90 compilers.

    When an ANSI/C90 plugin compiled with ‘-pedantic’ uses
    NBDKIT_HANDLE_NOT_NEEDED it gets the error:
    
      ISO C forbids conversion of function pointer to object pointer type
    
    This is because the existing macro worked by returning a function
    pointer but in C90 function pointers cannot be cast to data pointers
    since on some ancient architectures code and data pointers were
    incompatible.
    
    We only need a convenient global data pointer here, and the address of
    ‘errno’ should be fine.
    rwmjones committed Jan 18, 2019
    Copy the full SHA
    d5733ec View commit details
    Browse the repository at this point in the history

Commits on Jan 16, 2019

  1. build: Don't link everything, only the server, with libselinux.

    The server can link to libselinux to support SELinux socket labelling.
    However because we added the library to $LIBS it got linked into
    everything, eg:
    
    $ eu-readelf -d /usr/lib64/nbdkit/plugins/nbdkit-memory-plugin.so |
        grep NEEDED
      NEEDED            Shared library: [libselinux.so.1]
      NEEDED            Shared library: [libc.so.6]
    
    Libselinux has a pkg-config file so we can use that to detect
    the library and adjust server/Makefile.am so it is only linked
    into the server.
    
    This dependency is still optional.
    rwmjones committed Jan 16, 2019
    Copy the full SHA
    6c51add View commit details
    Browse the repository at this point in the history

Commits on Jan 15, 2019

  1. Version 1.9.10.

    rwmjones committed Jan 15, 2019
    Copy the full SHA
    7ed7e09 View commit details
    Browse the repository at this point in the history
  2. server: Include <errno.h> in some files.

    Fixes FreeBSD and OpenBSD compilation which was broken by the code
    refactoring in commit 6193863.
    rwmjones committed Jan 15, 2019
    Copy the full SHA
    8ce27da View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    deb8f99 View commit details
    Browse the repository at this point in the history
  4. server: connections: Use send(2) and recv(2) instead of write and read.

    Winsock only lets you use send/recv, and it shouldn't make any
    difference on Linux either.
    rwmjones committed Jan 15, 2019
    Copy the full SHA
    327ddff View commit details
    Browse the repository at this point in the history
  5. server: sockets: Refactor accept_incoming_connections.

    This is a simple refactoring of the function, allowing us to
    reimplement the inner loop for Windows in a future commit.  Note that
    I made explicit that fds[nr_socks] is used for the quit_fd entry,
    previously this was implicit which was somewhat confusing.
    rwmjones committed Jan 15, 2019
    Copy the full SHA
    512a000 View commit details
    Browse the repository at this point in the history
  6. server: Refactor more parts of main.c into separate files.

    This split is simple code motion.  However it does allow two things:
    we can document more clearly the interfaces between the main code and
    these functions, and it makes it a bit easier to provide alternative
    implementations for Windows.
    rwmjones committed Jan 15, 2019
    Copy the full SHA
    6193863 View commit details
    Browse the repository at this point in the history

Commits on Jan 13, 2019

  1. server: Move quit pipe code to a separate file.

    No functional change, simply refactoring.
    rwmjones committed Jan 13, 2019
    Copy the full SHA
    b2819d3 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    59fce61 View commit details
    Browse the repository at this point in the history
  3. data: Print correct final size.

    This fixes a debugging message which showed the incorrect size
    variable.
    rwmjones committed Jan 13, 2019
    Copy the full SHA
    59a9f9f View commit details
    Browse the repository at this point in the history
  4. server: Use special attribute((format)) for varargs print functions.

    Also tidy up an existing declaration so it matches similar decls
    elsewhere in the header file.
    rwmjones committed Jan 13, 2019
    Copy the full SHA
    9783c78 View commit details
    Browse the repository at this point in the history

Commits on Jan 12, 2019

  1. tests: cxx: Return NBDKIT_HANDLE_NOT_NEEDED from open callback.

    In commit 6c4092a we introduced the
    concept of the open callback returning NBDKIT_HANDLE_NOT_NEEDED for
    plugins which do not need a handle.  The C++ test uses this archetype
    too, but in a slightly different form so that commit did not modify
    this test plugin before.
    rwmjones committed Jan 12, 2019
    Copy the full SHA
    4f070eb View commit details
    Browse the repository at this point in the history
  2. sh: Document can_multi_conn callback in the manual.

    Fixes commit 627727e which omitted to
    updated the manual.
    rwmjones committed Jan 12, 2019
    Copy the full SHA
    4cffc76 View commit details
    Browse the repository at this point in the history
  3. Copy the full SHA
    09cae96 View commit details
    Browse the repository at this point in the history

Commits on Jan 11, 2019

  1. Update todo.

    rwmjones committed Jan 11, 2019
    Copy the full SHA
    1cac7e4 View commit details
    Browse the repository at this point in the history

Commits on Jan 9, 2019

  1. Copy the full SHA
    b55d856 View commit details
    Browse the repository at this point in the history

Commits on Jan 7, 2019

  1. Version 1.9.9.

    rwmjones committed Jan 7, 2019
    Copy the full SHA
    b8d80d3 View commit details
    Browse the repository at this point in the history

Commits on Jan 5, 2019

  1. data, memory: Use fine-grained locking and change thread model to par…

    …allel.
    
    Instead of implicitly locking around every request, use an explicit
    and (slightly) more fine-grained lock, and change the thread model to
    parallel.  The same change is made to the memory plugin and the data
    plugin.
    
    This improves performance slightly.  Using fio with 8 threads and
    multi-conn enabled with -C 8:
    
    Before:
       read: IOPS=103k, BW=401MiB/s (420MB/s)(46.0GiB/120002msec)
      write: IOPS=103k, BW=401MiB/s (420MB/s)(46.0GiB/120002msec)
    
    After:
       read: IOPS=112k, BW=437MiB/s (458MB/s)(51.2GiB/120001msec)
      write: IOPS=112k, BW=437MiB/s (458MB/s)(51.2GiB/120001msec)
    
    For comparison:
    
    The memory plugin implemented using a simple malloc instead of a
    sparse array:
       read: IOPS=133k, BW=518MiB/s (544MB/s)(60.7GiB/120002msec)
      write: IOPS=133k, BW=518MiB/s (543MB/s)(60.7GiB/120002msec)
    
    Directly running fio against /dev/shm:
       read: IOPS=1018k, BW=3978MiB/s (4171MB/s)(466GiB/120001msec)
      write: IOPS=1018k, BW=3979MiB/s (4172MB/s)(466GiB/120001msec)
    rwmjones committed Jan 5, 2019
    Copy the full SHA
    a76cc95 View commit details
    Browse the repository at this point in the history
  2. data, memory: Return NBD_FLAG_CAN_MULTI_CONN.

    These plugins use NBDKIT_THREAD_MODEL_SERIALIZE_ALL_REQUESTS because
    of their use of the global sparse array.  However since they are both
    RAM disks, and thus (a) flush is a no-op, and (b) the locked part of
    each request is short, it is both safe and there is some performance
    benefit to using NBD_FLAG_CAN_MULTI_CONN.
    
    Without multi-conn:
    
       read: IOPS=52.8k, BW=206MiB/s (216MB/s)(24.2GiB/120002msec)
      write: IOPS=52.8k, BW=206MiB/s (216MB/s)(24.2GiB/120002msec)
    
    With multi-conn (-C 8):
    
       read: IOPS=103k, BW=401MiB/s (420MB/s)(46.0GiB/120002msec)
      write: IOPS=103k, BW=401MiB/s (420MB/s)(46.0GiB/120002msec)
    rwmjones committed Jan 5, 2019
    Copy the full SHA
    dbd8629 View commit details
    Browse the repository at this point in the history
  3. partitioning: Return NBD_FLAG_CAN_MULTI_CONN.

    This plugin has a parallel thread model and handles flush correctly
    across connections, so return NBD_FLAG_CAN_MULTI_CONN.
    rwmjones committed Jan 5, 2019
    Copy the full SHA
    048c34e View commit details
    Browse the repository at this point in the history
Older