Script created in BSM not appearing in BPM

Hello All

APM 9.30
BPM 9.30.471

We had created new script using vuGen to monitor an web based application and added the script in script repository in BSM. We further created End User Monitor in BSM and launched the script in BPM. However we see the script is not running in BPM.

We further checked in BPM and in BPM also we are not seeing the script been listed.

Please provide your help to fix this issue.

Parents
  • please check out in the BPM logs if you see any errors

    you can find it under %programData%\HP\BPM\workspace

    You can stop BPM delete workspace and restart it just to see if this is a temp problem or not.

  • In BPM Workspace, I see following error under details section

    440 - Failed to register

    Please clarify what does it mean and how to solve it.

  • Hi All

    I see the script is been run from BPM workspace, but status still shows "Failed to start"

    If I look at the log file /opt/HP/BPM/workspace/logs/bpm_all.log, I see following lines,

    INFO  [BpmTaskRunner-20] [GeneralScriptTaskExecutor] Running script: oml
    INFO  [BpmTaskRunner-20] [BpmSchedulerServerProxy] Adding copy script results scheduled job for oml1490787295001_7 with interval: 60 seconds
    INFO  [BpmTaskRunner-17] [BpmSchedulerCommonProxy] Adding thread timeout scheduled job for BpmTaskRunner-17
    [BpmTaskRunner-20] [BpmSchedulerCommonProxy] Adding thread timeout scheduled job for BpmTaskRunner-20
    [BpmTaskRunner-17] [BpmScheduler] Removing thread timeout scheduled job
    [BpmTaskRunner-20] [BpmScheduler] Removing copy script results scheduled job for oml1490787295001_7
    [BpmTaskRunner-20] [BpmScheduler] Removing thread timeout scheduled job
    29/03/2017 15:34:55 WARN  [BpmTaskRunner-20] [GeneralScriptTaskExecutor] The script output file: oml_*.json.cp was not created. Setting the exit code to: 6
    [BpmTaskRunner-20] [BpmSchedulerServerProxy] Adding execute run unit scheduled job for Site1_bc34801875c9e2a2b29babc6b90bc966
    [BpmTaskRunner-20] [GeneralAppExecutor] btfLastScriptEnded: BusinessTransactionFlowDto{id='989c7138666f83822684ddedfd598d88', name='oml', runMode=CLASSIC, action=PLAY, appId='bc34801875c9e2a2b29babc6b90bc966', customerName='Default Client', groupId='00000000000000000000000000000000', groupName='Default Client', locId='bdcb322d76ec4b252c5bf879c7a7c479', locName='Dubai', order='2', runStepSec='-1', webtraces=com.hp.bsm.bpm.utils.SortedValueMap@460bb06e, scripts=com.hp.bsm.bpm.utils.SortedValueMap@3ced3991} BaseRunUnit{appId='null', action=PLAY, tasksTimeoutSec=900, site='Site1', customerId='1', schedules=[], path=''}
    ERROR [SamplesHandlerThread (Site1)] [ScriptMetadata] transactions metadata is missing in metadata file: /opt/HP/BPM/workspace/agent1/Site1/data/trans_t/1490787295002_7/1490787295001_1_17_oml_________/oml.metadata samples will not be sent for this script run.

    Can someone explain what is the problem..

  • so from the logs below I noticed you have a RSHEL platform. please note BPM can run only HTTP/WEB scripts in such operating system. 

    If you are using a HTTP/WEB protocol that please run the script manual from the workspace using a simple command line 

    The way to run it, is to browse to the script\RES folder open . Open the file cmdline.txt copy the content and run it using your own user. check the output.log results immediately after the run.

     

  • Hi

    I ran the script and checked the file output.txt and it contains following error,

    vuser_init.c(75): Error -27794: Could not resolve address of host ocsp.thawte.com       [MsgId: MERR-27794]
    Vuser Terminated.

    I had faced this issue in vuGen when I try to replay the script and I solved it in vuGen by defining Proxy in script properties.

    I then imported the script as ZIP file and imported it in BSM and then launched in BPM.

    However I am seeing the same error as received in vuGen.

    Do I need to define any proxy at BSM/BPM level to resolve this issue.

  • It depends which proxy option you used in your script. for the testing I suggests you just use the "Use custom proxy" option in your script "replay"-> "runtime setting" -> "proxy" options

    If you did so that it should work.

    Now - regarding the DNS error, it is simply because BPM can not resolve this specific address. I suggest to check if it works manually without the script. 

    Just login to the machine and ping to this URL ("ping ocsp.thawte.com") , if you get the same problem and you dont get the IP than you need to fix you machine and setup a DNS client to be able to resolve this URL. 

    form my experience there is almost not DNS issue for a script without having the same problem from the machine without the script.

     

  • Hi

    I configured "Use custom proxy" option in my script "replay"-> "runtime setting" -> "proxy" options, but it fails with error,

    vuser_init.c(12): Error -26609: HTTP Status-Code=503 (Service Unavailable) for "http://mylab.com:9662/"      [MsgId: MERR-26609]

    I then configured "Use the default HTTP proxy settings" and then replay got succeeded.

    Coming back to the issue of running the script in BPM, I see ping ocsp.thawte.com fails, so I added entry in /etc/hosts file to resolve it.

    But now I am seeing one more error,

    Error -27794: Could not resolve address of host aus3.mozilla.org

    By the way I see vuGen is inserting additional URL like above which is causing this issue.

    How to rectify it.

     

  • Hi

    I created new vuGen script using IE and uploaded it to BSM and launched it from BPM.

    From /opt/HP/BPM/workspace/agent1/Site1/ops__________5e490adcdf3f8d571d97c29a879e93a5_1/WebHttpHtml1/21_1/output.txt, I am seeing following lines,

    Action.c(1036): web_url("logout.24.gif_2") was successful, 13610 body bytes, 171 header bytes   [MsgId: MMSG-26386]
    Ending action Action.
    Ending iteration 1.
    Ending Vuser...
    Starting action vuser_end.
    Ending action vuser_end
    Vuser Terminated.

    which I assume the script was executed successfully.

    In /opt/HP/BPM/workspace/agent1/Site1/ops__________5e490adcdf3f8d571d97c29a879e93a5_1/WebHttpHtml1/21_1/res/output.txt, I am seeing following error

    Action.c(4): Error -27724: Step download timeout (120 seconds) has expired      [MsgId: MERR-27724]

    How to solve this.

  • so Step download timeout (120 seconds) has expired meaning your URL was nto accesible form the BPM machine.

    You can just put this URL in the BPM machine browser  and check it is happen there.

    This is a simple timeout message not a script issue.

  • Noam

    Does it mean I need to open FW ports from BPM Server to the URL requested in the script.

  • Hi

    Yes I am able to access the URL from my BPM server.

    If I look at output.txt, I am seeing following,

    Vuser Terminated.

    If I look at /opt/HP/BPM/workspace/logs/bpm_all.log, I am seeing following errors,

    WARN  [BpmTaskRunner-17] [GeneralScriptTaskExecutor] The script output file: WebHttpHtml1_*.json.cp was not created. Setting the exit code to: 6

    ERROR [SamplesHandlerThread (Site1)] [ScriptMetadata] transactions metadata is missing in metadata file: /opt/HP/BPM/workspace/agent1/Site1/data/trans_t/1491109049001_643/1491109049000_1_21_WebHttpHtml1/WebHttpHtml1.metadata samples will not be sent for this script run.

    What does it mean and how to solve it.

     

  • It can be due to many reasons but in your case I think you did not wrap the script with a transactions (start transaction and end transaction), hence the script exist with status  6 (script error) since it does not have a transaciton to report this error.

    send me the script to review.

Reply Children
  • Noam

    Attached.

    Not able to attach the file as .usr or .zip, hence attached in image format.

  • I could not see [Transactions] section.

    can you just copy the text of the USR?

    withtout [ransaction] section you wil not see any report

    It is hard to determin such problem just by images.

  • Noam

    Please find the script

    [General]
    Type=Multi
    DefaultCfg=default.cfg
    ParameterFile=
    GlobalParameterFile=
    NewFunctionHeader=1
    RunType=cci
    ActionLogicExt=action_logic
    LastActiveAction=Action
    MajorVersion=12
    MinorVersion=53
    ActiveTypes=QTWeb
    GenerateTypes=QTWeb
    AdditionalTypes=QTWeb
    DevelopTool=Vugen
    LastModifyVer=12.53.0.1203
    ParamLeftBrace={
    ParamRightBrace=}
    ScriptLanguage=C
    LastCodeGenerationVer=12.53.0.1203
    DisableRegenerate=0
    Description=
    ScriptLocale=en-US
    [Actions]
    vuser_init=vuser_init.c
    Action=Action.c
    vuser_end=vuser_end.c
    [RunLogicFiles]
    Default Profile=default.usp
    [VuserProfiles]
    Profiles=Default Profile
    [CfgFiles]
    Default Profile=default.cfg
    [ExtraFiles]
    globals.h=
    [Modified Actions]
    vuser_init=0
    Action=1
    vuser_end=0
    [Recorded Actions]
    vuser_init=0
    Action=1
    vuser_end=0
    [Replayed Actions]
    vuser_init=1
    Action=1
    vuser_end=1
    [Interpreters]
    vuser_init=cci
    Action=cci
    vuser_end=cci
    [TransactionsOrder]
    Order=
    [StateManagement]
    LastReplayStatus=1
    [ActiveReplay]
    LastReplayedRunName=result1
    ActiveRunName=result1

  • Noam

    I created new script and put start transaction in init section and put end transaction in end section of the script.

    Imported the script to APM and ran it in BPM and this time it finished fine.

    While creating End User monitor in APM in License type I am seeing following,

    BPM Target
    Transaction single location
    APM 360 with SLM
    Transaction unlimited location.

    Can you please elaborate which one to choose when.

    Also even the script has finished running, I am not able to see data for the script in APM.

  • Verified Answer

    I don't see [Transactions] section. It means that one of 2 things:

     

    1. you did not put transactions inside the script

    2. The script was not saved correctly.

    I assume you have just one transaction names as "Order"

    in that case please ass to this file the following section, save it and upload the script again.:

    [Transactions]

    Order=

    IF it does not work please attache the Action.C file as well.