[gridengine users] [SGE-discuss] Can prolog see resource requests?

William Hay w.hay at ucl.ac.uk
Fri Jul 19 07:49:54 UTC 2013


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 18/07/13 14:09, Pacey, Mike wrote:
> Hi folks,
> 
> I’m looking to build a GPU-card reservation subsystem into our
> local SGE setup, in order to prevent jobs grabbing more GPU cards
> than they request. Univa’s RSMAP seems to offer the functionality
> I’m after, but it looks like I can build a simple, GPU-specific
> approximation with a bit of shell scripting.
> 
> I’m starting with the standard recipe of creating a consumable gpu
> resource/complex. The next step would be to reserve free cards on a
> host via a simple central database. The problem I’m having is that
> neither the script, the prolog nor the starter_method seem to have
> access to a job’s complex/resource request, so I can’t see how many
> cards have been reserved. It’s not available as an environment
> variable, and a trawl of $SGE_JOB_SPOOL_DIR/ shows quite a few
> files (including the promising-looking config file), but not the
> data I’m after.
> 
> To progress, I’m currently scraping the resource request out of the
> job’s own copy of its submission script, which has at least one
> obvious drawback. Am I missing a trick here?
> 
> Regards, Mike.
> 
Among other things our server side JSV sets an environment variable in
the job for any resource the epilog/prolog/starter may need to
process.  Not wholly without drawbacks but slightly fewer than
submission script scraping.

We also use this for GPUs.  Our prolog/epilog scripts manipulate
lockfiles to determine which GPUs to allocate and chgrps the
/dev/nvidia* files to the job's additional group id to control access.

William



> -----
> 
> Dr Mike Pacey,                                          Email:
> M.Pacey at lancaster.ac.uk<mailto:M.Pacey at lancaster.ac.uk> HPC
> Manager,                                            Phone: 01524
> 510659 Information Systems Services,            Fax: 01524 594459 
> ISS Building, Lancaster University, Lancaster LA1 4WA
> 
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with undefined - http://www.enigmail.net/

iQIcBAEBAgAGBQJR6O+iAAoJEKCzH4joEjNW7Y8P/0mFw5EG0EZmwFx4F5M/KitS
4xOHzx0o04aTdM1aBWQunHfe2GFnU9AGvZci52nuwss613gnxlfvPGbJb8p31rhN
vloxkSV76uTBE1zatFod3lKWvRnnHJv7iZ/oTxugJbE9Vg6h6aWKuF2IRjEg8Yak
iZ9r8pSjWQQBj7e98HPhJXzQihMZybzvKAmUYJbEXvXqosEyxdjU8B5criM97m34
PeUfjxRp+89sFpWJMq8Zfzywv2n/JnOLQTCB9kbBMyEVG2l4zf5KF2t9UWL/SMGo
2oPgOfzUET3phEgaztz46KODKoBqLEaLJzn6SjQaUl5rurAoWtkBGTdD5D4IQrG0
0/xKE3gUiMg/H5enhjhMofCVp5FnUKcj54v0Y8ASw+XuNJkqkr0vLinBZ4mMWtqe
JKDMjSmKYxS3X2PL/X6uLzNVYEMQ+HsPeOX1AGG32UnoI/R52pGu5A5EbguNNPMa
fGc6mibGak2+ChPdPH0MfoORGN1ZIBaE/d2dgvf7/xo3tzAWSh4FQpqzeXPjl1Or
2VktSTH+69DcPDnbdJeg6vMP1YHVjMM4O7YQrg4LdJupkpJUJtFLfuLOQLz9/XE7
tohFYMstjmC3wIBCVKmqiTHfJzR0oD8c6XVQBhDw3jVdFTOPkDV/zBS81OtEnXov
v7WMMomMb51Bu2OkJc3N
=Ro4L
-----END PGP SIGNATURE-----





More information about the users mailing list