[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Simplified protocol?



On Thu, Nov 15, 2018 at 03:41:08PM +0100, Wouter Verhelst wrote:
> +### Baseline
> +
> +The following MUST be implemented by all implementations, and should be
> +considered a baseline:
> +
> +- NOTLS mode
> +- The fixed newstyle handshake
> +- During the handshake:
> +
> +    - the `NBD_OPT_INFO` and `NBD_OPT_GO` messages, with the
> +      `NBD_INFO_EXPORT` response.
> +    - Servers that receive messages which they do not implement MUST
> +      reply to them with `NBD_OPT_UNSUP`, and MUST NOT fail to parse
> +      the next message received.
> +    - the `NBD_OPT_ABORT` message, and its response.
> +    - the `NBD_OPT_LIST` message and its response.
> +
> +- During the transmission phase:
> +
> +    - Simple replies
> +    - the `NBD_CMD_READ` message (and its response)
> +    - the `NBD_CMD_WRITE` message (and its response)

Could drop this, or note that it's only necessary for read/write
exports.

> +Clients and servers that desire maximum interoperability SHOULD
> +implement the following features:
> +
> +- TLS-encrypted communication, which may be required by some
> +  implementations or configurations;
> +- Servers that implement block constraints through `NBD_INFO_BLOCK_SIZE`
> +  and desire maximum interoperability SHOULD NOT require them.
> +  Similarly, clients that desire maximum interoperability SHOULD
> +  implement querying for block size constraints. Since some older
> +  clients default to a block size of 1024 bytes, implementations
> +  desiring maximum interoperability MAY default to that size.
> +- Clients or servers that desire interoperability with older
> +  implementations SHOULD implement the `NBD_OPT_EXPORT_NAME` message in
> +  addition to `NBD_OPT_INFO` and `NBD_OPT_GO`.
> +- For data safety, implementing `NBD_CMD_FLUSH` and the
> +  `NBD_CMD_FLAG_FUA` flag to `NBD_CMD_WRITE` is strongly recommended.

This section mixes clients and servers, and I wonder if it would be
better to separate them out?

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines.  Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v


Reply to: