{"id":122,"date":"2011-03-02T23:37:13","date_gmt":"2011-03-03T04:37:13","guid":{"rendered":"http:\/\/digitallibraryworld.com\/?p=122"},"modified":"2011-06-11T00:04:45","modified_gmt":"2011-06-11T04:04:45","slug":"how-to-delete-or-remove-dpm-replica","status":"publish","type":"post","link":"https:\/\/heisbudi.com\/?p=122","title":{"rendered":"How to delete or remove DPM replica?"},"content":{"rendered":"<p>If you ever find a need to delete a replica from your Data Protection manager 2007 or DPM2010, you will find that this is not as simple as clicking through several task buttons. This is quite cumbersome if you don&#8217;t have any programming knowledge. Surprisingly, this process was A LOT easier in DPM 2006. I don&#8217;t know why Microsoft decided to take this feature out.<\/p>\n<p>The short answer to this question is: POWERSHELL. You need to use DPM management shell, which is a powershell command prompt.<\/p>\n<p>The long answer is as follow:<!--more--><\/p>\n<p>1. Run the DPM management shell.<\/p>\n<p>2. Find the protection group for the replica you want to delete by issuing this command\u00a0in DPM shell<br \/>\n<strong> $pgList = Get-ProtectionGroup <span style=\"color: #3366ff;\">MYDPMSERVERNAME<\/span><br \/>\nForeach($pg in $pgList){<br \/>\nwrite-host($pg.FriendlyName)<br \/>\n}<\/strong><br \/>\nThe statement above will print out the list of protection group in your DPM\u00a0server.<br \/>\nThe first protection group should be referred to <strong>$pglist[0]<\/strong>, the second one\u00a0should be referred to as <strong>$pglist[1] <\/strong>and so on. If you only have one protection group, you can just refer to it as <strong>$pglist<\/strong>.<\/p>\n<p>3. Get the data source of the protected server(a replica of a volume\/share\/object you want to delete) using <strong>$pglist[x]<\/strong> above<br \/>\n<strong>$dslist = get-datasource($pglist[x])<\/strong><br \/>\nx is the name of the protection group from step 2<\/p>\n<p>4. Check to see if you have more than one data source by issuing this command<br \/>\n<strong> write-host $dslist.name<\/strong><br \/>\nIf you are getting an output, skip to step 5, and use <strong>$dslist<\/strong>, instead of <strong>$dslist[x].<\/strong><br \/>\nIf you are NOT getting any output, that means there are multiple data\u00a0source. You need to select which one you are going to use, by issuing the\u00a0following command<br \/>\n<strong>foreach($ds in $dslist){<\/strong><br \/>\n<strong> write-host $ds.name<\/strong><br \/>\n<strong> }<\/strong><br \/>\nThe first data source should be addressed as $dslist[0]. the second\u00a0$dslist[1] and so on.<\/p>\n<p>5. Get the list of all recovery point for the data source you&#8217;d like to trim.<br \/>\n<strong>$rplist=get-recoverypoint $dslist[x]<\/strong><br \/>\n<strong>foreach($rp in $rplist){<\/strong><br \/>\n<strong> write-host $rp.representedpointintime<\/strong><br \/>\n<strong> }<\/strong><br \/>\nAgain, the first recovery point should be addressed as $rplist[0]. The\u00a0second $rplist[1], and so on. If there is only one recovery point, you can just use <strong>$rplist.<\/strong><\/p>\n<p>6. Pick the recovery point you want to delete and delete them by issuing the\u00a0following command<br \/>\n<strong>remove-recoverypoint -recoverypoint $rplist[x]<\/strong><\/p>\n<p>This is an example of a complete command to delete a replica<br \/>\n<strong>$pgList = Get-ProtectionGroup <\/strong><strong>MYDPMSERVERNAME<\/strong><br \/>\n<strong>$dslist = get-datasource($pglist[2])<\/strong><br \/>\n<strong>$rplist=get-recoverypoint $dslist[6]<\/strong><br \/>\n<strong>remove-recoverypoint -recoverypoint $rplist[0]<\/strong><\/p>\n<div data-counters='1' data-style='square' data-size='regular' data-url='https:\/\/heisbudi.com\/?p=122' data-title='How to delete or remove DPM replica?' class='linksalpha_container linksalpha_app_3'><a href='\/\/www.linksalpha.com\/share?network='facebook' class='linksalpha_icon_facebook'><\/a><a href='\/\/www.linksalpha.com\/share?network='twitter' class='linksalpha_icon_twitter'><\/a><a href='\/\/www.linksalpha.com\/share?network='googleplus' class='linksalpha_icon_googleplus'><\/a><a href='\/\/www.linksalpha.com\/share?network='mail' class='linksalpha_icon_mail'><\/a><\/div><div data-position='' data-url='https:\/\/heisbudi.com\/?p=122' data-title='How to delete or remove DPM replica?' class='linksalpha_container linksalpha_app_7'><a href='\/\/www.linksalpha.com\/share?network='facebook' class='linksalpha_icon_facebook'><\/a><a href='\/\/www.linksalpha.com\/share?network='twitter' class='linksalpha_icon_twitter'><\/a><a href='\/\/www.linksalpha.com\/share?network='googleplus' class='linksalpha_icon_googleplus'><\/a><a href='\/\/www.linksalpha.com\/share?network='mail' class='linksalpha_icon_mail'><\/a><\/div>","protected":false},"excerpt":{"rendered":"<p>deleting replica from DPM2007 and DPM2010<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[18,7,6],"tags":[],"_links":{"self":[{"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/posts\/122"}],"collection":[{"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/heisbudi.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=122"}],"version-history":[{"count":13,"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/posts\/122\/revisions"}],"predecessor-version":[{"id":174,"href":"https:\/\/heisbudi.com\/index.php?rest_route=\/wp\/v2\/posts\/122\/revisions\/174"}],"wp:attachment":[{"href":"https:\/\/heisbudi.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=122"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/heisbudi.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=122"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/heisbudi.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=122"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}