0 Replies Latest reply on Aug 17, 2009 10:17 AM by Gerardo Bartoccini

    Extending Bulk Installer usage

    Gerardo Bartoccini

      We have been under the urgency of using the Bulk installer for some more activities than just simple RSCD agent installation.


      This was due to two main reasons:

      • security product on the target server (CA eTrust Access Control)

      • need to change listening port (=> agent restart needed)


      The "SSH installer with sudo" option could not be used due to the specific security product settings at customer site, and to the fact that the sudo command only applies to agent installer, not the pre and post install scripts.


      We have been considering many different options, but we ended up with a solution based on makeself.sh


      The main problem we had to face was Bulk Installer file copy feature. Only the agent installer is copied as a binary file. All the rest is copied as ASCII files. This includes pre and post install scripts, RSC files and further scripts.


      In case you need to copy more binary files, for some reasons, this is not possible by default.


      For instance, you may need to install something through the pre or post install script, and this may happen to be a binary file.


      == The makeself tool

      "makeself.sh is a small shell script that generates a self-extractable tar.gz archive from a directory. The resulting file appears as a shell script (many of those have a .run suffix), and can be launched as is. The archive will then uncompress itself to a temporary directory and an optional arbitrary command will be executed (for example an installation script). This is pretty similar to archives generated with WinZip Self-Extractor in the Windows world. Makeself archives also include checksums for integrity self-validation (CRC and/or MD5 checksums)." (http://megastep.org/makeself/)


      == How to use makeself with Bulk Installer ==

      What we have done is creating a binary file with makeself which will contain all the files (binary and ASCII files) we need for the installation.

      When run on the target server, the makeself archive will extract itself and run the specified command.


      The only drawback is that the Bulk Installer append flags to the agent packages execution command (-default ./nsh-install-defaults chmod755package.sh%3Bshpackage.sh-default.%2Fnsh-install-defaults%3C%2Fdev%2Fnull


      ==== Run the job

      Open the Bulk Installer, load the xml file and kick off the job