Non Interactive Operating System Installation

This chapter contains the following sections:

Non Interactive Operating System Installation

Non Interactive Server Configuration Utility (NI-SCU) helps deploy operating systems without user intervention.

To install operating systems using NI-SCU, do the following:

  • Modify the nwboot.cfg file to include information such as the target server, the SCU ISO file location, and the log collection details.

  • Modify the niscu.cfg configuration file to include information such as the target server, the SCU ISO file location, and the log collection details.

  • See Modifying the niscu.cfg File.

  • See Modifying conf_file.

  • Prepare the answer file for kickstart installation.

    For sample answer files, see the Custom OS Installation Examples chapter.

  • Run the os_install-4.2.yc.yyyymmddab.py script to begin the installation.

    See Running the Python Script to Start OS Deployment.

Support for Network Boot from PXE, iPXE, HTTP and HTTPS

Beginning with Release 6.3, you can perform SCU Network boot from the following network options with IPv4 and IPv6.

  • PXE

  • iPXE

  • HTTP

  • HTTPS

The above network boot options are available in addition to the existing boot medium options like CIMC vMedia.

You can perform the SCU ISO boot from the above network options using the NISCU-XML API and NISCU-Redfish interfaces on Cisco UCS M5, M6 and M7 servers.

Beginning with Release 6.3, for non interactive operating system installation using HTTP/HTTPS, PXE and IPXE, you must first configure the nwboot.cfg file.

Modifying the nwboot.cfg File

Beginning with Release 6.3, for non interactive operating system installation using HTTP/HTTPS, PXE and IPXE, you must first configure the nwboot.cfg file.

The nwboot.cfg file consists of the following sections:

Default

The Default section consists of the following parameter:

Table 1. Parameters in the Default Section
Parameter Description

Update_Timeout

The time (in minutes) the python script is active after it has been started. The default value is 240 minutes. The valid range is 30 to 240 minutes.

Example

[defaults]
update_timeout=240

SCU Repository

The SCU Repository section consists of the following parameters:

Table 2. Parameters in the SCU Repository Section
Parameter Description

BootMedium

The boot medium to install SCU boot.

The following types are supported:

  • vMedia

  • HTTP

  • FlexMMC

  • MicroSD

  • PXE

  • IPXE


Note


See the below sections for the details of the fields available for the respective boot medium under SCU Repository.


Table 3. HTTP Boot Medium

Parameter

Description

ImageRepository

Path where SCU ISO resides in the HTTP share

MACAddress

The MAC address assigned to the active network interface to SCU

PCIeSlot

The name of the PCIe slot in which the controller is located.

PhysicalPortNumber

Physical Port Number

IPv4Address

and IPv6Address

IP address for IPv4 and IPv6

These are the following parameters for IPv4:

  • AddressOrigin

  • Address - Host IP Address for the network interface

  • Gateway - IPv4 Gateway Address

  • Subnetmask - IPv4 Subnet Address

  • Static Name Server

These are the following parameters for IPv6:

  • AddressOrigin

  • Address - Host IP Address for the network interface

  • Gateway - IPv6 Gateway Address

  • Subnetmask - IPv6 Subnet Address

  • Static Name Server

Table 4. vMedia Boot Medium

Parameter

Description

ImageRepository

Path where SCU ISO resides in the HTTP share

TransferProtocol

The transfer protocol type.

Username

User credentials

Password

MountOptions

Mounting options

Table 5. PXE Boot Medium

Parameter

Description

ImageRepository

Path where SCU ISO resides in the HTTP share

MACAddress

The MAC address assigned to the active network interface to SCU

PCIeSlot

The name of the PCIe slot in which the controller is located.

PhysicalPortNumber

Physical port number

AddressOrigin

Server IP address from which IPv4 or IPv6 origins

The value is DHCP.

Table 6. iPXE Boot Medium

Parameter

Description

ImageRepository

Server IP address from which IPv4 or IPv6 origins

The value is DHCP.

MACAddress

The MAC address assigned to the active network interface to SCU

PCIeSlot

The name of the PCIe slot in which the controller is located.

PhysicalPortNumber

Physical port number

Example

