parallel/doc/FUTURE_IDEAS

65 lines
2 KiB
Plaintext
Raw Normal View History

2010-04-19 07:07:12 +00:00
=head1 IDEAS
2010-06-05 23:03:39 +00:00
Kan vi lave flere ssh'er, hvis vi venter lidt?
En ssh med 20% loss og 900 ms delay, så kan login nås på 15 sek.
2010-04-19 07:07:12 +00:00
Test if -0 works on filenames ending in '\n'
2010-06-05 23:03:39 +00:00
Transfer scriptfile before first job. Remove it when last job done.
2010-04-19 07:07:12 +00:00
monitor to see which jobs are currently running
http://code.google.com/p/ppss/
Accept signal INT instead of TERM to complete current running jobs but
do not start new jobs. Print out the number of jobs waiting to
complete on STDERR. Accept sig INT again to kill now. This seems to be
hard, as all foreground processes get the INT from the shell.
If there are nomore jobs (STDIN is closed) then make sure to
distribute the arguments evenly if running -X.
Parallelize so this can be done:
mdm.screen find dir -execdir mdm-run cmd {} \;
Maybe:
find dir -execdir par$ --communication-file /tmp/comfile cmd {} \;
2010-06-05 23:03:39 +00:00
find dir -execdir mutex -j4 -b cmd {} \;
2010-04-19 07:07:12 +00:00
=head2 Comfile
This will put a lock on /tmp/comfile. The number of locks is the number of running commands.
If the number is smaller than -j then it will start a process in the background ( cmd & ),
otherwise wait.
par$ --wait /tmp/comfile will wait until no more locks on the file
=head2 mutex
2010-06-05 23:03:39 +00:00
mutex -b -n -l lockid -m max_locks [command]
2010-04-19 07:07:12 +00:00
mutex -u lockid
2010-06-05 23:03:39 +00:00
-b run command in background
2010-04-19 07:07:12 +00:00
-l lockfile will lock using the lockid
-n nonblocking
-m maximal number of locks (default 1)
-u unlock
If command given works like: mutex -l lockfile -n number_of_locks ; command; mutex -u lockfile
2010-06-05 23:03:39 +00:00
If -b given works like: mutex -l lockfile -n number_of_locks ; (command; mutex -u lockfile)&
Kan vi finde på lockid som giver mening?
=head1 options
One char options not used: F G J K P Q Y
Skilletegn i sshlogin:
#=item B<--sshlogin> I<[ncpu/]sshlogin[,[ncpu/]sshlogin[,...]]> (beta testing)
# Skilletegn:
# No: "#!&()?\<>|;*'~ shellspecial
# No: @.- part of user@i.p.n.r i.p.n.r host-name
# No: , separates different sshlogins
# No: space Will make it hard to do: 8/server1,server2
# Maybe: / 8//usr/bin/myssh,//usr/bin/ssh
# %/=:_^