Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
Supporting
BMC Server Automation version 8.2.00
February 2012
www.bmc.com
Copyright 2012 BladeLogic, Inc. BMC, BMC Software, and the BMC Software logo are the exclusive properties of BMC Software, Inc., are registered with the U.S. Patent and Trademark Office, and may be registered or pending registration in other countries. All other BMC trademarks, service marks, and logos may be registered or pending registration in the U.S. or in other countries. All other trademarks or registered trademarks are the property of their respective owners. BladeLogic and the BladeLogic logo are the exclusive properties of BladeLogic, Inc. The BladeLogic trademark is registered with the U.S. Patent and Trademark Office, and may be registered or pending registration in other countries. All other BladeLogic trademarks, service marks, and logos may be registered or pending registration in the U.S. or in other countries. All other trademarks or registered trademarks are the property of their respective owners. IBM and AIX are trademarks or registered trademarks of International Business Machines Corporation in the United States, other countries, or both. Linux is the registered trademark of Linus Torvalds. Oracle and Java are registered trademarks of Oracle and/or its affiliates. Other names may be trademarks of their respective owners. UNIX is the registered trademark of The Open Group in the US and other countries. The information included in this documentation is the proprietary and confidential information of BMC Software, Inc., its affiliates, or licensors. Your use of this information is subject to the terms and conditions of the applicable End User License agreement for the product and to the proprietary and restricted rights notices included in the product documentation.
Customer support
You can obtain technical support by using the BMC Support Central website or by contacting Customer Support by telephone or e-mail. To expedite your inquiry, see Before contacting BMC.
Support website
You can obtain technical support from BMC 24 hours a day, 7 days a week at http://www.bmc.com/support. From this website, you can
read overviews about support services and programs that BMC offers find the most current information about BMC products search a database for issues similar to yours and possible solutions order or download product documentation download products and maintenance report an issue or ask a question subscribe to receive proactive e-mail alerts when new product notices are released find worldwide BMC support center locations and contact information, including e-mail addresses, fax numbers, and telephone numbers
product information product name product version (release number) license number and password (trial or permanent)
operating system and environment information machine type operating system type, version, and service pack or other maintenance level such as PUT or PTF system hardware configuration serial numbers related software (database, application, and communication) including type, version, and service pack or maintenance level
sequence of events leading to the issue commands and options that you used messages received (and the time and date that you received them) product error messages messages from the operating system, such as file system full messages from related software
Send an e-mail message to customer_support@bmc.com. Use the Customer Support website at http://www.bmc.com/support.
Introduction
The Network Shell (NSH) commands are file manipulation utilities designed to look and feel like their UNIX counterparts. The difference is that the NSH commands are able to access and manipulate both local and remote files without using NFS/RFS or the .rhost remote authentication mechanisms. Using the NSH commands, you can manage your network of UNIX and Windows machines as one large host. You can perform system administrative functions on multiple remote hosts from a single machine. Instead of having to rlogin or telnet to a host to see what is going is on, or to make a quick change, you can just use the NSH commands to access files on local and remote hosts directly from the command line. You can use the NSH commands to write new scripts, or modify existing scripts and make them distributed. The BMC Server Automation Network Shell Command Reference Manual provides both summarized and complete descriptions of all commands and utilities available in Network Shell. Use this document as follows:
To view summarized descriptions of commands and utilities, see the alphabetized table in Summarized descriptions of commands on page 8. To view complete descriptions of commands and utilities, see Complete descriptions of commands on page 12.
Introduction
ZSH support
When using the console, open the login dialog as you normally would. Select Options, which displays additional authentication choices. Then select Save Credential for this session. After you select Connect to authenticate, a session credential is cached, even if you exit the console. For more information about using blcred to obtain a session credential, refer to the blcred man page. Alternatively, BMC technical documentation shows some typical scenarios for using blcred at https://docs.bmc.com/docs/display/bsa82/Administering+security. If you are running Network Shell in batch mode, you must use blcred to obtain a session credential. If you are using Network Shell to connect directly to servers without routing traffic through a Network Shell Proxy Server, no authentication is required.
ZSH support
Network Shell supports both 4_0_4 and 4_3_4 versions of ZSH. By default, Network Shell calls the 4_3_4 version of ZSH. If you want to access the older version of ZSH, do the following:
NOTE
HP-UX platforms do not support ZSH 4.3.4. The default ZSH version on HP-UX remains 4.0.4. The following functionality described in the NSH man page only applies to the default zsh 4.3.4 (zsh-4_3_4) based Network Shell executable. When using the older zsh 4.0.4 (zsh) based Network Shell executable, the following behavior will not be present.
The ability to use fully qualified paths to specify execution of native commands when those commands have Network Shell equivalents. The implicit nexec of a native command on a remote host.
1 Cd to <BladeLogic install directory>\bin. By default, this is C:\Program Files\BMC Software\BladeLogic\NSH\bin on Windows and /opt/bmc/bladelogic/NSH/bin on UNIX. 2 Do one of the following:
On Windows, do the following: A. Rename the existing "nsh.exe" executable to "nsh-4_3_4.exe". B. Copy the "zsh.exe" executable to "nsh.exe".
Internationalization support
Most of the Network Shell commands support multibyte characters for internationalization (I18N). For a list of NSH commands that support multibyte characters, see Summarized descriptions of commands on page 8 (as indicated in the I18N Support column).
NOTE
The applicability of these environment variables to the Network Shell and the RSCD Agent depends on the operating system where they are installed:
The Network Shell uses these variables, whether hosted on a UNIX operating system or a Windows operating system. The RSCD Agent uses these variables only if installed on a UNIX operating system. On Windows, the RSCD Agent uses the operating systems language settings.
Introduction
Description Controls the functions of an RSCD agent. Provides information about an RSCD agent. Scans files for specified patterns. Creates an X.509 certificate.
bzip2
yes
cat chapw chgrp chmod chown chrole cksum cmp colrm comm compress cp csv2xml cut
yes NA yes yes yes NA yes yes yes yes yes yes yes yes
Network Shell Command daalinfo dd diff df df2 dsync du echo expand fields file find fold fqdn funzip grep head hexdump hgrep hostname join lam less lesskey link ln ls man md5sum mkdir mkfifo mknod mv ncp ncpu ndf ndircmp
Description Displays an overview of the local DAAL registry. Converts and copies a file. Compares the differences between files and directories. Executes a remote df command. Reports file system disk usage. Synchronizes two directories. Displays disk usage information for files. Echoes arguments. Expands tabs to spaces. Extracts specified fields from a data row. Determines file type. Walks a file hierarchy. Filters the contents of files to limit line length. Prints fully qualified domain name of the current or specified host. Extracts files from a ZIP archive in a pipe. Searches files and selects lines matching specified patterns. Displays the first few lines of a file. Performs an ASCII, decimal, hexadecimal, or octal dump. Highlights the results of a grep. Prints the name of the current host. Provides a relational database operator. Outputs files side by side. Displays files on a CRT. Specifies key bindings that are used by the less command. Creates a link to a file. Creates a link to a file. Lists the contents of a directory. Get man pages from a remote host. Calculate the MD5 checksum of files. Create directories. Creates a named pipe. Creates a special file. Moves or renames files. Copies/synchronizes multiple sources to multiple destinations. Displays CPU information. View usage statistics from one or more hosts. Compares contents of multiple directories.
I18N Support NA yes yes yes yes yes yes yes yes NA yes yes yes NA yes yes yes yes yes yes yes yes yes NA yes yes yes NA yes yes yes yes yes yes NA NA yes Introduction 9
Network Shell Command ndsync nexec nlogin nmem nnet nohup nover nprocsum nps nsh NSH-Perl nshopt nshpath nstats ntop nukecert nunzip order paste pax pkgadd pr prune putcert redi renice rm rmdir rscd rsu runcmd runscript
Description Copies/synchronizes multiple sources to multiple destinations. Provides an interface for running remote commands. Log in to a remote host. View memory and swap statistics from one or more hosts. Displays network adaptor configuration data for one or more servers. Invokes a command immune to hangups. Displays a system overview in a standardized format independent of the servers operating system. Displays process summary from one or more hosts. Displays process information from one or more hosts. Outlines the differences between Network Shell and other shells. Describes the use of the Network Shell Perl module. Tests different network write buffer sizes. Shows the path where an nsh executable resides. Displays a system overview in a standardized format independent of the servers operating system. Provides a collection of commands used to view information and statistics for one or more servers. Removes certificates from servers. Decompresses or compresses files. Sorts a list of strings (or lines) in a specified order. Merges corresponding or subsequent lines of files. Reads and writes file archives and copies directory hierarchies. Provides a Network Shell wrapper to the pkgadd command. Print files. Prunes log files to a specified size. Pushes a certificate generated by bl_gen_ssl to one or more servers. Redirects input to a file. Alters the priority of running processes. Removes a file. Removes an empty directory. Describes the Remote System Call Daemon (the RSCD agent). Runs an NSH command with alternate privileges. Runs a Network Shell command on one or more hosts. Runs a Network Shell script on one or more hosts.
I18N Support yes yes NA NA NA yes NA NA NA yes NA NA yes NA NA NA yes yes yes yes NA yes yes NA yes NA yes yes yes yes yes yes
10
Network Shell Command scriptutil sdiff secadmin sed sort split strings su tail tar tee test touch tr uname uncompress uncp unexpand uniq unlink unzip unzipsfx uuencode uudecode version vi vsh vshview vtree wc zcat zip zipcloak zipgrep
Description Copies and executes scripts on remote servers. Compares the differences between files and directories sideby-side. Defines encryption security when modifying the secure file. Provides a stream editor. Sorts or merges text files. Splits a file into pieces. Finds printable strings in a file. Substitutes a user identity. Outputs the last part of files. Reads and writes file archives and copies directory hierarchies. Copies standard input to standard output, making copies of the input. Tests the value of an expression. Changes the last update and modification times of a file. Translates or deletes characters. Prints the operating system name. Expands compressed data. Uncopies files that were backed up during a cp or dsync. Replaces spaces with tabs (see also expand). Reports or filters out repeated lines in a file. Unlinks a file and/or directory. Lists, tests, and extracts compressed files in a ZIP archive. Provides a self-extracting stub for prepending to ZIP archives. Encodes a binary file. Decodes a binary file. Tells what version of BMC Server Automation software is installed on a server. Provides a text editor. Starts a shell and captures input and output. Views the log files created by vsh. Shows the directory structure of a file system. Counts the number of lines, words, and/or characters in a file. Expands compressed data. (zcat is an alias for uncompress.) Packages and compresses (archives) files. Packages and compresses (archives) files. Searches files in an archive for lines matching a pattern.
I18N Support yes yes NA yes yes yes yes NA yes yes yes yes yes yes NA yes yes yes yes yes yes yes yes yes NA no NA NA yes yes yes yes yes yes
Introduction
11
Description Lists detailed information about an archive. Packages and compresses (archives) files. Packages and compresses (archives) files. Provides man pages for Network Shells preferred command interpreter, the Z shell.
I18N Support yes yes yes Zsh 4.0.4: no Zsh 4.3.4: yes
12