Network Management

 View Only
Expand all | Collapse all

Backing up Cisco C9300, C9400 and C9600

This thread has been viewed 2 times
  • 1.  Backing up Cisco C9300, C9400 and C9600

    Posted Sep 24, 2020 03:53 AM

    Hi All,

    Is it possible to back up these Cisco switches to IMC?

    Rgds,

    Jesper



  • 2.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 24, 2020 04:04 AM

    Hello,

    iMC supports many different Cisco devices out of the box. If it doesn't work directly, add the SysOID of the devices to the iMC\server\conf\adapters\ICC\Cisco\adapter-index.xml file under the adapter (script folder) that should work, like CiscoIOSGeneric adapter.

    For more details about how you can customize iMC, I'd recommend searching online for 'customizing iMC', there is a great third-party document about this. You can customize it to back up/restore any devices that have a text-based configuration (and even some devices like F5 with a .tar.gz archive).



  • 3.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 24, 2020 04:39 AM

    Hi Justin,

    When I try to backup a C9300, I get this error: System does not support obtaining version information from the device.

    Rgds,

    Jesper



  • 4.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 24, 2020 10:29 AM

    Hello Jesper,

    That error message is misleading, as it usually means that iMC actually cannot find the adapter to use for backup.

    First, make sure the device is recognized properly in iMC. That means under System > Resource Management > Device Definition > Device Model tab, you should be able to find a result when searching for your device's SysOID (shown on the Device Details page for each device). If the SysOID is not associated with a Model definition in iMC, you won't be able to perform the backup.

    Second, navigate on iMC server to iMC\server\conf\adapters\ICC\Cisco\ and open adapter-index.xml in a text editor. Here you will see the list of SysOIDs which are associated to various different adapters, since the scripts needed to backup an ASA will obviously need to differ from those used to backup an IOS switch, and so on. Make sure the SysOID of your C9300 exists in this file - most likely it does not, so you should add it in the same format as the other SysOIDs, under the adapter that you think will most likely work. In this case, I would suggest adding it under CiscoIOSGeneric as this works with IOS-based switches. Save the file after you added the <sysoid> entry.

    Lastly, restart iMC (or at least the imccfgbakdm process) and then synchronize the device (Device Details > Actions). Then try the backup again - does it work now, or does it provide a different error at least?



  • 5.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 25, 2020 02:20 AM

    Hi Justin,

    Please see attached screenshot. As you can see I don't have a Cisco adapter in this path, iMC\server\conf\adapters\Cisco\adapter-index.xml adapter.JPG

    There are however Cisco adapters in: iMC\server\conf\adapters\GenericConfig. This .xml only have very few devices.

    Is it pissible to copy adapter index from iMC\server\conf\adapters\ICC to iMC\server\conf\adapters\Cisco\adapter-index.xml ???

    Kind regards,

    Jesper



  • 6.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 25, 2020 02:49 AM

    Hello Jesper,

    Sorry about that, I posted an incomplete path above. It should be iMC\server\conf\adapters\ICC\Cisco instead. I'll correct this. ICC folder contains all the adapters for the Intelligent Configuration Center, which handles the config backup/restore and software deployment features. You should have an adapter-index under that folder that you can edit.



  • 7.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 25, 2020 07:12 AM

    Hi Justin,

    I have added this to adapter index:

    <adapter name="Cisco C9K">
    <description>Cisco switches, Catalyst 9300, 9400, 9600</description>
    <sysoid>:1.3.6.1.4.1.9.1.2494</sysoid>
    <sysoid>:1.3.6.1.4.1.9.1.2593</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2804</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2648</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2500</sysoid>

    <sysoid>1.3.6.1.4.1.9.1.2501</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2664</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2500</sysoid>
    <sysoid>1.3.6.1.4.1.9.1.2501</sysoid>
    </adapter>

    This should be SysOID for Cisco for Cisco 9300, 9400 and 9600, but I still can't backup config for these devices.

    I got the 9300 to work, but 9400 and 9600 still fails.

    9400: Please check if the script is exist error.

    9600: not supported by system

    Kind regards,

    Jesper 



  • 8.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 25, 2020 09:35 AM

    Hello Jesper,

    Glad to hear one of them is working now. If that is the full excerpt from adapter-index.xml, I'd note that these SysOIDs are listed twice - you might want to remove the duplicates (not sure if it would cause errors but it's worth a shot):

    <sysoid>1.3.6.1.4.1.9.1.2500</sysoid>

    <sysoid>1.3.6.1.4.1.9.1.2501</sysoid>

    Regarding 9400 and 9600, the errors seem like something is not working as expected with iMC's adapter scripts. You can debug it via System > System Configuration > Log Configuration and setting the imccfgbakdm to DEBUG level, then testing the backup again. There's also a link there to download the logfile afterwards (ignore IMF log, that is not relevant).

    You should see the execution sequence of the adapter scripts and the output from the device in there, look for entries like:

     

    [INFO (0)] [THREAD(8528)] [CTclExecutor::exec_impl()] Begin to exec: 
    [INFO (0)] [THREAD(8528)] [CTelnetScriptProcessor::gotoMode()] Begin, ip: <your-device-ip>, current mode: , new mode: initialize
    [INFO (0)] [THREAD(8528)] [CTclExecutor::exec_impl()] Begin to exec: C:/Program Files/iMC/server/bin/../../server/conf/adapters/ICC/Hewlett Packard/HPProcurve2500/backup_startup_config_scp.tcl
    [ERROR (0)] [THREAD(8528)] [CTclExecutor::exec_impl()] Error occured to exec cmd: C:/Program Files/iMC/server/bin/../../server/conf/adapters/ICC/Hewlett Packard/HPProcurve2500/backup_startup_config_scp.tcl, error message: Timeout to login. No message recive from device!
    [INFO (0)] [THREAD(8528)] [CTclExecutor::exec_impl()] Finished.
    [WARNING (11)] [THREAD(8528)] [CSSHScriptProcessor::exec_step()] Fail to call oTclExecutor.execFile(), will try next command. AdaptName = HPProcurve2500, DevIP = <your-device-ip>, command script name = backup_startup_config_scp.tcl.
    [INFO (0)] [THREAD(8528)] [CCLIScriptProcessor::login_impl()] Begin ...
    [INFO (0)] [THREAD(8528)] [CCLIScriptProcessor::login()] Begin ...
    [INFO (0)] [THREAD(8528)] [CTclExecutor::exec_impl()] Begin to exec: spawn plink.exe -P 22  <your-username>@<your-device-ip>

     

    The example above is from a failed HP 2500-series backup via SCP, but you should be able to find something similar at the timestamp when your backup started. Note the error above was caused by a timeout, which is probably different in your case, but it's the kind of log entry you want to look for. Shortly thereafter you will see the sequence of .tcl scripts rund, which can also reveal which script, if any, failed to run properly.



  • 9.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 28, 2020 04:33 AM

    Hi Justin,

    I have now tried to set imccfgbakdm to "DEBUG"  Can you see what and why something goes wrong. My debug outpunt doesn't look like you example.9400.JPG9500.JPG

    Kind regards,

    Jesper

     


  • 10.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 28, 2020 05:31 AM

    Hi Jesper,

    Looking at the timestamp in your screenshots, it appears that those logs are from midnight on your server - probably not when you tested the backup, right? You'll want to look through the log for the timestamp when the IMC GUI shows that the backup started, and then you should be able to find something similar.

    PS. I'd highly recommend a tool like Notepad++ for analyzing iMC logs, as Notepad tends to have difficulties handling larger logs and also doesn't have good search functionality etc.



  • 11.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 28, 2020 05:40 AM

    Hi Justin,

    I thought I had deleted this info and replaced it.. Below is log for the 9600

    10:18:43.747 [DEBUG (0)] [THREAD(6256)] [CCfgFileTransferTaskMgr::createTask] cmd_code = 3101
    2020-09-28 10:18:43.759 [DEBUG (0)] [THREAD(6256)] [CCfgFileDataMgr::getTftpServerIP] Doesn't get dev specified tftpserver ip from "tbl_dev_transfer_protocol", Device Id:3420
    2020-09-28 10:18:43.760 [DEBUG (0)] [THREAD(6256)] [CCfgFileDataMgr::getDevTransferProtocol] Doesn't get dev specified transfer protocol from "tbl_dev_transfer_protocol", Device Id:3420
    2020-09-28 10:18:43.761 [DEBUG (0)] [THREAD(6256)] [CFileTransferTask::transferFileEx()] strDevFileName: 10.254.10.101_running_20200928101843.cfg, strHostFileName :running_3127909342.cfg
    2020-09-28 10:18:43.762 [INFO (0)] [THREAD(6256)] [CThirdPartCfgfileMgr::backupRunning()] Begin to backup running cfgfile ...
    2020-09-28 10:18:43.762 [INFO (0)] [THREAD(6256)] [CScriptProcessor::exec()] Begin to execute, data: ServiceName = ConfigBackup
    ActionName = backup_running_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/running_3127909342.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:18:43.763 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:43.763 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=Custom,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:43.763 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: custom + snmp, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_running_config, TransferProtocol: 3
    2020-09-28 10:18:43.765 [WARNING (2023)] [THREAD(6256)] [CScriptTool::getDevAdapterNameFromDB()] reader no data, sql: select vendor_name,adapter_name,error_code from tbl_dev_adapter where component_name = 'Custom' and dev_id = 3420 and adapter_type = 0
    2020-09-28 10:18:43.766 [DEBUG (0)] [THREAD(6256)] [CQvDBConnADP::executeSQL]execute"update tbl_dev_adapter set adapter_name = 'N/A',sysoid = '1.3.6.1.4.1.9.1.2871',vendor_name = 'Cisco',error_code = 18 where component_name = 'Custom' and dev_id = 3420 and adapter_type = 0" not affected rows!
    2020-09-28 10:18:43.767 [ERROR (18)] [THREAD(6256)] [CComponentAdapter::getDevAdapterName()] fail to call discoverDeviceAdapter()
    2020-09-28 10:18:43.767 [ERROR (18)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3420,ServiceName = ConfigBackup
    2020-09-28 10:18:43.767 [DEBUG (0)] [THREAD(6256)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_running_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:18:43.767 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: custom + cli, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_running_config, TransferProtocol: 3
    2020-09-28 10:18:43.767 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:43.767 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=ICC,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:43.767 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: SNMP, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_running_config, TransferProtocol: 3
    2020-09-28 10:18:43.768 [WARNING (2023)] [THREAD(6256)] [CScriptTool::getDevAdapterNameFromDB()] reader no data, sql: select vendor_name,adapter_name,error_code from tbl_dev_adapter where component_name = 'ICC' and dev_id = 3420 and adapter_type = 0
    2020-09-28 10:18:43.768 [INFO (0)] [THREAD(6256)] [CComponentAdapter::parseVendorAdapter()] Begin to parse ...
    2020-09-28 10:18:43.768 [INFO (0)] [THREAD(6256)] [CComponentAdapter::parseVendorAdapter]Vendor existed in memory.Do not need to parse again.vendor name = Cisco
    2020-09-28 10:18:43.770 [WARNING (2001)] [THREAD(6256)] [CComponentAdapter::getSupportAdapter()] Fail to get dev version,devID=3420
    2020-09-28 10:18:43.770 [WARNING (43)] [THREAD(6256)] [CComponentAdapter::discoverDeviceAdapter()] fail to call getSupportAdapter(),devID=3420
    2020-09-28 10:18:43.770 [DEBUG (0)] [THREAD(6256)] [CQvDBConnADP::executeSQL]execute"update tbl_dev_adapter set adapter_name = 'N/A',sysoid = '1.3.6.1.4.1.9.1.2871',vendor_name = 'Cisco',error_code = 43 where component_name = 'ICC' and dev_id = 3420 and adapter_type = 0" not affected rows!
    2020-09-28 10:18:43.771 [ERROR (43)] [THREAD(6256)] [CComponentAdapter::getDevAdapterName()] fail to call discoverDeviceAdapter()
    2020-09-28 10:18:43.771 [ERROR (43)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3420,ServiceName = ConfigBackup
    2020-09-28 10:18:43.771 [DEBUG (0)] [THREAD(6256)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_running_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:18:43.771 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: CLI, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_running_config, TransferProtocol: 3
    2020-09-28 10:18:43.771 [INFO (43)] [THREAD(6256)] [CScriptProcessor::exec()] Finished to execute, result:
    ServiceName = ConfigBackup
    ActionName = backup_running_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/running_3127909342.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:18:43.771 [ERROR (43)] [THREAD(6256)] [CThirdPartCfgfileMgr::__backup()] Failed to call CScriptProcessor::exec().step_detail: , error_message:
    2020-09-28 10:18:43.771 [INFO (6187)] [THREAD(6256)] [CThirdPartCfgfileMgr::backupRunning()] End to backup running cfgfile.
    2020-09-28 10:18:44.775 [DEBUG (0)] [THREAD(6256)] [CFileTransferTask::transferFileEx()] strDevFileName: 10.254.10.101_startup_20200928101844.cfg, strHostFileName :startup_3127909352.cfg
    2020-09-28 10:18:44.777 [INFO (0)] [THREAD(6256)] [CThirdPartCfgfileMgr::backupStartup()] Begin to backup startup cfgfile ...
    2020-09-28 10:18:44.779 [INFO (0)] [THREAD(6256)] [CScriptProcessor::exec()] Begin to execute, data: ServiceName = ConfigBackup
    ActionName = backup_startup_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/startup_3127909352.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:18:44.780 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:44.780 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=Custom,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:44.780 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: custom + snmp, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:18:44.782 [ERROR (18)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3420,ServiceName = ConfigBackup
    2020-09-28 10:18:44.782 [DEBUG (0)] [THREAD(6256)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:18:44.782 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: custom + cli, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:18:44.783 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:44.783 [WARNING (32)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=ICC,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:44.783 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: SNMP, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:18:44.783 [ERROR (43)] [THREAD(6256)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3420,ServiceName = ConfigBackup
    2020-09-28 10:18:44.783 [DEBUG (0)] [THREAD(6256)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:18:44.783 [DEBUG (0)] [THREAD(6256)] [CScriptProcessor::exec()] Don't support method: CLI, DevID: 3420, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:18:44.784 [INFO (43)] [THREAD(6256)] [CScriptProcessor::exec()] Finished to execute, result:
    ServiceName = ConfigBackup
    ActionName = backup_startup_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/startup_3127909352.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:18:44.784 [ERROR (43)] [THREAD(6256)] [CThirdPartCfgfileMgr::__backup()] Failed to call CScriptProcessor::exec().step_detail: , error_message:
    2020-09-28 10:18:44.784 [INFO (6187)] [THREAD(6256)] [CThirdPartCfgfileMgr::backupStartup()] End to backup startup cfgfile.
    2020-09-28 10:18:45.784 [INFO (0)] [THREAD(6304)] [CCfgFileRestoreTask::processBackupTransferTaskResult()]Process backup transfer task result: { -- SEQUENCE --
    result { -- SEQUENCE --
    operStep 'ff'H --
    ,
    result '00'H --
    ,
    stepDetail ''H -- "" --
    }
    ,
    devID '0d5c'H --
    ,
    strSession ''H -- "" --,
    devDescr '444b4c595f53575f30312831302e3235342e31302e31303129'H -- "DKLY_SW_01(10.254.10.101)" --,
    transferResultList { -- AsnDevFileTransferResultSeqOf SEQUENCE OF AsnTransferCfgFileResult
    { -- SEQUENCE --
    resultList { -- AsnCfgBakOprResultList SEQUENCE OF AsnCfgBakOprResult
    { -- SEQUENCE --
    operStep '00'H --
    ,
    result '182b'H --
    ,
    stepDetail ''H -- "" --
    }
    }
    ,
    fileType '00'H --
    ,
    cfgFileID '13'H --
    ,
    hostFileName '72756e6e696e675f333132373930393334322e636667'H -- "running_3127909342.cfg" --,
    devFileNamePath '31302e3235342e31302e3130315f72756e6e696e675f32303230303932383130313834332e636667'H -- "10.254.10.101_running_20200928101843.cfg" --
    }
    { -- SEQUENCE --
    resultList { -- AsnCfgBakOprResultList SEQUENCE OF AsnCfgBakOprResult
    { -- SEQUENCE --
    operStep '00'H --
    ,
    result '182b'H --
    ,
    stepDetail ''H -- "" --
    }
    }
    ,
    fileType '01'H --
    ,
    cfgFileID '15'H --
    ,
    hostFileName '737461727475705f333132373930393335322e636667'H -- "startup_3127909352.cfg" --,
    devFileNamePath '31302e3235342e31302e3130315f737461727475705f32303230303932383130313834342e636667'H -- "10.254.10.101_startup_20200928101844.cfg" --
    }
    }

    }

    2020-09-28 10:18:45.786 [WARNING (32)] [THREAD(6304)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:45.786 [WARNING (32)] [THREAD(6304)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=ICC,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:18:45.787 [ERROR (43)] [THREAD(6304)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3420,ServiceName = ConfigBackup
    2020-09-28 10:18:45.787 [DEBUG (0)] [THREAD(6304)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:18:45.789 [DEBUG (0)] [THREAD(6304)] [qvdm::writeOperLog] send operate log :{ -- SEQUENCE --
    strUserName '6a6566685f61'H -- "jefh_a" --,
    strOperTime ''H -- "" --,
    strIpAddr '3137322e32352e36372e323530'H -- "172.25.67.250" --,
    iModuleID '09'H --
    ,
    strOperDesc '4261636b75702072756e6e696e6720636f6e66696775726174696f6e2066696c653a20444b4c595f53575f30312831302e3235342e31302e313031292e'H -- "Backup.running.configuration.file:.DKLY_SW_01(10.254.10.101)." --,
    operRst '01'H --
    ,
    strOperFailReason '5472616e736665722066696c65203a20756e6b6f776e206572726f72'H -- "Transfer.file.:.unkown.error" --
    }

    2020-09-28 10:18:45.792 [DEBUG (0)] [THREAD(6304)] [qvdm::writeOperLog] send operate log :{ -- SEQUENCE --
    strUserName '6a6566685f61'H -- "jefh_a" --,
    strOperTime ''H -- "" --,
    strIpAddr '3137322e32352e36372e323530'H -- "172.25.67.250" --,
    iModuleID '09'H --
    ,
    strOperDesc '4261636b7570207374617274757020636f6e66696775726174696f6e2066696c653a20444b4c595f53575f30312831302e3235342e31302e313031292e'H -- "Backup.startup.configuration.file:.DKLY_SW_01(10.254.10.101)." --,
    operRst '01'H --
    ,
    strOperFailReason '5472616e736665722066696c65203a20756e6b6f776e206572726f72'H -- "Transfer.file.:.unkown.error" --
    }

    2020-09-28 10:18:46.794 [DEBUG (0)] [THREAD(6304)] [CCfgFileRestoreTask::sendBackupDevTaskNotify()] Running File:redo_flag = 0, new_step = 0,finish_ flag = 0, notify = { -- SEQUENCE --
    iSessionID '0e7e'H --
    ,
    iJobID '0e7e'H --
    ,
    iDevID '0d5c'H --
    ,
    iExtendStatus '0e'H --
    ,
    iResultCode '03'H --
    ,
    iExtendResultCode '182b'H --
    ,
    strExtendResult '3081e130090a01ff0a02182b040002020d5c0404333731300419444b4c595f53575f30312831302e3235342e31302e313031293081ae3055300b30090a01000a02182b04000a0100020113041672756e6e696e675f333132373930393334322e636667042831302e3235342e31302e3130315f72756e6e696e675f32303230303932383130313834332e6366673055300b30090a01000a02182b04000a01010201150416737461727475705f333132373930393335322e636667042831302e3235342e31302e3130315f737461727475705f32303230303932383130313834342e636667'H -- "0..0.......+.....\..3710..DKLY_SW_01(10.254.10.101)0..0U0.0.......+..........running_3127909342.cfg.(10.254.10.101_running_20200928101843.cfg0U0.0.......+..........startup_3127909352.cfg.(10.254.10.101_startup_20200928101844.cfg" --,
    bFinished FALSE,
    iStepID '07'H --
    ,
    iFileType '00'H --
    ,
    bStepFinished TRUE,
    strRespondResult ''H -- "" --
    }

    2020-09-28 10:18:47.795 [DEBUG (0)] [THREAD(6304)] [CCfgFileRestoreTask::sendBackupDevTaskNotify()] Startup File: redo_flag = 0, new_step = 0,finish_ flag = 0, notify = { -- SEQUENCE --
    iSessionID '0e7e'H --
    ,
    iJobID '0e7e'H --
    ,
    iDevID '0d5c'H --
    ,
    iExtendStatus '0e'H --
    ,
    iResultCode '03'H --
    ,
    iExtendResultCode '182b'H --
    ,
    strExtendResult '3081e130090a01ff0a02182b040002020d5c0404333731300419444b4c595f53575f30312831302e3235342e31302e313031293081ae3055300b30090a01000a02182b04000a0100020113041672756e6e696e675f333132373930393334322e636667042831302e3235342e31302e3130315f72756e6e696e675f32303230303932383130313834332e6366673055300b30090a01000a02182b04000a01010201150416737461727475705f333132373930393335322e636667042831302e3235342e31302e3130315f737461727475705f32303230303932383130313834342e636667'H -- "0..0.......+.....\..3710..DKLY_SW_01(10.254.10.101)0..0U0.0.......+..........running_3127909342.cfg.(10.254.10.101_running_20200928101843.cfg0U0.0.......+..........startup_3127909352.cfg.(10.254.10.101_startup_20200928101844.cfg" --,
    bFinished TRUE,
    iStepID '06'H --

    Kind regards,

    Jesper



  • 12.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 28, 2020 05:45 AM

    And below should be log for the 9400:

    28 10:16:45.846 [ERROR (21)] [THREAD(6252)] [CThirdPartCfgfileMgr::__backup()] Failed to call CScriptProcessor::exec().step_detail: , error_message:
    2020-09-28 10:16:45.846 [INFO (6133)] [THREAD(6252)] [CThirdPartCfgfileMgr::backupRunning()] End to backup running cfgfile.
    2020-09-28 10:16:46.846 [DEBUG (0)] [THREAD(6252)] [CFileTransferTask::transferFileEx()] strDevFileName: 10.254.10.103_startup_20200928101646.cfg, strHostFileName :startup_3127908172.cfg
    2020-09-28 10:16:46.847 [INFO (0)] [THREAD(6252)] [CThirdPartCfgfileMgr::backupStartup()] Begin to backup startup cfgfile ...
    2020-09-28 10:16:46.848 [INFO (0)] [THREAD(6252)] [CScriptProcessor::exec()] Begin to execute, data: ServiceName = ConfigBackup
    ActionName = backup_startup_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/startup_3127908172.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:16:46.848 [WARNING (32)] [THREAD(6252)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:46.848 [WARNING (32)] [THREAD(6252)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=Custom,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:46.848 [DEBUG (0)] [THREAD(6252)] [CScriptProcessor::exec()] Don't support method: custom + snmp, DevID: 3423, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:16:46.850 [ERROR (18)] [THREAD(6252)] [CComponentAdapter::isDevSupportServiceAction()] fail to call getDevAdapterName().DevID=3423,ServiceName = ConfigBackup
    2020-09-28 10:16:46.850 [DEBUG (0)] [THREAD(6252)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = N/A,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:16:46.850 [DEBUG (0)] [THREAD(6252)] [CScriptProcessor::exec()] Don't support method: custom + cli, DevID: 3423, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:16:46.850 [WARNING (32)] [THREAD(6252)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:46.850 [WARNING (32)] [THREAD(6252)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=ICC,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:46.850 [DEBUG (0)] [THREAD(6252)] [CScriptProcessor::exec()] Don't support method: SNMP, DevID: 3423, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:16:46.850 [ERROR (21)] [THREAD(6252)] [CDevAdapter::parserAdapterIndexProcess()] get Doc Node error, file: D:\Program Files\iMC\server\bin\..\..\server\conf\adapters\ICC\Cisco\Cisco C9K\adapter.xml
    2020-09-28 10:16:46.850 [ERROR (21)] [THREAD(6252)] [CDevAdapter::getAdapterService] fail to call parseAdapterIndex.AdapterName = Cisco C9K
    2020-09-28 10:16:46.850 [WARNING (21)] [THREAD(6252)] [CComponentAdapter::getAdapterService] fail to call poAdapter->getAdapterService().service name = ConfigBackup
    2020-09-28 10:16:46.851 [WARNING (21)] [THREAD(6252)] [CComponentAdapter::isDevSupportServiceAction()] Can not support specify service.DevID=3423,ServiceName = ConfigBackup,adaptername=Cisco C9K
    2020-09-28 10:16:46.851 [DEBUG (0)] [THREAD(6252)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = Cisco C9K,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:16:46.851 [DEBUG (0)] [THREAD(6252)] [CScriptProcessor::exec()] Don't support method: CLI, DevID: 3423, ServiceName: ConfigBackup, ActionName: backup_startup_config, TransferProtocol: 3
    2020-09-28 10:16:46.851 [INFO (21)] [THREAD(6252)] [CScriptProcessor::exec()] Finished to execute, result:
    ServiceName = ConfigBackup
    ActionName = backup_startup_config
    InputParam = TFTPFile=D:/Program Files/iMC/server/tmp/startup_3127908172.cfg?_?TFTPServer=192.168.100.250?_?UnitList=?_?VpnName=
    OutputParam =
    CmdResp =
    ErrorMessage =
    ActionResult = 19

    2020-09-28 10:16:46.851 [ERROR (21)] [THREAD(6252)] [CThirdPartCfgfileMgr::__backup()] Failed to call CScriptProcessor::exec().step_detail: , error_message:
    2020-09-28 10:16:46.851 [INFO (6133)] [THREAD(6252)] [CThirdPartCfgfileMgr::backupStartup()] End to backup startup cfgfile.
    2020-09-28 10:16:47.852 [INFO (0)] [THREAD(6296)] [CCfgFileRestoreTask::processBackupTransferTaskResult()]Process backup transfer task result: { -- SEQUENCE --
    result { -- SEQUENCE --
    operStep 'ff'H --
    ,
    result '00'H --
    ,
    stepDetail ''H -- "" --
    }
    ,
    devID '0d5f'H --
    ,
    strSession ''H -- "" --,
    devDescr '444b4c595f53575f30332831302e3235342e31302e31303329'H -- "DKLY_SW_03(10.254.10.103)" --,
    transferResultList { -- AsnDevFileTransferResultSeqOf SEQUENCE OF AsnTransferCfgFileResult
    { -- SEQUENCE --
    resultList { -- AsnCfgBakOprResultList SEQUENCE OF AsnCfgBakOprResult
    { -- SEQUENCE --
    operStep '00'H --
    ,
    result '17f5'H --
    ,
    stepDetail ''H -- "" --
    }
    }
    ,
    fileType '00'H --
    ,
    cfgFileID '10'H --
    ,
    hostFileName '72756e6e696e675f333132373930383136322e636667'H -- "running_3127908162.cfg" --,
    devFileNamePath '31302e3235342e31302e3130335f72756e6e696e675f32303230303932383130313634352e636667'H -- "10.254.10.103_running_20200928101645.cfg" --
    }
    { -- SEQUENCE --
    resultList { -- AsnCfgBakOprResultList SEQUENCE OF AsnCfgBakOprResult
    { -- SEQUENCE --
    operStep '00'H --
    ,
    result '17f5'H --
    ,
    stepDetail ''H -- "" --
    }
    }
    ,
    fileType '01'H --
    ,
    cfgFileID '12'H --
    ,
    hostFileName '737461727475705f333132373930383137322e636667'H -- "startup_3127908172.cfg" --,
    devFileNamePath '31302e3235342e31302e3130335f737461727475705f32303230303932383130313634362e636667'H -- "10.254.10.103_startup_20200928101646.cfg" --
    }
    }

    }

    2020-09-28 10:16:47.853 [WARNING (32)] [THREAD(6296)] [CComponentAdapter::checkAccessTypeMatchTransferProtocol()] transfer protocol does not match access type,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:47.853 [WARNING (32)] [THREAD(6296)] [CComponentAdapter::isDevSupportServiceAction()] transfer protocol does not match access type,ServiceName = ConfigBackup,commandName=ICC,iTransferProtocol=3,iAccessType=3
    2020-09-28 10:16:47.854 [ERROR (21)] [THREAD(6296)] [CDevAdapter::parserAdapterIndexProcess()] get Doc Node error, file: D:\Program Files\iMC\server\bin\..\..\server\conf\adapters\ICC\Cisco\Cisco C9K\adapter.xml
    2020-09-28 10:16:47.854 [ERROR (21)] [THREAD(6296)] [CDevAdapter::getAdapterService] fail to call parseAdapterIndex.AdapterName = Cisco C9K
    2020-09-28 10:16:47.854 [WARNING (21)] [THREAD(6296)] [CComponentAdapter::getAdapterService] fail to call poAdapter->getAdapterService().service name = ConfigBackup
    2020-09-28 10:16:47.854 [WARNING (21)] [THREAD(6296)] [CComponentAdapter::isDevSupportServiceAction()] Can not support specify service.DevID=3423,ServiceName = ConfigBackup,adaptername=Cisco C9K
    2020-09-28 10:16:47.854 [DEBUG (0)] [THREAD(6296)] [CAdapterMgr::isDevSupportServiceAction] Fail to call isDevSupportServiceAction().Adapter name = Cisco C9K,Service name = ConfigBackup,Action name = backup_startup_config,AccessType = 2,iTransferProtocol = 3
    2020-09-28 10:16:47.855 [DEBUG (0)] [THREAD(6296)] [qvdm::writeOperLog] send operate log :{ -- SEQUENCE --
    strUserName '6a6566685f61'H -- "jefh_a" --,
    strOperTime ''H -- "" --,
    strIpAddr '3137322e32352e36372e323530'H -- "172.25.67.250" --,
    iModuleID '09'H --
    ,
    strOperDesc '4261636b75702072756e6e696e6720636f6e66696775726174696f6e2066696c653a20444b4c595f53575f30332831302e3235342e31302e313033292e'H -- "Backup.running.configuration.file:.DKLY_SW_03(10.254.10.103)." --,
    operRst '01'H --
    ,
    strOperFailReason '5472616e736665722066696c65203a20536372697074206578697374206572726f722e'H -- "Transfer.file.:.Script.exist.error." --
    }

    2020-09-28 10:16:47.859 [DEBUG (0)] [THREAD(6296)] [qvdm::writeOperLog] send operate log :{ -- SEQUENCE --
    strUserName '6a6566685f61'H -- "jefh_a" --,
    strOperTime ''H -- "" --,
    strIpAddr '3137322e32352e36372e323530'H -- "172.25.67.250" --,
    iModuleID '09'H --
    ,
    strOperDesc '4261636b7570207374617274757020636f6e66696775726174696f6e2066696c653a20444b4c595f53575f30332831302e3235342e31302e313033292e'H -- "Backup.startup.configuration.file:.DKLY_SW_03(10.254.10.103)." --,
    operRst '01'H --
    ,
    strOperFailReason '5472616e736665722066696c65203a20536372697074206578697374206572726f722e'H -- "Transfer.file.:.Script.exist.error." --
    }

    2020-09-28 10:16:48.861 [DEBUG (0)] [THREAD(6296)] [CCfgFileRestoreTask::sendBackupDevTaskNotify()] Running File:redo_flag = 0, new_step = 0,finish_ flag = 0, notify = { -- SEQUENCE --
    iSessionID '0e7d'H --
    ,

    Isn't it possible to attach a zip file ?

    Kind regards,

    Jesper



  • 13.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 29, 2020 03:45 AM

    Hello,

    For the first (9600), it looks like iMC cannot find the correct adapter to use:

    adapter_name = 'N/A',sysoid = '1.3.6.1.4.1.9.1.2871',

    A few things you can check...

    * Make sure you have defined the device model for this SysOID via Resource Management > Device Definition

    * Make sure iMC is provided with SNMP RW and full CLI access, and the CLI Login Type (Telnet/SSH) is set

    * Verify the SysOID of the switch is indeed in the adapter-index.xml file under the correct adapter

    * Try deleting the device from iMC and re-adding it, this will force it to update the adapter

    One more thing - if you use Telnet as CLI access, iMC expects that you will also use TFTP/FTP as transfer protocol, and with SSH it will expect a secure transfer protocol like SCP/SFTP, otherwise it will complain (in the log, "transfer protocol does not match access type").

    You can check which protocols and methods (CLI or SNMP-triggered backup) iMC detected as supported for your device by going to Configuration Center > Options page. Device Capability Set shows you this. The default transfer protocol used is on the next tab "File Transfer Mode", and further down on the page you can define a "Single Device Transfer Mode" for individual devices that do not work with the default transfer mode.

    Keep in mind that for FTP and SFTP Server modes you must set up a third-party FTP solution on iMC's server for it to work. Personally I'd recommend TFTP or SCP for ease of setup where supported.

    ---

    Regarding the 9400, what is the Cisco C9K adapter? Did you create a custom adapter for these switches? If so, which existing adapter are the scripts based on? I'm asking since my own iMC installations don't have such a folder.

    2020-09-28 10:16:46.850 [ERROR (21)] [THREAD(6252)] [CDevAdapter::parserAdapterIndexProcess()] get Doc Node error, file: D:\Program Files\iMC\server\bin\..\..\server\conf\adapters\ICC\Cisco\Cisco C9K\adapter.xml
    2020-09-28 10:16:46.850 [ERROR (21)] [THREAD(6252)] [CDevAdapter::getAdapterService] fail to call parseAdapterIndex.AdapterName = Cisco C9K
    2020-09-28 10:16:46.850 [WARNING (21)] [THREAD(6252)] [CComponentAdapter::getAdapterService] fail to call poAdapter->getAdapterService().service name = ConfigBackup
    2020-09-28 10:16:46.851 [WARNING (21)] [THREAD(6252)] [CComponentAdapter::isDevSupportServiceAction()] Can not support specify service.DevID=3423,ServiceName = ConfigBackup,adaptername=Cisco C9K

    The error message seems to indicate there's a problem with the adapter.xml file, which is a file located in each adapter folder that defines the services (config backup, deployment etc) that are available for the devices using it. If you create a custom adapter folder, note that they do not have any blank space in the name. Please make sure there is no space - Cisco C9K should be changed to CiscoC9K and adapter-index.xml updated accordingly too.



  • 14.  RE: Backing up Cisco C9300, C9400 and C9600

    Posted Sep 29, 2020 06:46 AM

    Hi Justin,

    Good new, I got it to work.

    I moved related SysOIDs under "generic Cisco adapter" in -xml file. Rebooted server, and deleted 9400 and 9600 devices and added devices again. Now it works

    Thanks for your support. It's highly appriciated.

    Best regards,

    Jesper