"BootMedium": {
            "VMEDIA": {
                "ImageRepository": "10.10.10.1/home/nfsshare/iso/scu.iso",
                "TransferProtocol": "nfs",
                "Username": "root",
                "Password": "password",
                "MountOptions": ""
            },
            "HTTP": {
                "ImageRepository": "http://10.10.10.1:80/iso/scu.iso",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1,
                "IPv4Address": {
                    "AddressOrigin": "Static",
                    "Address": "10.104.255.179",
                    "Gateway": "10.104.255.129",
                    "SubnetMask": "255.255.255.128",
                    "StaticNameServer": "64.104.76.247"
                },
                "IPv6Address": {
                    "AddressOrigin": "DHCPv6",
                    "Address": "fc00:1234::a:b:c:d",
                    "PrefixLength": 64,
                    "Gateway": "fe80::fe15:b4ff:fe97:90cd",
                    "StaticNameServer": "fe80::fe15:b4ff:fe97:90cd"
                }
            },
            "FLEXMMC": {
                "ImageRepository": "scu.iso"
            },
            "MICROSD": {},
            "PXE": {
                "ImageRepository": "ftp://10.104.255.224/pub/scu",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1,
                "IPv4Address": {
                    "AddressOrigin": "DHCP"
                }
            },
            "IPXE": {
                "ImageRepository": "http://10.10.10.1/iso/scu.iso",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1
            }
        }

OS Details

In the OS Details section, provide the OS Repository and Target OS details of the share where the SCU ISO image is located.

The OS Details section consists of the following parameters for OS Repository, vMedia boot medium and Target OS:

Table 7. OS Repository

Parameter

Description

MediaType

Type of media.

BootMedium

The boot medium to install SCU boot.

The following types are supported:

  • vMedia

  • HTTP

  • FlexMMC

  • MicroSD

  • PXE

  • IPXE

Table 8. vMedia Boot Medium

Parameter

Description

ImageRepository

SCU ISO boot image repository location

Transfer Protocol

The transfer protocol type.

Username

User credentials

Password

Mount Options

Mounting options

Example

