% cd ~/workbook/startd-rank/example1
Load up Condor's configuration file into your favorite editor and view the START expression. (For your convenience, the example1 directory has a symbolic link named condor_config.local to the configuration file.)
Now change the expression to
START : Owner != "userLLL"where userLLL is the login name of the user on the machine to your left. Then quit the editor after saving the configuration file.
To activate the change in configuration, type:
% condor_reconfigNow submit the example1.cmd from the previous workbook section by typing:
% cp ../../submit-rank/example1/example1.cmd . % condor_submit example1.cmd
Typing
% condor_status -runwill show that none of the machines run jobs submitted by their left neighbors.
% cd ~/workbook/startd-rank/example2
% condor_status -l machineXXXand looking up the value of the ClockMin attribute.
Now load up the configuration file in your editor and edit the START expression to
START : (ClockMin > TTT + 3) && (Owner == "userXXX")where TTT is the value of ClockMin from condor_status above, and userXXX is your login name.
Reconfigure the machine and submit example2 by typing:
% condor_reconfig ; condor_submit example2.cmdYou will notice that the machine will run your only job after three minutes have elapsed.
% cd ~/workbook/startd-rank/example3
Edit the the configuration file condor_config.local so that the START and Rank expressions look like
START : TRUE RANK : (Owner == "userXXX") * ImageSizewhere userXXX is your login name.
This policy states that any job will be accepted, but jobs submitted by you are preferred, and large jobs submitted by you are especially preferred.
Edit the command file example3a.cmd so that the requirements expression as in example1 will only run on an adjacent machine.
Requirements = Name=="machineLLL.ncsa.uiuc.edu" || Name=="machineRRR.ncsa.uiuc.edu"Now reconfigure the daemon and submit example3a:
% condor_reconfig ; condor_submit example3a.cmdThis job, like example1 from the previous workbook section, will only run on adjacent machines.
Ensure that your job is running by typing:
% condor_status -run
Now submit example3b, which does not place any requirement on which machine it will run on:
% condor_submit example3b.cmdWait a few seconds, and type:
% condor_q ; condor_status -runYou will notice that your machine has preempted the job it was previously running in preference to the second job you submitted.
Finally, submit yet another job example3c, which is similar to example2 except that it has a larger ImageSize:
% condor_submit example3c.cmdAfter a few seconds, you will notice that your machine has preempted the second job in preference to the third.
% condor_rm -a