Changes between Version 3 and Version 4 of AlternateDistClientQuickstart
- Timestamp:
- Feb 26, 2010, 1:23:10 PM (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
AlternateDistClientQuickstart
v3 v4 5 5 To get started using update-mirror, take the following steps: 6 6 7 * Save update_mirror.py and parse_config.py somewhere in your PATH. I keep7 * Save update_mirror.py and parse_config.py somewhere in your PATH. I keep 8 8 my copy in ~/bin, since I added my ~/bin directory to my PATH long ago. 9 9 10 * Edit update_mirror.py to set two things:10 * Edit update_mirror.py to set two things: 11 11 12 12 1. Change mirrorRootDir to be the path to the directory where … … 16 16 want ps1-md; if you only want medium deep catalogs you want ps1-md-cat. 17 17 18 * Run it. A good format for the command is:19 18 * Run it. A good format for the command is: 19 {{{ 20 20 nice nohup update_mirror.py >& update_mirror_stdout.log & 21 21 }}} 22 22 That will run update_mirror.py in such a way that you can log out and 23 23 it will keep going. If you like, you can watch its progress with: 24 24 {{{ 25 25 tail -f update_mirror.log 26 26 }}} 27 27 Note that you are not watching update_mirror_stdout.log- that file is 28 28 only there to catch unexpected error messages. … … 36 36 however. There are command line options to update_mirror to let you 37 37 do that. Some examples are below, but you can see all the options if you do: 38 38 {{{ 39 39 update_mirror.py --help 40 40 }}} 41 41 To understand how to select datasets you need to understand the keys 42 42 that specify datasets. The easiest way to do that is to look at the … … 51 51 Selecting a particular skycell is a special case; see below. 52 52 53 -To get only stacks, do:54 53 * To get only stacks, do: 54 {{{ 55 55 update_mirror.py --select_stage stack 56 57 -To select only MD04, do:58 56 }}} 57 * To select only MD04, do: 58 {{{ 59 59 update_mirror.py --select_datagroup 'MD04.*' 60 61 -You can combine terms. For example, to select only stack-stack diffs62 done with the g.00000 filter for MD06, use:63 60 }}} 61 * You can combine terms. For example, to select only stack-stack diffs 62 done with the g.00000 filter for MD06, use: 63 {{{ 64 64 update_mirror.py --select_datagroup 'MD06.*' --select_filter g.00000 65 65 --select_stage SSdiff 66 66 }}} 67 67 Caution: the rules specifying what words mean what in the different 68 68 columns of the datastore table seem to change occasionally, so it's … … 75 75 the actual files that get downloaded for that fileset. At least one 76 76 of them will be a .tgz file, with a name like: 77 77 {{{ 78 78 MD04.skycell.068.stk.52993.skycell.068.tgz 79 79 }}} 80 80 The --select_tarball option to update_mirror lets you specify a 81 81 regular expression for the tarball name, so that option can be used to … … 84 84 file. 85 85 86 For example, to select only warps from MD04 for skycell 040, do:87 86 For example, to select only warps from MD04 for skycell 040, do: 87 {{{ 88 88 update_mirror.py --select_stage warp --select_datagroup 'MD04.*' 89 89 --select_tarball '.*skycell\.040\.tgz' 90 90 }}} 91 91 This can get tedius if you actually want several skycells, so here is 92 92 a useful trick with regular expressions. If you want skycells 038, 93 93 053, 061 and 074 from that stage and group, try: 94 94 {{{ 95 95 update_mirror.py --select_stage warp --select_datagroup 'MD04.*' 96 96 --select_tarball '.*skycell\.((038)|(053)|(061)|(074))\.tgz' 97 }}}
