Project

General

Profile

Feature #10643

Add ifdh log info from jobsub_wrapper

Added by Michael Diesburg over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Category:
-
Target version:
Start date:
10/26/2015
Due date:
% Done:

0%

Estimated time:
Stakeholders:
Duration:

Description

We would like to have the jobsub_wrapper script log some additional information
via the "ifdh log" command. Specifically, we would like it to log a json format
string with the following information:

poms_data="{ \"campaign_id\" : \"$CAMPAIGN_ID\" , \"task_definition_id\" : \"$TASK_DEFINITION_ID\" , \"task_id\" : \"$POMS_TASK_ID\" , \"job_id\" : \"$POMS_JOB_ID\" , \"batch_id\" : \"$JOBSUBJOBID\" , \"host_site\" : \"$HOST_SITE\" , \"b
ogomips\" : \"$BOGOMIPS\" , \"node_name\" : \"$NODE_NAME\" , \"vendor_id\" : \"$VENDOR_ID\" }"

Note in the above string the "\" were there strictly to escape the quotes for a test. They should not show up in the actual string that is logged. I believe the environment variables referenced above are either already present or will be passed through from jobsub_submit. The exceptions to that are these three variables:

BOGOMIPS
NODE_NAME
VENDOR_ID
The above should be set as:
NODE_NAME=`hostname`
BOGOMIPS=`grep bogomips /proc/cpuinfo | tail -1 | cut -d ' ' -f2`
VENDOR_ID=`grep vendor_id /proc/cpuinfo | tail -1 | cut -d ' ' -f2`

The above is meant as an example of a way to get this info. I don't care how it is actually accomplished. Since there are multiple entries for "bogomips" and "vendor_id" in cpuinfo you may take of the entries even though they may not all be exactly the same.
Thanks.
Michael Diesburg

History

#1 Updated by Dennis Box over 3 years ago

  • Target version set to v1.1.9

#2 Updated by Dennis Box over 3 years ago

  • Assignee set to Dennis Box

#3 Updated by Dennis Box over 3 years ago

Hi Mike:

Here is a sample output line from the ifdh logs:

2015-12-02T20:04:27-06:00 fermicloud042.fnal.gov /v1_8_7/nova2623442: ifdh: poms_data={"campaign_id":"","task_definition_id":"","task_id":"","job_id":"","batch_id":"","host_site":"","bogomips":"4399.99","node_name":"fermicloud042.fnal.gov","vendor_id":"GenuineIntel"}

Is this what you want?

Dennis

#4 Updated by Dennis Box over 3 years ago

  • Status changed from New to Feedback
  • Assignee changed from Dennis Box to Michael Diesburg

see output in ifdh logs on fifemon1 at /fife/local/home/ifmon/logs
also see jobsub git branch 10643

#5 Updated by Dennis Box over 3 years ago

  • Status changed from Feedback to Closed


Also available in: Atom PDF