8 Replies Latest reply on Oct 9, 2013 3:48 PM by Bill Robinson

    No cached session profile

    Jim Campbell

      My workstation was recently changed to a new Windows7 one and I am trying to get back to being able to run nsh scripts from it.  I think i have recreated everything I needed but am receiving an error:


      C:\>blcred cred -acquire
      profile name: ProfileNameHere
      username: UserNameHere
      Authentication succeeded: acquired session credential

      HostNameHere3% cat blah.nsh
      blcli_setoption serviceProfileName ProfileNameHere

      blcli_setoption roleName "RoleNameHere"


      HostNameHere3% ./blah.nsh
      com.bladelogic.om.infra.session.client.SessionLoginException: No cached Session
      Credential for named service profile - please login.
      The BLCLI is not connected


      The credential shows up from 'blcred cred -list' and is not expired.  I can perform other NSH commands (agentinfo e.g.) without issue and the NSH proxying is working (e.g. it picks up automation principals).  I do have UAC turned on but am running all of the commands from an elevated administrator command prompt.

        • 1. Re: No cached session profile
          Sean Berry

          What happens if you do blcred cred –acquire from nsh?

          • 2. Re: No cached session profile
            Jim Campbell

            Same thing.  Is it looking for the bl_sesscc file ?  I am wondering if it is having an issue with folder redirection of the user profile somehow.

            • 3. Re: No cached session profile

              Can you see the bl_sesscc file created in the home location ?

              starts NSH

              cd $HOME


              cd AppData/Roaming/BladeLogic


              see if there is a bl_sesscc file there after you do a successful blcred acquire.

              try to access the file from NSH shell you have opened.


              In case, your profile is set somehow for a different folder, you can specify the option of ssocache file using -


              blcli_setoption ssoCredCacheOpt <path to where the bl_sesscc is being created>


              • 4. Re: No cached session profile
                Aryan Anantwar



                You are right Rohit.

                if the bl_sesscc file does not exist or not accessible then this error occurs at NSH prompt for blcli_connect.


                @Jim: Login to BSA console on the same host / use blcred cred -acquire through NSH to create this bl_sesscc.

                after that, your blcli script will work properly.



                Aryan Anantwar



                • 5. Re: No cached session profile
                  Jim Campbell

                  HostNameHere% cd $HOME

                  HostNameHere% pwd


                  HostNameHere% cd AppData/Roaming/Bladelogic

                  HostNameHere% ls -l bl_sesscc

                  -rwx------   1 4294967295 mkpasswd     5151 Oct 09 09:27 bl_sesscc


                  The file is readable.  The one thing I don't see in the session credential is the name of the authentication profile.  I know it is case sensitive and have checked it over but I don't see anyway to confirm with blcred that it is the same name.


                  I have tried using blcred from within nsh and it is also not working.  The other thing is that if i use a non-administrative command prompt i get this message the first time i run NSH after logging in to the machine :


                  Created BladeLogic user's home dir : \\RemoteProfileServerHere\Share\UserNameHere\Application Data/BladeLogic


                  I do not get this when running from an administrator command prompt.  Also this is a copy/paste so it is showing different slashes for some reason.


                  For the ssoCredCacheOpt what format is this in?  I tried setting it as:


                  blcli_setoption ssoCredCacheOpt /c/Users/UserNameHere/AppData/roaming/bladelogic


                  This also did not work.

                  • 6. Re: No cached session profile

                    Contining with the same access you did earlier -

                    try running this on the command shell -


                    HostNameHere% cd $HOME

                    HostNameHere% pwd




                    blcli_setoption ssoCredCacheOpt /c/Users/UserNameHere/AppData/Roaming/BladeLogic/bl_sesscc



                    • 7. Re: No cached session profile
                      Jim Campbell

                      It looks like this works.  The first time i ran with this property set it required me to accept the certificate, but this doesn't seem to have been the issue as I still have to set the option to directly specify the location of the credential file:


                      HostNameHere% /blah.nsh
                      Do you want to accept the following X509 certificate from "service:appsvc.bladelogic:blsess://AppServerNameHere:PortHere"?


                      I had already accepted the certificate when logging in with the RCP client but I guess the CLI requires a separate authorization?  And is there any reason the CLI is looking for this file in a different location?

                      • 8. Re: No cached session profile
                        Bill Robinson

                        the problem is the unc path.  i think there is a defect open for this already as a couple other customers have ran into it.