LoRS Command Line Tool Tutorial
The LoRS command line tools let you do three primary things:
They also give you the ability to see where the pieces of the file are stored (List) and to extend the allocations' expiration times (Refresh).
- Store a file into the wide-area network (Upload),
- Change where the file is located in the network (Augment or Trim), and
- Retrieve the file (Download).
The tools have built-in defaults which can be over-ridden by settings in the .xndrc preferences file.
Once you have stored an exNode, you may want to know where the pieces are or you may want to know if they are accessible. You can list the exNode to see these things. For example,
lors_ls foo.xnd -h
will provide output something like:
TITLE Filename foo
0 Srwma 1 silo.surfnet.nl:6714 0 500000 Thu Jun 19 11:26:55 2003
1 Srwma 1 silo.surfnet.nl:6714 500000 500000 Thu Jun 19 11:26:55 2003
The tool repeats the exNode name (foo.xnd), the filename (foo) and the file's size in bytes (1000000). It then prints one line per IBP allocation. The line starts with a number that is the allocation's (fragment's, segment's, allocation's or mapping's) number. you may use this to specify a specific mapping when using other tools.
Next, it shows Srwma which means that it uses SOFT IBP allocation (or H for a HARD allocation). The rwm means that the exNode contains the Read, Write and Manage IBP capabilities. If you want to give someone read access to your exNode but not the ability to delete your IBP allocations, you would remove the Write and Manage capabilities from the exNode (currently, you must do this manually by editing the .xnd XML file but we will provide a tool in the next release). The a means the storage is an IBP byte array.
The next column has a number. It is typically 1 or -1. A positive 1 means that this allocation is available. Conversely, a negative 1 means that it is not.
The fourth column has the name of the depot and the depot's port number.
The fifth column has the offset (starting byte) of the data stored in this allocation. The sixth column has number of bytes stored in this allocation. The default is the logical number of bytes. If you used checksums the physical number is slightly higher. If you used compression, the actual number may be a lot less. You can add the -p parameter to see the actual number of stored bytes.
The last set of columns show the expiration date of the allocation. If the allocation was not reachable, it will say DEAD.