Process name in Upper case and nfLoad error

Clovertech Forums Read Only Archives Cloverleaf Cloverleaf Process name in Upper case and nfLoad error

  • Creator
    Topic
  • #52098
    Krishna Kumar
    Participant

      We are using a tcl script that is going through processes and renaming the SMAT files and archiving them so that SMAT size can be kept under control. In the script we are getting a keyed list to read thread configuration. I am pasting couple of statements that I am referring here



      set netconfig [file join $HciSiteDir NetConfig]              

      nfLoad $netconfig processData hostData xlateData NetFilePrologue



      The script was running fine. But then one developer created a process with a process name in upper case. Next day onwards we are getting error on the log file like  

      can’t read “hostData(name of the process in upper case)”: no such element in array Connection has no SMAT saved messages.

      We are using Cloverleaf version 5.4.1 on Windows 2003 server.

      I remember reading on user web that we cannot name a process in upper case in this version. My assumption is that we are experiencing this error because of the process with upper case name.

      Are you guys out there agreeing with me? Any comments most welcome

    Viewing 5 reply threads
    • Author
      Replies
      • #73058
        Russ Ross
        Participant

          We don’t allow thread names, site names, or process names to be in upper case.  I don’t know if this problem has been done away with as Cloverleaf is enhanced with each upgrade but I agree with you that upper case is an added risk that caused us problems in the past, too.

          Russ Ross
          RussRoss318@gmail.com

        • #73059
          Tim Pancost
          Participant

            This is one of the gotchas in using the non-official nfLoad command.  The array keys it generates are in all lower case, regardless of how the process/thread is named in NetConfig.  For the threads, you can still get the correct name from the SYMNAME attribute(using your hostData array):

            foreach threadNameLower [array names hostData] {

              set threadInfo $hostData(threadNameLower)

              set threadNameProper [keylget threadInfo SYMNAME]

              ….

            }

            Unfortunately, I don’t see a way around it for process names with uppercase.  Oh, and it’s still that way in 5.8, just checked.

            HTH,

            TIM

            Tim Pancost
            Trinity Health

          • #73060
            Krishna Kumar
            Participant

              Haa..after reading all postings it seems to me only option available is to rename the thread names and process names to upper case.

              Any other option? anybody out there please

            • #73061
              Jim Kosloskey
              Participant

                Krishna,

                I think you want to go to lower case not upper case.

                email: jim.kosloskey@jim-kosloskey.com 29+ years Cloverleaf, 59 years IT - old fart.

              • #73062
                Krishna Kumar
                Participant

                  Thanks Jim I meant to say lower case.

                • #73063
                  Tim Pancost
                  Participant

                    After noodling on this a bit, you can probably make it work, although you’ll have to do some re-write on your script, and it’s a bit kludgy.

                    You can get at the thread names as I mentioned above.  For the process names, you can get them from the process directory names, rather than NetConfig.  This is, of course, assuming your exec/processes directory only contains process directories.

                    setHciDirs (hopefully you’re already using this)

                    set processList [exec ls $HciProcessesDir]

                    The processList variable now contains a list of your processes, which you can loop through and retrieve the thread info.

                    HTH,

                    TIM

                    Tim Pancost
                    Trinity Health

                Viewing 5 reply threads
                • The forum ‘Cloverleaf’ is closed to new topics and replies.