When you don't have a dedicated compute farm, it is often necessary to put user's machines into part-time service. So, for example, the hosts might be available for computing at night, but not during the day. It can be quite inconvenient to start and stop the Qube! Worker every day. It would be better if there were a way to simply tag Workers as available or not, depending upon the circumstances.
Qube! manages this tagging through a system of "locks" that effectively control the number of available subjob slots on any Worker host. Closing out one or more subjob slots is called "locking." This is controllable from either the WranglerView UI or by command-line calls to qblock and qbunlock.
Locking/Unlocking with the Qube! WranglerView
In WranglerView, the Host Layout provides locking/unlocking capabilities for the Workers. Right-click on a Worker or Workers and then select one of the following:
- Lock all: Locks all Worker process slots
- Unlock all: Unlocks all Worker process slots
- Lock/Unlock: Specifies number of process slots that are available
- Lock/Schedule: Pick on a weekly calendar the times that the Worker(s) should be locked or unlocked
- Lock/Watchdog: Automatically lock and unlock the Worker based on interactive computer use [Windows only]
If choosing one of the "Lock" options, decide if you want to "Purge running jobs" from the machine, which stops those processes immediately and then requeues them on other machines.
Locking/Unlocking with the command-line utilities
qblock host [host,…]
qbunlock host [host,…]
where host is a list of one more host names.
--all flag can be used in place of the hostname. When using the
--all flag, only hosts which match the other criteria are operated upon:
qblock --cluster /myCluster --all
qbunlock --active --all
By default, qblock locks out all of the subjob slots on the host, but you can also quantify the number of slots to lock or unlock:
qblock --range rangespec host
where rangespec is either a slot number, a comma-delimited list of slots, a range or some combination.
% qblock myhost
% qblock --range 0, 1 sb005