Home > Articles > Operating Systems, Server > Linux/UNIX/Open Source

Using the Linux Standard Base Sample Implementation

  • Print
  • + Share This
The LSB Sample Implementation (LSB-si) is a stand-alone Linux distribution that can run isolated on a virtual machine, and is used for testing LSB applications in a secure, isolated environment. This chapter will show you how to use this mini-OS to test your apps.
This chapter is from the book

The LSB Sample Implementation (LSB-si) is a minimal LSB-conformant runtime environment used for testing purposes. Think of it as a tiny Linux distribution that you have complete control over. It can be booted as a standalone system, hosted inside a virtual machine, or run in a change-root mode. It is particularly convenient to use hosted mode as a way to enable an LSB test environment to exist on a system without disrupting the base system, thus reducing the need for multiple dedicated LSB test machines.

LSB-compliant applications should be tested inside the LSB-si to insure they haven't picked up any distribution-specific quirks. The LSB Certification program, as outlined in Chapter 7, requires that an application be tested under the LSB-si.

The LSB-si can also be used in a variety of validation scenarios where there's a desire to limit the installed environment to the minimal set required by the LSB.

12.1 Understanding the Sample Implementation

The LSB-si is an example runtime environment implementation. It is the accumulation of elements that are both explicitly required and implied by the LSB Written Specification, plus any necessary dependencies to make the runtime environment work.

The LSB-si has three main purposes. First, it is an example implementation to demonstrate the features and correctness of the LSB Written Specification. Second, it serves as an example of building an LSB-conformant system from current open source packages without a lot of special patching. Thirdly, the LSB-si is a testing sandbox to help evaluate the LSB compliance of an application. If an application fails because it requires something not found in the LSB-si, then this is an opportunity to trim or rework the dependencies of an application to help better conform to the LSB.

The LSB-si is a sample implementation, not a reference implementation. The difference is that a sample implementation demonstrates one way to conform to the specification, while a reference implementation serves as a baseline for conformance validation. In a reference implementation scenario, other implementors are required to be compatible with all of the reference implementation, including all the features and bugs unintentially present in it. In addition, a reference implementation constrains the evolution of other implementations because even legitimate enhancements or fixes would deviate from the reference, thus breaking adherence.

The LSB is an ABI specification designed to capture the functional requirements of a conforming system without locking in any specific implementation, versions of software packages, and so on, as being the standard. By specifying the behavior of required elements and avoiding a reference implementation, the LSB permits conforming runtime environments and applications to evolve within the ABI confines of the Written Specification.

  • + Share This
  • 🔖 Save To Your Account