Opened 19 years ago

Last modified 11 years ago

#75 new enhancement

IZ409: provide all resource requests to job environment

Reported by: chaubal Owned by:
Priority: normal Milestone:
Component: sge Version: 5.3
Severity: Keywords: execution


[Imported from gridengine issuezilla]

        Issue #:      409              Platform:     All           Reporter: chaubal (chaubal)
       Component:     gridengine          OS:        All
     Subcomponent:    execution        Version:      5.3              CC:    None defined
        Status:       REOPENED         Priority:     P3
      Resolution:                     Issue type:    ENHANCEMENT
                                   Target milestone: ---
      Assigned to:    andreas (andreas)
      QA Contact:     pollinger
       * Summary:     provide all resource requests to job environment
   Status whiteboard:

     Issue 409 blocks:
   Votes for issue 409:  1

   Opened: Thu Oct 31 11:16:00 -0700 2002 

Currently, the only way for a job method (starter,
prolog, etc, or even job script itself) to know
about the resources requested (both hard and soft)
when the job was submitted is to do qstat -j
$JOB_ID.  This puts an undue burden on the
qmaster, esp. if many such methods are executed
simultaneously (eg, array job submission).

It would be better if this information was somehow
made available to the job, either via environment
variables, or else in a file in the job spool

   ------- Additional comments from andreas Sun May 9 06:06:28 -0700 2004 -------
For adding this as documented 6.0 feature it's too late.

There is an undocumented hook that allows you exactly this. When you
submit a job with an empty env var that uses SGE_COMPLEX_ prefix this
is considered as a request to get the information you need in job's

   > cat bin/
   # -- our name ---
   #$ -N Envtester
   #$ -S /bin/sh

   > qsub -o "$HOME" -v SGE_COMPLEX_arch bin/
   Your job 10815 ("Envtester") has been submitted.

after job was run

   > grep SGE_COMPLEX_arch  ~/*Envtest*

I verified it works in 60b2.

   ------- Additional comments from chaubal Sat May 22 05:48:34 -0700 2004 -------
This depends upon the job submission explicitly stating certain
environment variables, which is not a good interface.  However, the
bigger problem is described on the users lists:

seems this does not play well with the new 'or' style resource requests:

  ~ > qsub -l "arch=lx24-x86|foobar" -v SGE_COMPLEX_arch
  ~ > grep arch*|foobar resource_list:
arch=lx24-x86|foobarmail_list:                   SGE_COMPLEX_arch

so this tells me nothing that i did not know at the time of job
submission -
namely that the resource would be statisfied by one of two values.
--- END QUOTE ---

With variable resource requests, there is now more than ever a need
for the job to know exactly what resources were granted at the time of

   ------- Additional comments from sgrell Mon Dec 12 03:11:40 -0700 2005 -------
Changed subcomponent.


Change History (0)

Note: See TracTickets for help on using tickets.