Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
- [bsubmit](https://github.com/IBMSpectrumComputing/lsf-utils/tree/master/bsubmit)
A setuid tool to submit LSF jobs on behalf of other users.

- [bsubkill](https://github.com/IBMSpectrumComputing/lsf-utils/tree/master/bsubkill)
A setuid tool to kill other users' LSF jobs.

- [LSF chatops](https://github.com/IBMSpectrumComputing/lsf-utils/tree/master/chatops/errbot)
An `Errbot` plugin to help you talking with your `LSF` cluster by `Slack` from anywhere.

Expand Down
10 changes: 10 additions & 0 deletions bsubkill/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
bsubkill:
g++ -o bsubkill bsubkill.cpp

install: bsubkill
cp -f bsubkill $(LSF_BINDIR)
chown root:root $(LSF_BINDIR)/bsubkill
chmod u+s $(LSF_BINDIR)/bsubkill

clean:
rm -rf bsubkill
63 changes: 63 additions & 0 deletions bsubkill/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
# bsubkill

bsubkill is a wrapper of bkill. It allows a user to kill another user's job.

If you would like to contribute, you must follow the DCO process in the attached [DCO Readme file](https://github.com/IBMSpectrumComputing/lsf-utils/blob/master/IBMDCO.md) in the root of this repository. It essentially requires you to provide a Sign Off line in the notes of your pull request stating that the work does not infinge on the work of others. For more details, refer to the DCO Readme file.

## Release Information

* IBM Spectrum LSF bsubkill
* Supporting LSF Release: 10.1
* Version: 1.0
* Publication date: 25 Feb 2026
* Last modified: 25 Feb 2026

## Introduction

You might want to kill a job that was submitted using bsubmit for a different user.

To do this, this package introduces a bkill wrapper with the setuid bit set. The wrapper retrieves the user of the job id and verifies if the mapping is valid using a configuration file.

## Building and installing

Before building, set the LSF environment variables:

$ source profile.lsf

To build and install, go to the main source directory and run the following commands:

$ make
$ make install

A new executable file named bsubkill is installed in the $LSF_BINDIR directory. Ensure that the file is owned by root and has the setuid bit enabled. To do this, you must have root privileges.

## Configuring and running

The bsubkill utility uses the mapping policy as bsubmit. See [Configuring and running](https://github.com/IBMSpectrumComputing/lsf-utils/blob/master/bsubmit/README.md#configuring-and-running) for configuring the mapping policy for both utilities.

The bsubkill only supports killing a job by its job id with the following command:

$ bsubkill 12345678


## Community contribution requirements

Community contributions to this repository must follow the [IBM Developer's Certificate of Origin (DCO)](https://github.com/IBMSpectrumComputing/lsf-utils/blob/master/IBMDCO.md) process and only through GitHub pull requests:

1. Contributor proposes new code to the community.

2. Contributor signs off on contributions (that is, attaches the DCO to ensure the contributor is either the code originator or has rights to publish. The template of the DCO is included in this package).

3. IBM Spectrum LSF Development reviews the contributions to check for the following:
i) Applicability and relevancy of functional content
ii) Any obvious issues

4. If accepted, contribution is posted. If rejected, work goes back to the contributor and is not merged.

## Copyright

©Copyright IBM Corporation 2020

U.S. Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.

IBM&reg;, the IBM logo, and ibm.com&reg; are trademarks of International Business Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at "Copyright and trademark information" at <http://www.ibm.com/legal/copytrade.shtml>.
Loading