TSSA/BSA: CLI command/Script fails with "java.io.IOException: xml/cli is not a directory

Version 2
    Share This:

    This document contains official content from the BMC Software Knowledge Base. It is automatically updated when the knowledge article is modified.


    PRODUCT:

    BladeLogic Server Automation Suite


    APPLIES TO:

    BSA 8.x, TSSA 8.x



    QUESTION:

    Running a BMC BladeLogic Server Automation (BSA) or TrueSight Server Automation (TSSA) CLI Command/Script fails with the following:

    [28 Feb 2017 15:49:00,099] [main] [ERROR] [::] [] Failed to initialize command template inventory
    java.io.IOException: xml/cli is not a directory
    at com.bladelogic.om.infra.cli.factory.CommandTemplateInventory.getFilesInDirectory(CommandTemplateInventory.java:746)
    at com.bladelogic.om.infra.cli.factory.CommandTemplateInventory.loadCommandTemplatesFromDir(CommandTemplateInventory.java:650)
    at com.bladelogic.om.infra.cli.factory.CommandTemplateInventory.loadCommandTemplatesFromDir(CommandTemplateInventory.java:640)
    at com.bladelogic.om.infra.model.blcli.BlcliServerServiceImpl.initCommandFactory(BlcliServerServiceImpl.java:94)
    at com.bladelogic.om.infra.model.blcli.BlcliServerServiceImpl.initialize(BlcliServerServiceImpl.java:80)
    at com.bladelogic.om.infra.model.blcli.BlcliServerServiceImpl.<init>(BlcliServerServiceImpl.java:33)
    at com.bladelogic.om.infra.model.blcli.BlcliServerServiceImpl.getInstance(BlcliServerServiceImpl.java:61)
    at com.bladelogic.om.infra.model.ServiceFactory.getBlcliServerService(ServiceFactory.java:1508)
    at com.bladelogic.om.infra.model.ServiceServiceImpl.getBlcliServerService(ServiceServiceImpl.java:3299)
    at com.bladelogic.om.infra.model.blcli.BlcliServerManagerProxy.startBlcliServerService(BlcliServerManagerProxy.java:15)
    at com.bladelogic.om.infra.app.service.appserver.DefaultAppServerServiceImpl.postStartup(DefaultAppServerServiceImpl.java:600)
    at com.bladelogic.om.infra.mfw.fw.BlManager.runPostStartupServices(BlManager.java:1775)
    at com.bladelogic.om.infra.mfw.fw.BlManager.startWithType(BlManager.java:850)
    at com.bladelogic.om.infra.app.service.migration.PostMigration.doPostMigration(PostMigration.java:65)
    at com.bladelogic.om.infra.app.service.migration.PostMigration.main(PostMigration.java:51)
    [28 Feb 2017 15:49:00,115] [pool-3-thread-1] [INFO] [::] [] Starting BlCLI Server Service...

    In this example, it is encountered by the BSA Upgrade Postmigration utility because it uses the BLCLI but it is not specific to this utility.  This error can occur with any blcli command execution attempt.


    ANSWER:

    A directory called "cli" is expected under the "xml" directory on the server where the BLCLI is being run.

    This error suggests that a file (not a directory) called either xml or cli is being found instead which results in the "not a directory" error.  Or the referenced xml/cli directory is not present in the expected location.

    1) Check the directory listing of NSH/br to see if there is a file named 'xml'. If so, move it to another backup directory and retest.

    2) Check the directory listing of NSH/br/xml to see if there is a file named 'cli'. If so, move it to another backup directory and retest.

    3) If the directory xml/cli is not present, copy from another TSSA/BSA Console installation of the same version.  Once in place, then retest the blcli command execution.

     


    Article Number:

    000132592


    Article Type:

    FAQ/Procedural



      Looking for additional information?    Search BMC Support  or  Browse Knowledge Articles