Announcement

Collapse
No announcement yet.

SETCOMPUTERNAME variable

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • SETCOMPUTERNAME variable

    Is there a way to use the SETCOMPUTERNAME to pull the name from the computer or something else that is unique to the computer? It would be nice to be able to create just one script and have it run and not have to worry about going back and renaming the files that it exports.

  • #2
    Log file name prefixes using an environment variable, %COMPUTERNAME%, %USERNAME%, %OS%, %PROCESSOR_ARCHITECTURE% are supported. So, if for example you wanted to prefix log files with a computer’s name, just enter the following in Preferences->Logging, Prefix,
    %COMPUTERNAME%_

    If you want to change the COMPUTERNAME, you could set the %COMPUTERNAME% environment variable for example in a batch file, that also starts BurnInTest:
    eg.
    SET COMPUTERNAME=abc123
    c:
    cd "\Program Files\BurnInTest"
    bit.exe -r -p

    Regards,
    Ian

    Comment


    • #3
      Performance Test 6.1

      I'm running Performance test 6.1 not Burn-in. Below is the script I'm running. I'm wanting to know if the first line SETCOMPUTERNAME can use a variable so that it pick up the real name of the computer and not just what I put in there like "My Test Machine" I tried to use "%COMPUTERNAME%" but it only put in what was in the quotes. I'm wanting it to pick up the name of the computer. Is that possible?


      SETCOMPUTERNAME "My Test Machine"
      SETDURATION 20
      RUN CPU_ALL
      RUN ME_ALL
      RUN DI_ALL

      EXPORTHTML "C:\baseline\results.html"
      EXPORTCSV "C:\baseline\results.csv"
      EXPORTTEXTF "C:\baseline\resultsF.txt"

      Comment


      • #4
        Sorry, my mind was clearly thinking BurnInTest when I answered this.

        No, the PerformanceTest 6.1 SETCOMPUTERNAME can only have fixed values. We are thinking of adding dynamic log names in the next major release of PerformanceTest.

        Regards,
        Ian

        Comment


        • #5
          Workaround

          For a workaround try this:

          set FileName=E:\PerformanceTest\bench.pts

          If Exist %FileName% del %FileName%

          echo SETCOMPUTERNAME "%computername%" >> %FileName%
          echo SUPPRESSWARNINGS ON >> %FileName%
          echo SETDISK "C:" >> %FileName%
          echo SETPCPUTESTPROCESSES 5 >> %FileName%
          echo RUN CPU_ALL >> %FileName%
          echo RUN G2D_ALL >> %FileName%
          echo RUN ME_ALL >> %Filename%
          echo RUN DI_ALL >> %Filename%
          echo EXPORTCSV "<export location>" >> %Filename%
          E:\PerformanceTest\pt.exe /s bench.pts

          It dynamically rebuilds the script that runs to insert the computername. Works great for me, hope this helps.

          Comment


          • #6
            Thanks for the feedback.
            Regards,
            Ian

            Comment

            Working...
            X