Skip to content

A simple resource manager for helping people to not accidentally run experiments at the same time.

License

Notifications You must be signed in to change notification settings

j4cobgarby/resman

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Usage:

resman [-h] [-d DURATION] [-x [COMMAND ...]] [-r [REASON ...]] [-R] [-c] [-u USER]

A simple system resource allocation program. Persistent state stored in /etc/res_lock. This program does not impose any actual lock on system resource usage; it only keeps track of which user (if any) has laid claim to it for the time being, and if applicable how long they have it reserved for. The purpose of this is to prevent two people accidentally running experiments at the same time.

Options:

Flag(s) Description
-h, --help Show this help message and exit
-d DURATION, --duration DURATION How long to reserve server use for (e.g. 1h30m, 25m, 4h)
-x [COMMAND ...], --run [COMMAND ...] Reserve the server until COMMAND finishes. quotes (') are needed around COMMAND if it contains '-'s, otherwise they're optional.
-r [REASON ...], --reason [REASON ...] What experiment are you running? Default is blank. Completely optional.
-c, --confirm Interactively tell the user the current status of things. If the server is reserved, they are prompted to press enter to confirm they understand this.
-u USER, --user USER Who is using the server during the reservation? Default is your username.

Can also be run with no arguments, to check status. Exits with 0 if not reserved, or 1 if currently reserved. Just echo $? afterwards.

About

A simple resource manager for helping people to not accidentally run experiments at the same time.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •