Sun Service Tags and Inventory Channel
Recently I have been working on a new Java SE project related to a Sun Connection Technology called Service Tags. I'd like to give a short introduction of the Sun Service Tags technology that you may find various interesting ideas of leveraging it.
Sun Service Tags
The Sun Service Tags enable automatic discovery of the tagged systems and softwares on your systems or a local network. The JDK and JRE 6 update 4 will become discoverable when installed on Solaris and Linux service tag enabled systems. The Sun Service Tags are not limited for Sun products. You can create the service tags for your own products (hardwares, softwares, or services) and leverage the discovery capability for your environment to use.
Discoverable products are registerable at Sun Connection Inventory Channel. I'll talk about the JDK product registration next in a couple of weeks.
What is a Service Tag?
Sun Service Tag is a XML-based unique identifer of a product instance containing a set of basic information about the product instance on a system. Below represents a service tag of a JDK instance.
|instance_urn||urn:st:16f1e569-c583-4190-85ab-42339d984449||Unique identifier for the product instance|
|product_name||Java SE 6 Development Kit||Product name|
|product_parent_urn||urn:uuid:fdc90b21-018d-4cab-b866-612c7c119ed3||Product parent ID|
|product_parent||Java Platform Standard Edition 6 (Java SE 6)||Product parent name|
|product_defined_inst_id||id=1.6.0_04-ea-b07 x86||Product defined instance ID|
|product_vendor||Sun Microsystems||Product vendor|
|platform_arch||x86||Targeted product architecture|
|source||Windows JDK i586 installer||Source of the product instance|
|container||global||OS container (e.g. Zonename)|
The product_urn field of Sun products is in this format "urn:uuid:" followed with a 32 character long UUID but is not required by Sun Service Tags. You can also embed additional information about a product besides the basic one in the product_defined_instance_id field.
Service Tag Enabled System
To enable service tags technology, you need to install the Service Tags Software that consists of:
- Service Tags (ST) Registry: A XML-based registry that contains all service tags on a system locating at
/var/sadm/servicetag/registry/servicetag.xmlon Solaris and Linux or
c:\Program Files\Sun\servicetagon Windows (or [ProgramFilesFolder]\Sun\servicetag if you have a different folder for program files).
- A stclient utility: A command-line utility to add, update, and remove a service tag from the ST registry.
- ST discoverer and listener: Two network services facilitating auto discovery,
Create your own service tag
Once you enable Service Tags on your system, you can add a service tag for any hardware, software or anything else you want to be tagged. For example, I have created a service tag for Skype just as an example by using the
stclient utility (I installed Skype on my laptop for making international calls to my mom in Hong Kong) . You can do it in an interactive mode or with the
c:\Program Files\Sun\servicetag>.\stclient > a Enter instance URN (optional): Enter product (e.g. Sun Web Server): Skype Enter version (e.g. 6.1): 3.6 Enter product URN: A-unique-ID-for-Skype Enter product parent URN: A-unique-ID-for-its-parent Enter product parent (e.g. JES): Free software Enter product defined instance id: Enter product vendor (e.g. Sun): Skype Enter platform arch (e.g. SPARC): x86 Enter container (e.g. zone 0): global Enter source (e.g. genesis patch): SkypeSetup.exe Skype 3.6 added Product instance URN=urn:st:1f158110-de82-11dc-a0f1-000f1f14443e Press enter to continue
stclient will create an entry in ST registry containing the given information and it will assign a product instance URN if not specified. You can run the
stclient -g -i command to get the service tag of a given product instance URN or
stclient -x to view all service tags in the ST registry. Below is the XML entry in the ST registry I added for Skype.
<service_tag> <instance_urn>urn:st:1f158110-de82-11dc-a0f1-000f1f14443e</instance_urn> <product_name>Skype</product_name> <product_version>3.6</product_version> <product_urn>A-unique-ID-for-Skype</product_urn> <product_parent>Free software</product_parent> <product_parent_urn>A-unique-ID-for-its-parent</product_parent_urn> <product_defined_inst_id></product_defined_inst_id> <product_vendor>Skype</product_vendor> <platform_arch>x86</platform_arch> <timestamp>2008-02-19 00:32:16 GMT</timestamp> <container>global</container> <source>SkypeSetup.exe</source> <installer_uid>0</installer_uid> </service_tag>
ST discoverer and listener services allow the system to be discovered via the Registration Manager client tool. These network services only communicate the service tag information with the Registration Manager client tool and do not communicate with any other services on your system.
These are the screenshots of the Registration Manager client tool looking up the tagged products on my laptop:
The first screenshot shows that you can configure the Registration Manager client tool to perform the discovery on a local subnet or one or more specified systems. Note that the Registration Manager performs no communication with Sun until you decide to perform the "registration" step. I will blog about product registration later.
The second screenshot shows the list of tagged products on your system including my tagged Skype. Several Sun hardware and software products including JDK and NetBeans IDE are discoverable and more are being added over time. A service tag for the Windows OS is also created as part of the Service Tags software installation.
Sun Connection Inventory Channel is a free offering from Sun that provides a centralized repository to organize the deployed products on your systems and report on them using the report generation tool. My next blog about JDK product registration will cover more about it.
One of the most basic and difficult problems IT departments have today is to simply know what systems, softwares, and even services they have. Systems and softwares are installed by various team members at all times. Systems are shut down and new software is upgraded. Sun Service Tags and Inventory Channel give IT new tools to manage this complexity. For example, you can quickly determine what JDK and JRE instances (Java SE 6 update 4 and later releases) are installed on which systems in your environment.
For More Information
- Sun Inventory
- Sun Service Tag FAQ
- The Sun Connection Inventory Channel in a Nutshell
- Registering Your Inventory in the Disconnected Mode