Menu

How to Create an AI Server

In my last post, I covered the topic of creating a local Solaris 11 IPS repository accessible via HTTP. It is a primer for the information covered below, so you should read it to assist with the information that follows. Today our topic is ‘How to Create an AI Server’ and is the second part of this three-part series. As many of you may not be familiar, AI is the Automated Installer for Solaris 11. It is a complete replacement of it’s predecessor, JumpStart. It is a much more modern and robust installation system using customizable XML based profiles. One of the key benefits of AI is the ability to completely install a system via HTTP without the need for a bootable CD/DVD/ISO locally installed (or attached) to a system. While AI is capable of both SPARC based and x86 based installations, our scope will be limited to the SPARC based architecture (for which there is no need for DHCP or PXE). SPARC based AI installations are capable of installing over a WAN (which we will cover near the end of this post).

As a recap, there is already an IPS repository on our system using Solaris 11 (snv_167 build). Our existing repository is located at /IPS/s11-167/repo. It is now time to install the AI Server and configure it for use. First, we need to create a ZFS file system to contain our AI server. In this instance we will create two file systems rpool/AI and rpool/AI/s11-167 to logically separate Solaris 11 snv_167 from any potential future AI configurations we wish to host.

Next, we perform a couple of preliminary tasks. We need to enable the dns/multicast service because AI looks for it to be online since it is listed as a dependency in the install/server service. We do this via the svcadm command below.

The second part of our cleanup commands is specific to the snv_167 build. During packaging, the Oracle developers missed a critical file, cssselect.py in the library/python-2/lxml-26 package. This caused days of trial and error with debugging for me with AI in build snv_167 before I finally obtained the answer and received the cssselect.py from support. This particular issue should not be present in future builds. However, it helps to verify before creating the AI service. The cssselect.py file needs to be located at /usr/lib/python2.6/vendor-packages/lxml/cssselect.py with ownership set to root:bin and permissions set to 444 as follows.

Now, we can finally use the installadm command to create our AI service using the AI ISO image without DHCP. Note the Oracle documentation describes both with and without DHCP. If you are not using DHCP, your environment should have a system in place to statically assign IP addresses and hostnames via a DNS system and the DNS system should be updated prior to attempting to install a system from the AI service.

# installadm create-service -n s11-167-sparc -s \
/var/tmp/iso/sol-11-dev-167-ai-sparc.iso /AI/s11-167
Setting up the target image at /AI/s11-167 ...
Refreshing install services
Detected that DHCP is not set up on this server.
If not already configured, please create a DHCP macro
named 10.36.128.0 with:
Boot file (BootFile) : \"http://10.36.136.7:5555/cgi-bin/wanboot-cgi\"
If you are running the Oracle Solaris DHCP Server, use the following
command to add the DHCP macro, 10.36.128.0:
/usr/sbin/dhtadm -g -A -m 10.36.128.0 -d \
:BootFile=\"http://10.36.136.7:5555/cgi-bin/wanboot-cgi\":
Note: Be sure to assign client IP address(es) if needed
(e.g., if running the Oracle Solaris DHCP Server, run pntadm(1M)).
Service discovery fallback mechanism set up
Creating SPARC configuration file
#

As mentioned previously, we will not use DHCP for our AI server. Eventhough it appears that this must be done according to the output of the installadm create-service command, it is most likely not a best practice in large environments.

Now that our AI service has been created, we need to slightly tweak our default manifest file for installing the Solaris 11 operating system. For the sake of brevity, I will not cover all of the possibilities for modifications. However, as general background information, the AI service uses XML based configuration files. It is possible to completely customize an installation by creating XML based profiles specifying exactly to which devices, clients (systems), networking, configuration, and default users you desire. There are example profiles listed under your default AI service location (e.g. /AI/s11-167/auto_install/sc_profiles). Likewise, there are XML based manifests that can be customized for a specific AI service to install any valid packages from any IPS repositories you wish. The manifest files are located under a similar path (e.g. /AI/s11-167/auto_install/manifest). Also note, that with each new build (for developers – snv_167) changes are made to the XML specifications allowing more advanced customizations. For our example we will only edit the default manifest. The changes we make to our default manifest follow. First, we backup the default manifest.

Next, since we are only dealing with SPARC based systems and not x86 based systems, we want to add the auto_reboot attribute to the ai_instance tag. This should not be done for x86 based systems since the boot order is not guaranteed on x86.

<ai_instance name="default" auto_reboot="true">

Next, let’s change the name of the boot environment to snv_167 from the default of solaris just so we’re clear on which build we are using.

to the one we created in my previous post using the system’s IP address along with the port we specified for our IPS repository:

<origin name="http://10.36.136.7:10000"/>

If you are unsure of the port you specified, it can be verified using the svccfg -s pkg/server listprop pkg/port command.

For our last change to the default manifest, we want to add a section that will install any missing or third party drivers our clients may need that we already have in our IPS repository using the add_drivers tag as follows.

It’s time to test out our AI service backed by our Solaris 11 IPS repository. In this example, an LDom (Oracle VM on SPARC) is being used, but it works identically on any modern physical SPARC based system capable of wanboot. First we need to get the MAC address from our client system on which we want to install Solaris 11 with AI. We can do this from the OBP prompt as follows.

Now that our AI server knows about our client system, we can initiate the wanboot (remote installation) process from our client system. First we set our client system to auto-boot?=true and set the OBP value for network-boot-arguments with our client information and the HTTP location of our bootable image. It’s important to understand that the output below does not contain any spaces, tabs, or return characters between the comma-separated values for the network-boot-arguments. Doing so will not work and cause unnecessary troubleshooting. If you are not familiar with this value, it is documented in the man page for eeprom in the Oracle Solaris 11 Express documentation.

Once the installation is complete (approximately 20 minutes on my network) the system will reboot and you will be prompted to walk through the basic configuration tasks required by the installer (image below).

Finally, once you have gone through the installer and completed the post-install configuration tasks, you now have a working system at a login prompt ready for work.

Note, however, the manual post-install configuration tasks required by the installer can be eliminated entirely by establishing customized profiles containing the specific information for your client systems. Refer to Oracle’s documentation (or the XML DTD files) for specifics on the allowed tags and attributes for both manifests and profiles for your customized AI service.

In my next post, I will continue on the topic of IPS and cover “How to Publish Your Own IPS Packages”. It will include creating an IPS repository to hold your own packages which others will be able to install remotely.

Happy installing and stay tuned for more!

Advertisements

Share this:

Like this:

Brad Hudson is an Established Leader in IT Infrastructure, Engineering, Operations, and Customer Service with extensive experience developing and delivering infrastructure solutions, building and growing customer service organizations, leading change initiatives, providing data center management, and managing implementation activities.

Brad Hudson is an Established Leader in IT Infrastructure, Engineering, Operations, and Customer Service with extensive experience developing and delivering infrastructure solutions, building and growing customer service organizations, leading change initiatives, providing data center management, and managing implementation activities.[Read More...]