Installing Inventory templates and other scripts
BMC Server Automation provides templates for Inventory report data collection, and scripts for agent log data collection and running the ETL and archival processes. To use these templates and scripts, you must obtain them from the BDSSAInstallationDirectory/bsa/content_installer directory and create BMC Server Automation jobs. This topic describes how to download and install the templates and scripts.
The templates and scripts are included in the content_installer.zip file. The file also includes the Content Installer, which you need to run to install the templates and scripts.
The content_installer.zip file includes the Content Installer and the following artifacts:
- Templates for Inventory reports — Use BMC Server Automation to create Discovery and Snapshot Jobs to collect data by using Inventory templates. Run the jobs on a regular basis to collect the inventory data. For information about using Inventory templates, see Configuring Inventory reporting.
- collect_agent_logs.nsh — The script for creating agent log collection jobs. For more information, see Setting up data collection scripts for Command Usage reports.
- run_etl_from_om.nsh — The script for creating a Network Shell (NSH) Script Job to run the ETL process. For more information, see Running ETL using BMC Server Automation jobs.
- run_archival_from_om.nsh — The script for creating an NSH Script Job to run the archival process. For more information, see Archiving data by using BMC Server Automation jobs.
Before you begin
- Access the content_installer.zip file from the BDSSAInstallationDirectory/bsa/content_installer directory.
Verify that your BMC Server Automation Application Server environment meets the following prerequisites (for information about setting up the BMC Server Automation Application Server, see Installing components on Microsoft Windows and Installing components on Linux and UNIX in the BMC Server Automation documentation).
Network Shell is installed on the BMC Server Automation Application Server.
agentinfocommand works and displays the correct information when it is run on the BMC Server Automation Application Server.
To verify that the command works, start nsh and run the command as follows:
<hostName>is the Application Server name.
The command should return a message similar to the following example:
localhost: Agent Release: :126.96.36.199 Hostname: :vm-w23-rds896 Operating System:WindowsNT 5.2 User Permissions:BladeLogicRSCD@VM-W23-RDS896->Administrator@VM-23-RDS896:PrivilegeMapped(Identity via trust) Security :Protocol=5, Encryption=TLS1 Host ID :24612116 # of Processors: 1 License Status :Licensed for NSH/CM
To run the Content Installer
- Locate the content_installer.zip file in the BDSSAInstallationDirectory/bsa/content_installer directory.
Extract the zip file into a folder of your choice that is near to the root folder on your BMC Server Automation Application Server.
BMC recommends that you extract the zip file into a folder that is near to the root folder. Otherwise, the Content Installer files might not work. For example, you could extract the zip file into the /tmp directory on Linux and the c:\tmp directory on Windows.
- On the BMC Server Automation Application Server, from a command prompt, navigate to the directory in which you extracted the files in the previous step.
blcredutility to acquire credentials, as follows:
blcred cred -acquire
For more information about how to acquire credentials by using the
blcredutility, see Using the blcred utility in the BMC Server Automation documentation.
- Enter the following parameters for the utility:
- Profile Name: Name of the profile created on BMC Server Automation
- User Name: BMC Server Automation user
- Password: Password for the BMC Server Automation user
Execute the following scripts in any order:
nsh load-bsara-nsh-script.nsh -v <authenticationProfileName>
nsh load-bl-inventory-templates.nsh -v <authenticationProfileName>
<authenticationProfileName>is the authentication profile name for the local or remote application server. Use this parameter if you do not want to use the default profile or there is no default profile.
The first script provides the following options:
- Load BDSSA Collect Agent Logs Scripts: Imports the collect_agent_logs.nsh script. Use this option if you want to create agent log collection jobs.
- Load BDSSA ETL and Archival Scripts: Imports the run_etl_from_om.nsh and run_archival_from_om scripts. Use this option if you want to create BMC Server Automation Server Network Shell Script Jobs to run the ETL and archival processes.
- Load All: Loads the collect_agent_logs.nsh, run_etl_from_om.nsh, and run_archival_from_om scripts. BMC recommends that you use this option.
- Exit: Stops the execution of the load-bsara-nsh script.
The second script provides options to import the Inventory templates for your operating system type. Use this option to load the Inventory templates for your operating system type. These templates are required for Inventory reporting.
When you run these scripts, a log file, called content-install.log, is created in the contents_installer directory.
To locate the scripts
Log on to BMC Server Automation to locate the templates and scripts:
|Template/Script||Location on the BMC Server Automation Console|
|Inventory templates||BladeLogic\Component Templates\BladeLogic Inventory Templates|
Collect Agent Logs Script
(For the collect_agent_logs.nsh script)
|BladeLogic\Depot\BladeLogic Reports Scripts\Collect Agent Logs|
Run ETL From OM Script
(For the run_etl_from_om.nsh script)
|BladeLogic\Depot\BladeLogic Reports Scripts\Run ETL from OM|
Run BDSSA Archival Script
(For the run_archival_from_om.nsh script)
|BladeLogic\Depot\BladeLogic Reports Scripts\Run BDSSA Archival|