pbs_runjob.3B 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100
  1. .\" Copyright (C) 1994-2018 Altair Engineering, Inc.
  2. .\" For more information, contact Altair at www.altair.com.
  3. .\"
  4. .\" This file is part of the PBS Professional ("PBS Pro") software.
  5. .\"
  6. .\" Open Source License Information:
  7. .\"
  8. .\" PBS Pro is free software. You can redistribute it and/or modify it under the
  9. .\" terms of the GNU Affero General Public License as published by the Free
  10. .\" Software Foundation, either version 3 of the License, or (at your option) any
  11. .\" later version.
  12. .\"
  13. .\" PBS Pro is distributed in the hope that it will be useful, but WITHOUT ANY
  14. .\" WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  15. .\" FOR A PARTICULAR PURPOSE.
  16. .\" See the GNU Affero General Public License for more details.
  17. .\"
  18. .\" You should have received a copy of the GNU Affero General Public License
  19. .\" along with this program. If not, see <http://www.gnu.org/licenses/>.
  20. .\"
  21. .\" Commercial License Information:
  22. .\"
  23. .\" For a copy of the commercial license terms and conditions,
  24. .\" go to: (http://www.pbspro.com/UserArea/agreement.html)
  25. .\" or contact the Altair Legal Department.
  26. .\"
  27. .\" Altair’s dual-license business model allows companies, individuals, and
  28. .\" organizations to create proprietary derivative works of PBS Pro and
  29. .\" distribute them - whether embedded or bundled with other software -
  30. .\" under a commercial license agreement.
  31. .\"
  32. .\" Use of Altair’s trademarks, including but not limited to "PBS™",
  33. .\" "PBS Professional®", and "PBS Pro™" and Altair’s logos is subject to Altair's
  34. .\" trademark licensing policies.
  35. .\"
  36. .TH pbs_runjob 3B "11 September 2013" Local "PBS Professional"
  37. .SH NAME
  38. pbs_runjob, pbs_asyrunjob - run a PBS batch job, asynchronous batch job
  39. .SH SYNOPSIS
  40. #include <pbs_error.h>
  41. .br
  42. #include <pbs_ifl.h>
  43. .sp
  44. .B int pbs_runjob(\^int\ connect, char\ *job_id, char\ *location, char\ *extend)
  45. .sp
  46. .B int pbs_asyrunjob(\^int\ connect, char\ *job_id, char\ *location, char\ *extend)
  47. .SH DESCRIPTION
  48. Issue a batch request to run a batch job.
  49. .LP
  50. For
  51. .I pbs_runjob()
  52. a "Run Job"
  53. batch request is generated and sent to the server over the connection
  54. specified by
  55. .I connect
  56. which is the return value of \f3pbs_connect\f1().
  57. The server will reply when the job has started execution unless file
  58. in-staging is required. In that case, the server will reply when the
  59. staging operations are started.
  60. .LP
  61. For
  62. .I pbs_asyrunjob()
  63. an "Asynchronous Run Job"
  64. request is generated and sent to the server over the connection.
  65. The server will validate the request and reply before initiating the
  66. execution of the job. This version of the call can be used to reduce
  67. latency in scheduling, especially when the scheduler must start a large
  68. number of jobs.
  69. .LP
  70. These requests requires that the issuing user have operator or
  71. administrator privilege.
  72. .LP
  73. The argument,
  74. .I job_id ,
  75. identifies which job is to be run it is specified in the form:
  76. .RS 4
  77. .I "sequence_number.server"
  78. .RE
  79. .LP
  80. The argument,
  81. .I location ,
  82. if not the null pointer or null string, specifies the location where the
  83. job should be run, and optionally the resources to use. The location
  84. is the same as the -H option to the qrun command. See the
  85. description of qrun -H, both with and without resources specified, in
  86. the qrun.8B man page.
  87. .LP
  88. The argument,
  89. .I extend ,
  90. is reserved for implementation-defined extensions.
  91. .SH "SEE ALSO"
  92. qrun(8B), qsub(1B), and pbs_connect(3B)
  93. .SH DIAGNOSTICS
  94. When the batch request generated by the \f3pbs_runjob\f1()
  95. or \f3pbs_asyrunjob\f1()
  96. functions has been completed successfully by a batch server, the routines will
  97. return 0 (zero).
  98. Otherwise, a non zero error is returned. The error number is also set
  99. in pbs_errno.