This repository contains metadata retrieval and manipulation tools for use within guests of the SmartOS (and SDC) hypervisor. These guests may be either SmartOS Zones or KVM virtual machines.
This repository is part of the Joyent SmartDataCenter project (SDC). For contribution guidelines, issues, and general documentation, visit the main SDC project page.
There are four commands provided in this consolidation:
- mdata-list(1M); list custom metadata keys in the metadata store
- mdata-get(1M); get the value of a particular metadata key
- mdata-put(1M); set the value of a particular metadata key
- mdata-delete(1M); remove a metadata key
Manual pages for these tools are available in this repository, and are generally shipped with the OS (in the case of SmartOS) or in the package (e.g. for Ubuntu). They are also viewable on the web at the links above.
Protocol and Transport
The Joyent Metadata Protocol is documented online. The programs in this repository are clients that communicate using this protocol. The SmartOS (or SmartDataCenter) hypervisor provides a common set of supported base metadata keys for guests to consume, as well as the ability to support arbitrary additional user-provided metadata.
In a SmartOS container/zone guest, a UNIX domain socket is used to communicate
with the metadata server running in the hypervisor. In a KVM guest, such as a
Linux virtual machine, the client tools will make use of the second serial port
COM2) to communicate with the hypervisor.
The tools currently build and function on SmartOS and various Linux distributions. Support for other operating systems, such as *BSD or Windows, is absolutely welcome.
MIT (See LICENSE.)