This repository has been archived by the owner on Jan 31, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 22
How do I clean up an orphaned allocation
Malachi Griffith edited this page May 28, 2014
·
3 revisions
Occasionally a system crash or other outage during a build will result in an 'orphaned' disk allocation. For example as in the following warning and error message:
2014-04-01 22:06:58+0000 precise6: WARNING: Instance output directory (/opt/gms/0HDDD95/fs/0HDDD95/info/model_data/77ae30e13e154ddb918b8903fb02ff8d/build82d5d5f86c754e2f9109f925aac29d5b/variants/sv/squaredancer-0.1-d41d8cd98f00b204e9800998ecf8427e/tigra-validation-v1-d41d8cd98f00b204e9800998ecf8427e) already exists!
2014-04-01 22:06:58+0000 precise6: ERROR: Found allocation at (/opt/gms/0HDDD95/fs/0HDDD95/info/build_merged_alignments/detect-variants--precise64-vagrant-24205-63ea0860f7ad4b56abd257d475678806) but no software result for it's owner ID (63ea0860f7ad4b56abd257d475678806). This is either because the software result is currently being generated or because the allocation has been orphaned. If it is determined that the allocation has been orphaned then the allocation will need to be removed.
To clean up, you need to do the following: Check to make sure the owner mentioned actually doesn't exist and isn't being generated
perl -e 'use Genome; $al = Genome::Disk::Allocation->get(allocation_path => "build_merged_alignments/detect-variants--precise64-vagrant-24205-63ea0860f7ad4b56abd257d475678806"); $owner_id = $al->owner_id; $owner = $al->owner; print "\n\nowner_id = $owner_id\n\nowner = $owner\n\n";'
#Verify that $al->owner_id matches the owner ID in the warning message above, and that $al->owner is undefined.
Make sure the process isn't running on the machine (i.e. PID: 24205 on precise64-vagrant):
ps aux | grep 24205
Remove the symlink mentioned in the warning
rm -fr /opt/gms/0HDDD95/fs/0HDDD95/info/build_merged_alignments/detect-variants--precise64-vagrant-24205-63ea0860f7ad4b56abd257d475678806
Now allocation needs to be deallocated
genome disk allocation deallocate owner_id=63ea0860f7ad4b56abd257d475678806
An alternative to the above method is to use the following tool:
genome model admin fix-orhpaned-allocations-for-dv2-results --help