I'm trying to test a script for upgrading IOS of a 3560 switch. but receiving below error
*
% Unknown command or computer name, or unable to find computer address
.CHANGE_TEMPLATE_DESCRIPTION
Translating ".CHANGE_TEMPLATE_DESCRIPTION"...domain server (255.255.255.255)
% Unknown command or computer name, or unable to find computer address
This template allows the upgrade of the IOS and associated web management tools on Cisco Catalyst switches.
This template allows the upgrade of the IOS and associated web management tools on Cisco Catalyst switches.
^
% Invalid input detected at '^' marker.
.PLATFORM_DESCRIPTION
Translating ".PLATFORM_DESCRIPTION"...domain server (255.255.255.255)
% Unknown command or computer name, or unable to find computer address
This runs on Cisco IOS devices.
This runs on Cisco IOS devices.
^
% Invalid input detected at '^' marker.
.PARAMETER_LABEL @ContextNode
.PARAMETER_LABEL @ContextNode
^
% Invalid input detected at '^' marker.
NCM Node
NCM Node
^
% Invalid input detected at '^' marker.
.PARAMETER_DESCRIPTION @ContextNode
.PARAMETER_DESCRIPTION @ContextNode
^
% Invalid input detected at '^' marker.
The node the template will operate on. All templates require this by default. The target node is selected during the first part of the wizard so it will not be available for selection when defining values of variables.
The node the template will operate on. All templates require this by default. The target node is selected during the first part of the wizard so it will not be available for selection when defining values of variables.
^
% Invalid input detected at '^' marker.
.PARAMETER_LABEL @IOS_FILENAME
.PARAMETER_LABEL @IOS_FILENAME
^
% Invalid input detected at '^' marker.
The File Name of the new IOS Version.
The File Name of the new IOS Version.
^
% Invalid input detected at '^' marker.
.PARAMETER_DESCRIPTION @IOS_FILENAME
.PARAMETER_DESCRIPTION @IOS_FILENAME
^
% Invalid input detected at '^' marker.
This should be a valid Cisco IOS File. No spaces are allowed, a script will not be generated for a Cisco IOS Filename that includes a space. Current IOS versions held on the server are:
This should be a valid Cisco IOS File. No spaces are allowed, a script will not be generated for a Cisco IOS Filename that includes a space. Current IOS versions held on the server are:
^
% Invalid input detected at '^' marker.
2960: c2960-lanbasek9-tar.122-58.SE2.tar
2960: c2960-lanbasek9-tar.122-58.SE2.tar
^
% Invalid input detected at '^' marker.
3560: c3560-ipbaselmk9-tar.122-55.SE5.tar
3560: c3560-ipbaselmk9-tar.122-55.SE5.tar
^
% Invalid input detected at '^' marker.
3560: c3560e-ipbasek9-tar.150-2.SE9
3560: c3560e-ipbasek9-tar.150-2.SE9
^
% Invalid input detected at '^' marker.
3560G: c3560-ipbasek9-tar.122-55.SE5.tar
3560G: c3560-ipbasek9-tar.122-55.SE5.tar
^
% Invalid input detected at '^' marker.
3750v1: c3750-ipbaselmk9-tar.122-55.SE4.tar
3750v1: c3750-ipbaselmk9-tar.122-55.SE4.tar
^
% Invalid input detected at '^' marker.
3750v2: c3750-ipbasek9-tar.122-58.SE2.tar
3750v2: c3750-ipbasek9-tar.122-58.SE2.tar
^
% Invalid input detected at '^' marker.
*/
% Unknown command or computer name, or unable to find computer address
script UpgradeIOS (
script UpgradeIOS (
^
% Invalid input detected at '^' marker.
NCM.Nodes @ContextNode,
NCM.Nodes @ContextNode,
^
% Invalid input detected at '^' marker.
string @IOS_FILENAME )
string @IOS_FILENAME )
^
% Invalid input detected at '^' marker.
{
% Unknown command or computer name, or unable to find computer address
string @CommandLine = 'archive download-sw /overwrite tftp://192.168.10.77/' + @IOS_FILENAME
string @CommandLine = 'archive download-sw /overwrite tftp://192.168.10.77/' + @IOS_FILENAME
^
% Invalid input detected at '^' marker.
if (@IOS_FILENAME contains ' ')
if (@IOS_FILENAME contains ' ')
^
% Invalid input detected at '^' marker.
{}
% Unknown command or computer name, or unable to find computer address
else
Translating "else"...domain server (255.255.255.255)
% Unknown command or computer name, or unable to find computer address
{
% Unknown command or computer name, or unable to find computer address
foreach ( @node in @ContextNode )
foreach ( @node in @ContextNode )
^
% Invalid input detected at '^' marker.
{
% Unknown command or computer name, or unable to find computer address
if ( @node.Vendor == 'Cisco' )
if ( @node.Vendor == 'Cisco' )
^
% Invalid input detected at '^' marker.
{
% Unknown command or computer name, or unable to find computer address
CLI
Translating "CLI"...domain server (255.255.255.255)
% Unknown command or computer name, or unable to find computer address
{
% Unknown command or computer name, or unable to find computer address
@CommandLine
% Unknown command or computer name, or unable to find computer address
}
% Unknown command or computer name, or unable to find computer address
}
% Unknown command or computer name, or unable to find computer address
}
% Unknown command or computer name, or unable to find computer address
}
% Unknown command or computer name, or unable to find computer address
}
% Unknown command or computer name, or unable to find computer address
I have attached the original script here. Kindly let me know what is wrong and why