SURF supports a handle tool to streamline the initial upload process to populate a new handle prefix. The tool is called hdl-genericbatch and it allows users to execute a batch file to upload multiple handles.

Prerequisites

You have

  • received a prefix, index and port number from SURF
  • created a private/public keypair
  • sent the public key to SURF and confirmed it has been uploaded


For more details see our documentation on new system setup for Unix and Windows users.

Example batch file

The following is an example of a batch file with 2 handles. 

AUTHENTICATE PUBKEY:<index>:<prefix>/<user>
/<path to private key>/<prefix>_<user>_<index>_privkey.bin

CREATE <prefix>/<suffix 1>
1   URL      86400 1110 UTF8 <url 1>
100 HS_ADMIN 86400 1110 ADMIN 200:110011111110:0.NA/<prefix>

CREATE <prefix>/<suffix 2>
1   URL      86400 1110 UTF8 <url 2>
100 HS_ADMIN 86400 1110 ADMIN 200:110011111110:0.NA/<prefix>

Each handle value line is composed of:


value indexvalue typettlpermission setvalue data
Example1URL864001110

UTF8 http://www.test.com/bundle_test1


100HS_ADMIN864001110ADMIN 200:110011111110:0.NA/21.T12995


This format is described in more detail in the Handle Tech Manual - chapter 4.9.


Once the batch file has been created you can run it:

/<path_to_hdl-genericbatch>/hdl-genericbatch /<path_to_batch_file>/<batch_file_name> /<path_to_log_file>/<log_file_name>.log

This will setup a connection to a primary handle server and upload the new handles. The automated mirroring will replicate the handles to other primary handle servers and mirror systems. The handle tool (hdl-genericbatch) cannot control which primary handle system will be used to upload the handles and thus we only support this method for an initial upload.

Further Documentation

 hdl-genericbatch usage is detailed in the Handle Tech Manual - chapter 4.

Table of contents

  • No labels