开发者

Whats the easiest way to completely remove a directory element & all its sub-contents from VOB?

开发者 https://www.devze.com 2023-02-09 04:13 出处:网络
What I know is, 开发者_Python百科using rmelem to remove the folder first, and this will cause all of its child elements to be moved to lost+found.

What I know is, 开发者_Python百科using rmelem to remove the folder first, and this will cause all of its child elements to be moved to lost+found.

Then, go into lost+found, and repeatedly execute rmelem * until all of the elements are removed.

Is there a better way?


The technote about lost+found is quite clear:

if you rmelem a directory, all its content will indeed be moved to lost+found, where it will has to lost+found. The technote adds:

Note: If a directory element is deleted from lost+found with rmelem, its contents will be moved to lost+found in the same manner described in the first section above.

That is why I always try to rmelem files first, then directories, in order to avoid a trip (or several trips) in lost+found.

Except I very rarely rmelem anything, as the same technote warns:

Use rmelem carefully when deleting elements or symbolic links from the lost+found directory.
While the content of lost+found typically consists of unwanted elements and symbolic links, in some circumstances it can contain elements that are cataloged elsewhere in the VOB (that is, not orphaned) that are associated by symbolic or hard links.
For this reason, do not run rmelem recursively in lost+found without first verifying it contents.

If you need to save an element that is currently in lost+found, catalog it in a versioned directory using mv as explained in the previous section

Actually, with ClearCase UCM, it is almost impossible to rmelem any element with some history, because of all the hyperlink you would compromised (related to baselines mainly).

0

精彩评论

暂无评论...
验证码 换一张
取 消