Difference between revisions of "Sword Export to DANS"

From Dryad wiki
Jump to: navigation, search
(Useful Commands)
(Useful Commands)
Line 28: Line 28:
 
<pre>
 
<pre>
 
dryad2dans/bin/dans-transfer-many.sh
 
dryad2dans/bin/dans-transfer-many.sh
 +
</pre>
 +
 +
To select items in Dryad that haven't been transferred to DANS (for use with dans-transfer-many.sh):
 +
<pre>
 +
select item_id from item where in_archive=true and owning_collection=2 and item_id not in (select distinct item_id from metadatavalue where  metadatavalue.metadata_field_id=159 order by item_id) order by item_id;
 
</pre>
 
</pre>
  
 
[[Category:Technical Documentation]]
 
[[Category:Technical Documentation]]

Revision as of 08:04, 26 September 2017

Dryad content is stored in the DANS/KNAW system called EASY for preservation purposes. Dryad exports content to DANS using BagIt packages transferred via the SWORD protocol.

Installation Instructions

Detailed documentation for the DANS tools is on GitHub:

Useful Commands

To package (but not transfer) a single item, with Item ID 20, and leave the package for manual inspection:

sudo /opt/dryad/bin/dspace dsrun org.datadryad.dans.DANSTransfer -i 20 -p -k -t /opt/dryad-data/tmp/

To package and transfer a single item, with Item ID 20:

sudo /opt/dryad/bin/dspace dsrun org.datadryad.dans.DANSTransfer -i 20 -d -t /opt/dryad-data/tmp/

To package many items, put the item IDs in a text file called items.txt, one ID per line. Then, place this file in the directory where the temporary files should be stored (usually /opt/dryad-data/tmp), and from this directory, run:

dryad2dans/bin/dans-transfer-many.sh

To select items in Dryad that haven't been transferred to DANS (for use with dans-transfer-many.sh):

select item_id from item where in_archive=true and owning_collection=2 and item_id not in (select distinct item_id from metadatavalue where  metadatavalue.metadata_field_id=159 order by item_id) order by item_id;