"OSDetails": {
        "OSRepository": {
            "MediaType": "Local",
            "BootMedium": {
                "VMEDIA": {
                    "ImageRepository": "10.10.10.1/home/nfsshare/iso/rhel/RHEL-8.5.0-20211013.2-x86_64-dvd1.iso",
                    "TransferProtocol": "nfs",
                    "Username": "root",
                    "Password": "password",
                    "MountOptions": ""
                }
            }
        },
        "TargetOS": {
            "OSName": "rhel8u5x64",
            "OSEdition": "None"
        }

Target Disk

In the Target Disk section, provide the type of disk details.

The Target Disk section consists of the following parameters:

Table 9. Target Disk

Parameter

Description

PHYSICALDISK

Enter the Drive Serial Number.

VIRTUALDISK

Enter the following details:

  • Storage Controller Slot ID

  • Virtual Drive Number

DISKNAME

Enter the OS Drive details.

VIRTUALDRIVENAME

Enter the virtual drive name.

ONBOARDSATAM2SSD

Enter the slot details for SATAM2SSD.

M2SWVDNAME

Enter the details for M2 SW RAID Name.

FC

Enter the following details:

  • HostWWPN

  • TargetWWPN

  • LUN

iSCSI

Enter the following details:

  • MACAddress

  • Primary Target Name

  • Primary LUN

Example

"TargetDisk": {
        "PHYSICALDISK": {
            "DriveSerialNumber": "06VSGVVB"
        },
        "VIRTUALDISK": {
            "StorageControllerSlotID": "MRAID",
            "VirtualDriveNumber": 0
        },
        "DISKNAME": {
            "OSDrive": "/dev/sdk"
        },
        "VIRTUALDRIVENAME": {
            "VirtualDriveName": "Hypervisor"
        },
        "ONBOARDSATAM2SSD": {
            "SATAM2SSD": "slot1"
        },
        "M2SWVDNAME": {
            "M2SWRAIDName": "RAID0"
        },
        "FC": {
            "HostWWPN": "10:00:54:88:DE:A7:32:6F",
            "TargetWWPN": "50:06:01:68:3E:A0:62:22",
            "Lun": 200
        },
        "ISCSI": {
            "MACAddress": "70:DF:2F:86:AE:FD",
            "PrimaryTargetName": "iqn.2001-05.com.equallogic:0-af1ff6-082b3ebe6-cf2005780845d665-iqn.siva-25.com",
            "PrimaryLUN": 1
        }

Remote Log

In the Remote Log section, provide the IP address and access details of the share where the installation logs will be saved.

The Remote Log section consists of the following parameters:

Table 10. Parameters in the Remote Log Section
Parameter Description

ImageRepository

The IP address of the share where the log file is generated during the installation.

TransferProtocol

The protocol type used to access the share. The following protocols are supported:

  • SCP

  • SFTP

Username

Password

The user credentials to access the share.

Example

"RemoteLog": {
        "ImageRepository": "10.10.10.10/home/nfstest/scu.log",
        "TransferProtocol": "scp",
        "Username": "root",
        "Password": "John123"

Answer File

In the Answer File section, provide access details of the share where the answer file is located. The answer file contains details about OS deployment.

Example

"AnswerFile": {
        "ImageRepository": "10.10.10.10/home/nfstest/answerfile",
        "TransferProtocol": "scp",
        "Username": "root",
        "Password": "John123"

Modifying the niscu.cfg File

Beginning with Release 6.3, for non interactive operating system installation using HTTP/HTTPS, PXE and IPXE, you must first configure the nwboot.cfg file.

For non interactive operating system installation using vMedia, you must first configure the niscu.cfg file.


Note


You do not have to configure nwboot.cfg file while installing non interactive operating system using vMedia.


The niscu.cfg file consists of the following sections:

Each section must have an unique name. The section name is provided by the user.

Default

The Default section consists of the following parameters:

Table 11. Parameters in the Default Section
Parameter Description

[section_name]

Enter a name for the section.

use_http_secure=

The HTTP type.

The default value is 'Yes'. Type 'No' if the connection is insecure.

update_timeout=

The time (in minutes) the python script is active after it has been started. The default value is 120 minutes. The valid range is 30 to 240 minutes.

Example

[defaults]
use_http_secure=yes
update_timeout=120

SCU

In the SCU section, provide the IP address and access details of the share where the SCU ISO image is located.

The SCU section consists of the following parameters:

Table 12. Parameters in the SCU Section
Parameter Description

[section_name]

Enter a name for the section.

isoshareip=

The IP address of the SCU ISO share.

isosharepath=

The location of the ISO image in the share.

imagefile=

The name of the SCU ISO image.

isosharetype=

The share type. The following share types are supported:

  • NFS

  • CIFS

  • WWW (HTTP or HTTPS)

isoshareuser=

The user credentials to access the share.

isosharepassword=

bootmedium=

The medium to be used to boot from. The following types are supported:

  • vmedia - To boot from vmedia

  • flexmmc- To boot from eMMC

  • microsd - To boot from microsd

nios_section=

The nios_install section containing the OS installation process.

Example

[scu_iso]
isoshareip=192.0.2.10
isosharepath=/cifsshare
imagefile=ucs-cxxx-scu-5.0.0.39.iso
isosharetype=cifs
isoshareuser=Administrator
isosharepassword=John123
bootmedium=vmedia

NIOS Install

The NIOS Install section initiates the OS installation process and consists of the following parameters.

Table 13. Parameters in the NIOS Install Section
Parameter Description

remoteShareIp=

IP Address of the scuConfigFile remote share

remoteSharePath=

scuConfigFile remote share path.

remoteShareFile=

scuConfigFile in the remote share

remoteShareType=

Remote share protocol. The following are supported:

  • SCP

  • SFTP

  • TFTP

  • WWW (HTTP or HTTPS)

username=

The user credentials to access the remote share.

password=

scubootmedium=

The medium to be used to SCU boot from. The following types are supported:

  • HTTP - To boot from HTTP or HTTPS

  • PXE - To boot from PXE

  • IPXE - To boot from IPXE

  • vmedia - To boot from vmedia

  • flexmmc- To boot from eMMC

  • microsd - To boot from microsd

osBootMedium=

The medium to be used to boot SCU ISO from.

vmedia is the supported medium.

targetDiskType=

The type of target disk. The following types are supported:

  • physicaldisk

  • virtualdisk

  • microsd

Example

[nios_install]
niosremoteshareip=10.10.10.10
niosremotesharepath=/home/nfstest/xyz/config/
niosremotesharefile=scuConfigFile_VMEDIA_VMEDIA_RHEL8_4
niosremotesharetype=scp
niosusername=root
niospassword=Jack123
niosscubootmedium=vmedia
niososbootmedium=vmedia
niostargetdisktype=physicaldisk

Log Collection

In the Log Collection section, provide the IP address and access details of the share where the installation logs will be saved.

The Log Collection section consists of the following parameters:

Table 14. Parameters in the Log Collection Section
Parameter Description

[section_name]

Enter a name for the section.

remshareip=

The IP address of the share where the log file is generated during the installation.

remsharepath=

The location of the log file in the share. The log data generated during the installation is saved in this file.

Enter the absolute path of the share.

remsharefile=

The file name to store SCU NI-OSI logs on the remote server.

The default value is share_file.

remsharetype=

The protocol type used to access the share. The following protocols are supported:

  • SCP

  • SFTP

remshareuser=

remsharepassword=

The user credentials to access the share.

Example

[log_info]
remshareip=192.0.2.100
remsharepath=PATH
remsharefile=share_file
remsharetype=scp
remshareuser=user
remsharepassword=xxxx

OS

In the OS section, provide access details of the share where the config file is located. The config file contains the operating system details that are used in niscu.cfg. The OS section is for a single operating system only. If you want to install a different OS, repeat this section with the corresponding config file. See Modifying conf_file for information about config_file.

The OS section consists of the following parameters:

Table 15. Parameters in the OS Section
Parameter Description

[section_name]

Enter a name for the section.

The name provided here should be used as the value for the config_section parameter in the Target Server section.

ip=

The IP address of the share where the config file is located.

path=

The location of the config file in the share.

file=

The config file that contains the operating system details.

username=

The user credentials to access the share.

password=

protocol=

The protocol used to access the share.

The following protocols are supported:

  • SCP

  • SFTP

  • HTTP

  • TFTP

Example

[OS_iso]
ip=192.0.2.200
path=/var/www/html/huu
file=conf_file
username=root
password=Huudefault369
protocol=scp

Answer File

In the Answer File section, provide access details of the share where the answer file is located. The answer file contains details about custom OS deployment. This section is optional if you want to install an operating system with default settings (Quick installation).

Table 16. Parameters in the Answer File Section
Parameter Description

[section_name]

Enter a name for the section.

The name defined here should be used as the value in the "answerfile_section" parameter in the target server section.

ip=

The IP address of the share that contains the answer file.

path=

The location of the answer file in the share.

file=

The kickstart file. For custom installation, the kickstart file contains the required installation details.

username=

The user credentials to access the share.

password=

protocol=

The protocol type used to mount the share.

The following protocols are supported:

  • SCP

  • SFTP

  • HTTP

  • TFTP

Example

[OS_answerfile]
ip=192.0.2.254
path=/home/SCU/NI_SCU/Files/
file=esxi_ks.cfg
username=root
password=root@123
protocol=scp

Target System

In this section, provide details about the target server where the operating system is being installed. This section also contains details about the config file and answer file that are passed to the niscu.cfg file. For deploying operating systems in multiple servers, repeat this section with the details of target server, config file, and answer file.

Table 17. Parameters in the Target System Section
Parameter Description

[section_name]

When naming this section, use this format: cimc, followed by an underscore (_), and a number. The number defines the target server instance.

address=

The IP address of the target server where the OS is being installed.

user=

The user credentials to access the target server.

password=

imagefile=

The SCU image file name.

config_section=

The name given for the OS section should be provided here. For example, if the OS section name is "rhel_iso", then provide that name here.

servernode=

Select the node where you want to install the OS. This option is applicable for only C3260 and S3260 M4 servers.

Enter 1 to select node 1. Enter 2 to select node 2. Enter 'all' to select both the nodes.

[answerfile]

The name given for the Answer File section should be provided here. For example, if the Answer File section is "OS_answerfile", then provide that name here.

This is an optional parameter. The Answer file section is required only for custom installation.

Example


[cimc_1]
address=192.0.2.10
user=admin
password=Cisucs891
imagefile=ucs-cxxx-scu-5.0.0.39.iso
config_section=OS_iso
servernode=1
answerfile_section=OS_answerfile

[cimc_2]
address=192.0.2.20
user=admin
password=Ciscoucs345
imagefile=ucs-cxxx-scu-5.0.0.39.iso
config_section=OS_iso
servernode=2
answerfile_section=OS_answerfile

Modifying conf_file

The conf_file contains details about the operating system being deployed on the target server. The conf_file includes the following parameters:

Table 18. Parameters in conf_file
Parameter Description

shareMapType:

The share type. The following share types are supported:

  • NFS

  • CIFS

  • WWW (HTTP and HTTPS)

shareIP:

The IP address of the share where the OS ISO file is saved.

sharePath:

The location of the OS ISO file.

sharefile:

The name of the OS ISO file.

username:

The user credentials to access the share.

Enter the user name and password.

password:

osName:

The operating system format.

See Modifying conf_file for the operating system formats.

osDrive:

The drive where the operating system is installed.

For example, sdd and sde might represent the first and second VDs.

However, the enumeration of disks depends on the number of JBODs and VDs configured. Suppose a single JBOD has been configured. Then the JBOD is enumerated first and sde and sdf represent the first and second VDs.

  • DriveSerialNumber: Z1W4PB480000R610JQWP #Serial Number of the drive connected to LSI/Noe-Valley RAID controller or NVMe disk, on which OS has to be installed.

  • StorageControllerSlotID: MRAID #Controller Slot ID. This will be ignored, if DriveSerialNumber is present.

    VirtualDriveNumber: 0 #VD Number of the drive on which OS has to be installed.

    For LSI/Noe-Valley RAID controllers, VirtualDriveNumber should be specified along with StorageControllerSlotID.

  • VirtualDriveName: Hypervisor #VD Name on which OS has to be installed. Applicable only for SD Card Drives.

Note

 

The above options are exclusive. You can provide any one of the above.

Edition:

Windows parameter only. This parameter is applicable for both custom and quick installation of Windows.

The following editions are supported:

  • STANDARD

  • DATACENTER

  • STANDARDCORE

  • DATACENTERCORE

Example


shareMapType:www
shareIp:192.0.2.100
sharePath:/huu
shareFile:VMware-VMvisor-Installer-5-5-0_update03-3116895_x86_64.iso
userName:root
password:HuuWelcome123
osName:esxi5u5x64
osDrive:/dev/sde
Edition:STANDARD
MediaType:Local
Interface:eth0
BootProto:static
IP:192.0.2.254
Subnet:255.255.255.0
Gateway:192.0.2.100
DNS:192.0.2.100
 

The following table lists a few examples of operating system formats.

Table 19. Operating System Formats
Operating System Version Format

Rocky Linux

Rocky Linux 8 Update 6

Rocky Linux 8 Update 7

Rocky Linux 9 Update 1

rocky8u6x64

rocky8u7x64

rocky9u1x64

Oracle Linux

Oracle Linux 7 Update 9

Oracle Linux 8 Update 6

Oracle Linux 9

oracle7u9x64

oracle8u6x64

oracle9u0x64

RHEL

RHEL 8.0

RHEL 8.4

rhel8ux64

rhel8u4x64

SLES

SLES 15 SP3

SLES 15.0

sles15sp3x64

sles15x64

Ubuntu

Ubuntu 20.4.2

ubuntu20042x64

Esxi

Esxi 7.0U3

Esxi 6.7.3

esxi7u03x64

esxi6u73x64

Windows

Windows Server 2019 and 2022

w2k19x64

w2k22x64

Running the Python Script to Start OS Deployment

Procedure

  Command or Action Purpose

Step 1

Install the following components on the Linux client system from where you want to run the Python script:

  • Python 2.7.x for 4.1.1 and below

  • Python 3.x for 4.2.1 and above

  • Open SSL Version 1.0.1e-fips or later

Step 2

On the Linux client system, run the following command:

python os_install-4.2.yc.yyyymmddab.py -c niscu.cfg

Here, os_install-4.2.yc.yyyymmddab.py is the Python script, and niscu.cfg is the configuration file that contains information about the SCU ISO image and the OS details.

When the Python script is executed, the target server boots to the SCU ISO. After SCU boots, it mounts the OS ISO image that is mapped in the configuration file. SCU then installs the operating system on the target server.

Installing Operating Systems Using Commands

Use the following options to install an operating system on a single server:

Table 20. Options to Install OS on a Single Server
Option Description

-a a.b.c.d, --address=a.b.c.d

The IP address of the target server.

-u USERNAME, --user=USERNAME

The admin user credentials to access the target server.

-p PASSWORD, --password=PASSWORD

-m scu.iso, --imagefile=scu.iso

The name of the SCU ISO file.

-i a.b.c.d, --isoshareip=a.b.c.d

The IP address of the remote share where the SCU ISO image is located.

-d /data/image, --isosharepath=/data/image

The location of the ISO file in the share.

-t cifs/nfs/www, --isosharetype=cifs/nfs/www

The type of remote share.

The following share types are supported:

  • CIFS

  • NFS

  • WWW (HTTP or HTTPS)

-r ISOSHAREUSER, --isoshareuser=ISOSHAREUSER

The admin user credentials to access the share where the SCU ISO image is located.

-w ISOSHAREPASSWORD, --isosharepassword=ISOSHAREPASSWORD

-o BOOTMEDIUM, --bootMedium=BOOTMEDIUM

The boot medium used to update.

The following share types are supported:

  • vmedia

  • microsd

  • flexmmc

-q TIMEOUT, --timeout=TIMEOUT

NISCU OS Installation timeout

-M ISOMOUNTOPTION, --isomountoption=ISOMOUNTOPTION

Use mount option in case of CIFS share to specify the security option.

-I a.b.c.d, --remshareip=a.b.c.d

The IP address of the remote share where the snapshot results will be saved.

-D /data/image, --remsharepath=/data/image

The directory to store snapshot results in the share.

-F REMOTESHAREFILE, --remoteShareFile=REMOTESHAREFILE

The name of the share file.

-T scp/sftp, --remsharetype=scp/sftp

The type of share.

The following protocols are supported:

  • SCP

  • SFTP

-U REMSHAREUSER, --remshareuser=REMSHAREUSER

The user credentials to access the share to save snapshot results.

-W REMSHAREPASSWORD, --remsharepassword=REMSHAREPASSWORD

-x CONFIGSHAREIP, --configShareIp=CONFIGSHAREIP

The IP address of the remote share where the config file is located.

-y CONFIGSHAREPATH, --configSharePath=CONFIGSHAREPATH

The path to the location of the config file in the share.

-z CONFIGSHAREFILE, --configShareFile=CONFIGSHAREFILE

The name of the config file.

-j CONFIGSHARETYPE, --configShareType=CONFIGSHARETYPE

The type of share.

-b CONFIGSHAREUSERNAME, --configShareUsername=CONFIGSHAREUSERNAME

The user credentials to access the share where the config file is located.

-e CONFIGSHAREPASSWORD, --configSharePassword=CONFIGSHAREPASSWORD

-X ANSWERFILESHAREIP, --answerFileShareIp=ANSWERFILESHAREIP

The IP address of the share where the answer file is located.

-Y ANSWERFILESHAREPATH, --answerFileSharePath=ANSWERFILESHAREPATH

The path to the location of the answer file in the share.

-Z ANSWERFILESHAREFILE, --answerFileShareFile=ANSWERFILESHAREFILE

The name of the answer file.

-J ANSWERFILESHARETYPE, --answerFileShareType=ANSWERFILESHARETYPE

The type of share.

-B ANSWERFILEUSERNAME, --answerFileUsername=ANSWERFILEUSERNAME

The user credentials to access the share where the answer file is located.

-E ANSWERFILEPASSWORD, --answerFilePassword=ANSWERFILEPASSWORD

-N SERVERNODE, --serverNode=SERVERNODE

Select the node where you want to install the OS. This options is applicable for only C3260 and S3260 M4 servers.

Type 1 to select node 1. Type 2 to select node 2. Type ALL to select both the nodes.

-f LOGFILE, --logrecordfile=LOGFILE

The name of the log file that contains the log data.

Table 21. CLI Options for NIOS_Install Section

Option

Description

-A NIOSREMOTESHAREIP, --niosremoteshareip=NIOSREMOTESHAREIP

IP address of remote share for non-interactive OS install

-G NIOSREMOTESHAREPATH, --niosremotesharepath=NIOSREMOTESHAREPATH

Path in remote share for non-interactive OS install

-H NIOSREMOTESHAREFILE, --niosremotesharefile=NIOSREMOTESHAREFILE

Filename in remote share for non-interactive OS install

-K NIOSREMOTESHARETYPE, --niosremotesharetype=NIOSREMOTESHARETYPE

Remote share type for non-interactive OS install

-L NIOSUSERNAME, --niosusername=NIOSUSERNAME

Username of the Cisco IMC admin user

-O NIOSPASSWORD, --niospassword=NIOSPASSWORD

Password of the Cisco IMC admin user

-P NIOSSCUBOOTMEDIUM, --niosscubootmedium=NIOSSCUBOOTMEDIUM

Boot medium for non-interactive OS install

-Q NIOSOSBOOTMEDIUM, --niososbootmedium=NIOSOSBOOTMEDIUM

OS medium for non-interactive OS install

-R NIOSTARGETDISKTYPE, --niostargetdisktype=NIOSTARGETDISKTYPE

Target Disk type for non-interactive OS install

Example

Example 1: Options for Quick Installation

In this example, the command options help in quick installation of Windows on 198.51.100.10. The SCU ISO image is located in 198.51.100.100. The conf_file is placed in 198.51.100.100. The OS installation log files are saved in 198.51.100.254. The NI-SCU script log files are saved in the same client system where the script is executed.

python3 os_install.py -a 198.51.100.10 -u user1 -p passwd
-m ucs-cxxx-scu-6.2.xx.iso -o vmedia -i 198.51.100.100
-d /utils_share/scu/kb -t nfs -r user2 -w passwd1 -I 198.51.100.100
-D /niscu/new_TH2U
-F niscu_cli_remsharefile1 -T scp -U user3 -W passwd2 -x 198.51.100.254
-y /niscu/new_TH2U
-z conf_file -j sftp -b abcd -e passwd -f log_latest

Example 2: Options for Custom Installation

In this example, the command options help in custom installation of Windows on 198.51.100.10. The SCU ISO image is located in 198.51.100.100. The conf_file is placed in 198.51.100.100. The answer file required for custom installation is located in 198.51.100.110, and is named win_answer_file. The OS Installation log files are saved in 198.51.100.254. The NI-SCU script log files are saved in the same client system where the script is executed.

python3 os_install.py -a 198.51.100.10 -u user1 -p passwd
-m ucs-cxxx-scu-6.2.xx.iso -o vmedia -i 198.51.100.100
-d /utils_share/scu/kb -t nfs -r user2 -w passwd1 -q 120 -I 198.51.100.100
-D /niscu/new_TH2U
-F niscu_cli_remsharefile1 -T scp -U user3 -W passwd2 -x 198.51.100.254
-y /niscu/new_TH2U
-z conf_file -j sftp -b abcd -e passwd -X 198.51.100.254
-Y /niscu/answer_files
-Z rhel.cfg -J sftp -B user4 -E passwd-f log_latest

Sample nwboot.cfg file

Sample nwboot.cfg file

{
    "Update_Timeout": 240,
    "SCURepository": {
        "BootMedium": {
            "VMEDIA": {
                "ImageRepository": "10.10.10.1/home/nfsshare/iso/scu.iso",
                "TransferProtocol": "nfs",
                "Username": "root",
                "Password": "password",
                "MountOptions": ""
            },
            "HTTP": {
                "ImageRepository": "http://10.10.10.1:80/iso/scu.iso",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1,
                "IPv4Address": {
                    "AddressOrigin": "Static",
                    "Address": "10.104.255.179",
                    "Gateway": "10.104.255.129",
                    "SubnetMask": "255.255.255.128",
                    "StaticNameServer": "64.104.76.247"
                },
                "IPv6Address": {
                    "AddressOrigin": "DHCPv6",
                    "Address": "fc00:1234::a:b:c:d",
                    "PrefixLength": 64,
                    "Gateway": "fe80::fe15:b4ff:fe97:90cd",
                    "StaticNameServer": "fe80::fe15:b4ff:fe97:90cd"
                }
            },
            "FLEXMMC": {
                "ImageRepository": "scu.iso"
            },
            "MICROSD": {},
            "PXE": {
                "ImageRepository": "ftp://10.104.255.224/pub/scu",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1,
                "IPv4Address": {
                    "AddressOrigin": "DHCP"
                }
            },
            "IPXE": {
                "ImageRepository": "http://10.10.10.1/iso/scu.iso",
                "MACAddress": "70:df:2f:86:af:02",
                "PCIeSlot": "L",
                "PhysicalPortNumber": 1
            }
        }

    },
    "OSDetails": {
        "OSRepository": {
            "MediaType": "Local",
            "BootMedium": {
                "VMEDIA": {
                    "ImageRepository": "10.10.10.1/home/nfsshare/iso/rhel/RHEL-8.5.0-20211013.2-x86_64-dvd1.iso",
                    "TransferProtocol": "nfs",
                    "Username": "root",
                    "Password": "password",
                    "MountOptions": ""
                }
            }
        },
        "TargetOS": {
            "OSName": "rhel8u5x64",
            "OSEdition": "None"
        }
    },
    "TargetDisk": {
        "PHYSICALDISK": {
            "DriveSerialNumber": "06VSGVVB"
        },
        "VIRTUALDISK": {
            "StorageControllerSlotID": "MRAID",
            "VirtualDriveNumber": 0
        },
        "DISKNAME": {
            "OSDrive": "/dev/sdk"
        },
        "VIRTUALDRIVENAME": {
            "VirtualDriveName": "Hypervisor"
        },
        "ONBOARDSATAM2SSD": {
            "SATAM2SSD": "slot1"
        },
        "M2SWVDNAME": {
            "M2SWRAIDName": "RAID0"
        },
        "FC": {
            "HostWWPN": "10:00:54:88:DE:A7:32:6F",
            "TargetWWPN": "50:06:01:68:3E:A0:62:22",
            "Lun": 200
        },
        "ISCSI": {
            "MACAddress": "70:DF:2F:86:AE:FD",
            "PrimaryTargetName": "iqn.2001-05.com.equallogic:0-af1ff6-082b3ebe6-cf2005780845d665-iqn.siva-25.com",
            "PrimaryLUN": 1
        }
    },
    "RemoteLog": {
        "ImageRepository": "10.10.10.10/home/nfstest/scu.log",
        "TransferProtocol": "scp",
        "Username": "root",
        "Password": "john123"
    },
    "AnswerFile": {
        "ImageRepository": "10.10.10.10/home/nfstest/answerfile",
        "TransferProtocol": "scp",
        "Username": "root",
        "Password": "john123"
    }
}

Sample conf_file and niscu.cfg files

Sample conf file

shareMapType:www
shareIp:10.10.10.10
sharePath:/path/to/iso
shareFile:rhel66.iso
userName:www
password:www
osName:rhel6u6x64
osDrive:/dev/sdk   

DriveSerialNumber:Z1W4AC480000Z610ABCD  

StorageControllerSlotID:MRAID           

VirtualDriveNumber:0                    

VirtualDriveName:Hypervisor    
SATAM2SSD:slot1                
M2SWRAIDName:RAID00            
Edition:STANDARD   

Sample niscu.cfg file

#
# This file is just a template file and suggest user not to use this file directly without deleting comments and other info
#
# User has to create their own config file instead of using this.
#
#
[defaults]
use_http_secure=yes
update_timeout=120

[scu_iso]
isoshareip=10.10.10.10
isosharepath=/path/to/file
imagefile=ucs-cxx-scu.iso
isosharetype=www
isoshareuser=root
isosharepassword=password
mountoption=noauto   # Multiple mount options shall be passed as a comma separated list. Example - nolock,rw 
bootmedium=vmedia    # Value shall be vmedia - to boot from vmedia  or flexmmc- to boot from eMMC or microsd - to boot from microsd   

#################  Section to store SCU NI-OSI logs on Remote Server #########################

[output_location]
remshareip=10.10.10.10
remsharepath=/path/to/file
remsharefile=share_file
remsharetype=scp/sftp
remshareuser=root
remsharepassword=password

##############Section for one server starts here############

[rhel_iso]
ip=10.10.10.10
path=/path/to/conf_file
file=conf_file
username=root
password=password
protocol=scp  # supports scp, sftp, tftp and www

[rhel_answerfile]
ip=10.10.10.10
path=/path/to/answer_file
file=rhel66_custom.ks#Keep this field blank for quick install else give name of kickstart file to perform Custom install for RHEL,CENT, SLES, Ubuntu 
username=root
password=password
protocol=scp # supports scp, sftp, tftp and www

######## Section for Network Boot Support starts here ##########
[nios_install]
niosremoteshareip=10.10.10.10
niosremotesharepath=/home/nfstest/config #config templete file path for scu boot from network location
niosremotesharefile=nwboot.cfg #config template file for scu boot from network location
niosremotesharetype=scp
niosusername=root
niospassword=Ucsrack4All
niosscubootmedium=pxe #type of the boot pxe/http/ipxe
niososbootmedium=vmedia #currently only vmedia is supported
niostargetdisktype=physicaldisk #target disk details

[cimc_1]
address=10.10.10.10
user=admin
password=password
imagefile=ucs-cxx-scu.iso
config_section=rhel_iso
answerfile_section=rhel_answerfile #Mandatory for Custom Install for RHEL,CENT, SLES and Ubuntu. Remove this line, to perform Quick install.
nios_section=nios_install #nios_install section, if this section is present then it takes the priority over scu_iso section.
servernode=1/2/all	# For Colusa2 . 

#servernode option to be passed only in case of colusa2 For other server dont specify this option
##############Section for one server ends here################
##############################################################
##### To trigger os installation for multiple servers simply repeate above section with details for other server
##### and OS, also define separate conf_file for other server
############################################################################